From 5deabd3cfade451e0482dca45e58dbe572760750 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Mon, 16 Sep 2024 19:01:27 +0530 Subject: [PATCH 001/178] feat: add vip for multichain governance on zksync sepolia --- .../proposals/zksyncsepolia/vip-010/index.ts | 93 +++ .../vip-010/abi/AccessControlManagerAbi.json | 157 +++++ .../zksyncsepolia/vip-010/index.ts | 73 +++ .../vip-365/abi/AccessControlManager_ABI.json | 157 +++++ .../abi/OmnichainExecutorOwner_ABI.json | 145 +++++ .../abi/OmnichainGovernanceExecutor_ABI.json | 539 ++++++++++++++++++ .../vip-365/abi/OmnichainProposalSender.json | 314 ++++++++++ simulations/vip-365/bsctestnet.ts | 56 ++ simulations/vip-365/zksyncsepolia.ts | 97 ++++ .../vip-366/abi/AccessControlManager_ABI.json | 157 +++++ .../abi/OmnichainGovernanceExecutor_ABI.json | 539 ++++++++++++++++++ .../vip-366/abi/OmnichainProposalSender.json | 314 ++++++++++ simulations/vip-366/bsctestnet.ts | 26 + simulations/vip-366/zksyncsepolia.ts | 45 ++ src/networkAddresses.ts | 5 +- src/types.ts | 3 +- src/utils.ts | 8 + src/vip-framework/index.ts | 16 +- vips/vip-365/bsctestnet.ts | 173 ++++++ vips/vip-366/bsctestnet.ts | 132 +++++ 20 files changed, 3044 insertions(+), 5 deletions(-) create mode 100644 multisig/proposals/zksyncsepolia/vip-010/index.ts create mode 100644 multisig/simulations/zksyncsepolia/vip-010/abi/AccessControlManagerAbi.json create mode 100644 multisig/simulations/zksyncsepolia/vip-010/index.ts create mode 100644 simulations/vip-365/abi/AccessControlManager_ABI.json create mode 100644 simulations/vip-365/abi/OmnichainExecutorOwner_ABI.json create mode 100644 simulations/vip-365/abi/OmnichainGovernanceExecutor_ABI.json create mode 100644 simulations/vip-365/abi/OmnichainProposalSender.json create mode 100644 simulations/vip-365/bsctestnet.ts create mode 100644 simulations/vip-365/zksyncsepolia.ts create mode 100644 simulations/vip-366/abi/AccessControlManager_ABI.json create mode 100644 simulations/vip-366/abi/OmnichainGovernanceExecutor_ABI.json create mode 100644 simulations/vip-366/abi/OmnichainProposalSender.json create mode 100644 simulations/vip-366/bsctestnet.ts create mode 100644 simulations/vip-366/zksyncsepolia.ts create mode 100644 vips/vip-365/bsctestnet.ts create mode 100644 vips/vip-366/bsctestnet.ts diff --git a/multisig/proposals/zksyncsepolia/vip-010/index.ts b/multisig/proposals/zksyncsepolia/vip-010/index.ts new file mode 100644 index 000000000..1790c7435 --- /dev/null +++ b/multisig/proposals/zksyncsepolia/vip-010/index.ts @@ -0,0 +1,93 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { makeProposal } from "src/utils"; + +export const ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER = "0xa34607D58146FA02aF5f920f29C3D916acAb0bC5"; +export const ZKSYNCSEPOLIA_ACM = "0xD07f543d47c3a8997D6079958308e981AC14CD01"; +export const ZKSYNCSEPOLIA_NORMAL_TIMELOCK = "0x1730527a0f0930269313D77A317361b42971a67E"; +const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + +const { zksyncsepolia } = NETWORK_ADDRESSES; + +export const vip010 = () => { + return makeProposal([ + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "forceResumeReceive(uint16,bytes)", zksyncsepolia.GUARDIAN], + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setMaxDailyReceiveLimit(uint256)", zksyncsepolia.GUARDIAN], + }, + + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "pause()", zksyncsepolia.GUARDIAN], + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "unpause()", zksyncsepolia.GUARDIAN], + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setTrustedRemoteAddress(uint16,bytes)", zksyncsepolia.GUARDIAN], + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "addTimelocks(address[])", zksyncsepolia.GUARDIAN], + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "setTimelockPendingAdmin(address,uint8)", + zksyncsepolia.GUARDIAN, + ], + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "retryMessage(uint16,bytes,uint64,bytes)", + zksyncsepolia.GUARDIAN, + ], + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setSrcChainId(uint16)", zksyncsepolia.GUARDIAN], + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setReceiveVersion(uint16)", zksyncsepolia.GUARDIAN], + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "setConfig(uint16,uint16,uint256,bytes)", + zksyncsepolia.GUARDIAN, + ], + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "transferBridgeOwnership(address)", zksyncsepolia.GUARDIAN], + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ZKSYNCSEPOLIA_NORMAL_TIMELOCK], + }, + ]); +}; +export default vip010; diff --git a/multisig/simulations/zksyncsepolia/vip-010/abi/AccessControlManagerAbi.json b/multisig/simulations/zksyncsepolia/vip-010/abi/AccessControlManagerAbi.json new file mode 100644 index 000000000..2ef119947 --- /dev/null +++ b/multisig/simulations/zksyncsepolia/vip-010/abi/AccessControlManagerAbi.json @@ -0,0 +1,157 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } + ], + "name": "RoleAdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleRevoked", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_ADMIN_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleAdmin", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToPermit", "type": "address" } + ], + "name": "giveCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "grantRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "hasPermission", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "hasRole", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "isAllowedToCall", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "renounceRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToRevoke", "type": "address" } + ], + "name": "revokeCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "revokeRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], + "name": "supportsInterface", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/zksyncsepolia/vip-010/index.ts b/multisig/simulations/zksyncsepolia/vip-010/index.ts new file mode 100644 index 000000000..7f0b96c1d --- /dev/null +++ b/multisig/simulations/zksyncsepolia/vip-010/index.ts @@ -0,0 +1,73 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip009, { + ZKSYNCSEPOLIA_ACM, + ZKSYNCSEPOLIA_NORMAL_TIMELOCK, + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, +} from "../../../proposals/zksyncsepolia/vip-010"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManagerAbi.json"; + +const { zksyncsepolia } = NETWORK_ADDRESSES; + +forking(3771669, async () => { + let acm: Contract; + let defaultAdminRole: string; + before(async () => { + acm = await ethers.getContractAt(ACCESS_CONTROL_MANAGER_ABI, ZKSYNCSEPOLIA_ACM); + defaultAdminRole = await acm.DEFAULT_ADMIN_ROLE(); + }); + describe("Pre-VIP behaviour", async () => { + it("Normal Timelock does not has default admin role", async () => { + const hasRole = await acm.hasRole(defaultAdminRole, ZKSYNCSEPOLIA_NORMAL_TIMELOCK); + expect(hasRole).equals(false); + }); + + it("Guardian is not allowed to call retryMessage", async () => { + const role = ethers.utils.solidityPack( + ["address", "string"], + [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "retryMessage(uint16,bytes,uint64,bytes)"], + ); + const roleHash = ethers.utils.keccak256(role); + expect(await acm.hasRole(roleHash, zksyncsepolia.GUARDIAN)).to.be.false; + }); + + it("Guardian is not allowed to call forceResumeReceive", async () => { + const role = ethers.utils.solidityPack( + ["address", "string"], + [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "forceResumeReceive(uint16,bytes)"], + ); + const roleHash = ethers.utils.keccak256(role); + expect(await acm.hasRole(roleHash, zksyncsepolia.GUARDIAN)).to.be.false; + }); + }); + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip009()); + }); + it("Normal Timelock has default admin role", async () => { + const hasRole = await acm.hasRole(defaultAdminRole, ZKSYNCSEPOLIA_NORMAL_TIMELOCK); + expect(hasRole).equals(true); + }); + it("Guardian is allowed to call retryMessage", async () => { + const role = ethers.utils.solidityPack( + ["address", "string"], + [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "retryMessage(uint16,bytes,uint64,bytes)"], + ); + const roleHash = ethers.utils.keccak256(role); + expect(await acm.hasRole(roleHash, zksyncsepolia.GUARDIAN)).to.be.true; + }); + + it("Guardian is allowed to call forceResumeReceive", async () => { + const role = ethers.utils.solidityPack( + ["address", "string"], + [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "forceResumeReceive(uint16,bytes)"], + ); + const roleHash = ethers.utils.keccak256(role); + expect(await acm.hasRole(roleHash, zksyncsepolia.GUARDIAN)).to.be.true; + }); + }); +}); diff --git a/simulations/vip-365/abi/AccessControlManager_ABI.json b/simulations/vip-365/abi/AccessControlManager_ABI.json new file mode 100644 index 000000000..2ef119947 --- /dev/null +++ b/simulations/vip-365/abi/AccessControlManager_ABI.json @@ -0,0 +1,157 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } + ], + "name": "RoleAdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleRevoked", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_ADMIN_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleAdmin", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToPermit", "type": "address" } + ], + "name": "giveCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "grantRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "hasPermission", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "hasRole", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "isAllowedToCall", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "renounceRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToRevoke", "type": "address" } + ], + "name": "revokeCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "revokeRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], + "name": "supportsInterface", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-365/abi/OmnichainExecutorOwner_ABI.json b/simulations/vip-365/abi/OmnichainExecutorOwner_ABI.json new file mode 100644 index 000000000..f75834e6c --- /dev/null +++ b/simulations/vip-365/abi/OmnichainExecutorOwner_ABI.json @@ -0,0 +1,145 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "omnichainGovernanceExecutor_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "string", "name": "signature", "type": "string" }, + { "indexed": false, "internalType": "bool", "name": "active", "type": "bool" } + ], + "name": "FunctionRegistryChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "stateMutability": "nonpayable", "type": "fallback" }, + { + "inputs": [], + "name": "OMNICHAIN_GOVERNANCE_EXECUTOR", + "outputs": [{ "internalType": "contract IOmnichainGovernanceExecutor", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes4", "name": "", "type": "bytes4" }], + "name": "functionRegistry", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "srcAddress_", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner_", "type": "address" }], + "name": "transferBridgeOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "string[]", "name": "signatures_", "type": "string[]" }, + { "internalType": "bool[]", "name": "active_", "type": "bool[]" } + ], + "name": "upsertSignature", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-365/abi/OmnichainGovernanceExecutor_ABI.json b/simulations/vip-365/abi/OmnichainGovernanceExecutor_ABI.json new file mode 100644 index 000000000..b40c3cf44 --- /dev/null +++ b/simulations/vip-365/abi/OmnichainGovernanceExecutor_ABI.json @@ -0,0 +1,539 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "endpoint_", "type": "address" }, + { "internalType": "address", "name": "guardian_", "type": "address" }, + { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidProposalId", "type": "error" }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "indexed": false, "internalType": "bytes", "name": "_payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "_reason", "type": "bytes" } + ], + "name": "MessageFailed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldGuardian", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newGuardian", "type": "address" } + ], + "name": "NewGuardian", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint256", "name": "id", "type": "uint256" }], + "name": "ProposalCanceled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint256", "name": "id", "type": "uint256" }], + "name": "ProposalExecuted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "id", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "eta", "type": "uint256" } + ], + "name": "ProposalQueued", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "address[]", "name": "targets", "type": "address[]" }, + { "indexed": false, "internalType": "uint256[]", "name": "values", "type": "uint256[]" }, + { "indexed": false, "internalType": "string[]", "name": "signatures", "type": "string[]" }, + { "indexed": false, "internalType": "bytes[]", "name": "calldatas", "type": "bytes[]" }, + { "indexed": false, "internalType": "uint8", "name": "proposalType", "type": "uint8" } + ], + "name": "ProposalReceived", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "srcChainId", "type": "uint16" }, + { "indexed": true, "internalType": "bytes", "name": "srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "nonce", "type": "uint64" }, + { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } + ], + "name": "ReceivePayloadFailed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "indexed": false, "internalType": "bytes32", "name": "_payloadHash", "type": "bytes32" } + ], + "name": "RetryMessageSuccess", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyReceiveLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint16", "name": "_type", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "_minDstGas", "type": "uint256" } + ], + "name": "SetMinDstGas", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "precrime", "type": "address" }], + "name": "SetPrecrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "oldSrcChainId", "type": "uint16" }, + { "indexed": true, "internalType": "uint16", "name": "newSrcChainId", "type": "uint16" } + ], + "name": "SetSrcChainId", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "", "type": "address" }, + { "indexed": false, "internalType": "uint8", "name": "", "type": "uint8" } + ], + "name": "SetTimelockPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_path", "type": "bytes" } + ], + "name": "SetTrustedRemote", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint8", "name": "routeType", "type": "uint8" }, + { "indexed": true, "internalType": "address", "name": "oldTimelock", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newTimelock", "type": "address" } + ], + "name": "TimelockAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_PAYLOAD_SIZE_LIMIT", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ITimelock[]", "name": "timelocks_", "type": "address[]" }], + "name": "addTimelocks", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "proposalId_", "type": "uint256" }], + "name": "cancel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "proposalId_", "type": "uint256" }], + "name": "execute", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "", "type": "uint16" }, + { "internalType": "bytes", "name": "", "type": "bytes" }, + { "internalType": "uint64", "name": "", "type": "uint64" } + ], + "name": "failedMessages", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } + ], + "name": "forceResumeReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_version", "type": "uint16" }, + { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "_configType", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }], + "name": "getTrustedRemoteAddress", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "guardian", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } + ], + "name": "isTrustedRemote", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "last24HourCommandsReceived", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "last24HourReceiveWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "lastProposalReceived", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "lzEndpoint", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "internalType": "bytes", "name": "_payload", "type": "bytes" } + ], + "name": "lzReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxDailyReceiveLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "", "type": "uint16" }, + { "internalType": "uint16", "name": "", "type": "uint16" } + ], + "name": "minDstGasLookup", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "internalType": "bytes", "name": "_payload", "type": "bytes" } + ], + "name": "nonblockingLzReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "payloadSizeLimitLookup", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "precrime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "proposalTimelocks", + "outputs": [{ "internalType": "contract ITimelock", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "proposals", + "outputs": [ + { "internalType": "uint256", "name": "id", "type": "uint256" }, + { "internalType": "uint256", "name": "eta", "type": "uint256" }, + { "internalType": "bool", "name": "canceled", "type": "bool" }, + { "internalType": "bool", "name": "executed", "type": "bool" }, + { "internalType": "uint8", "name": "proposalType", "type": "uint8" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "queued", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "srcAddress_", "type": "bytes" }, + { "internalType": "uint64", "name": "nonce_", "type": "uint64" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" } + ], + "name": "retryMessage", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_version", "type": "uint16" }, + { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, + { "internalType": "uint256", "name": "_configType", "type": "uint256" }, + { "internalType": "bytes", "name": "_config", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newGuardian", "type": "address" }], + "name": "setGuardian", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit_", "type": "uint256" }], + "name": "setMaxDailyReceiveLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "internalType": "uint16", "name": "_packetType", "type": "uint16" }, + { "internalType": "uint256", "name": "_minGas", "type": "uint256" } + ], + "name": "setMinDstGas", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "internalType": "uint256", "name": "_size", "type": "uint256" } + ], + "name": "setPayloadSizeLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_precrime", "type": "address" }], + "name": "setPrecrime", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], + "name": "setReceiveVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }], + "name": "setSrcChainId", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "pendingAdmin_", "type": "address" }, + { "internalType": "uint8", "name": "proposalType_", "type": "uint8" } + ], + "name": "setTimelockPendingAdmin", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_path", "type": "bytes" } + ], + "name": "setTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "srcChainId", + "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "proposalId_", "type": "uint256" }], + "name": "state", + "outputs": [{ "internalType": "enum OmnichainGovernanceExecutor.ProposalState", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } +] diff --git a/simulations/vip-365/abi/OmnichainProposalSender.json b/simulations/vip-365/abi/OmnichainProposalSender.json new file mode 100644 index 000000000..66fd4df02 --- /dev/null +++ b/simulations/vip-365/abi/OmnichainProposalSender.json @@ -0,0 +1,314 @@ +[ + { + "inputs": [ + { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } + ], + "name": "ClearPayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } + ], + "name": "ExecuteRemoteProposal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "FallbackWithdraw", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } + ], + "name": "StorePayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], + "name": "TrustedRemoteRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "LZ_ENDPOINT", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourCommandsSent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLastProposalSentTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bool", "name": "useZro_", "type": "bool" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } + ], + "name": "estimateFees", + "outputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } + ], + "name": "execute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "fallbackWithdraw", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "proposalCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], + "name": "removeTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "retryExecute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" }, + { "internalType": "bytes", "name": "config_", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "storedExecutionHashes", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } +] diff --git a/simulations/vip-365/bsctestnet.ts b/simulations/vip-365/bsctestnet.ts new file mode 100644 index 000000000..7f8e66523 --- /dev/null +++ b/simulations/vip-365/bsctestnet.ts @@ -0,0 +1,56 @@ +import { expect } from "chai"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId } from "src/types"; +import { expectEvents } from "src/utils"; +import { forking, testVip } from "src/vip-framework"; + +import vip365, { MAX_DAILY_LIMIT, OMNICHAIN_PROPOSAL_SENDER } from "../../vips/vip-365/bsctestnet"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +const { zksyncsepolia } = NETWORK_ADDRESSES; +forking(43836268, async () => { + const provider = ethers.provider; + const omnichainProposalSender = new ethers.Contract( + OMNICHAIN_PROPOSAL_SENDER, + OMNICHAIN_PROPOSAL_SENDER_ABI, + provider, + ); + + describe("Pre-VIP behaviour", () => { + it("Daily limit should be 0", async () => { + expect(await omnichainProposalSender.chainIdToMaxDailyLimit(LzChainId.zksyncsepolia)).to.equals(0); + }); + it("Trusted remote should not be set", async () => { + expect(await omnichainProposalSender.trustedRemoteLookup(LzChainId.zksyncsepolia)).to.be.equals("0x"); + }); + }); + + testVip("vip365 give permissions to timelock", await vip365(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [ACCESS_CONTROL_MANAGER_ABI, OMNICHAIN_PROPOSAL_SENDER_ABI], + + ["SetMaxDailyLimit", "SetTrustedRemoteAddress", "ExecuteRemoteProposal", "StorePayload"], + [1, 1, 1, 0], + ); + }, + }); + + describe("Post-VIP behavior", () => { + it("Daily limit should be 100 of zksyncsepolia", async () => { + expect(await omnichainProposalSender.chainIdToMaxDailyLimit(LzChainId.zksyncsepolia)).to.equals(MAX_DAILY_LIMIT); + }); + + it("Trusted remote should be set of zksyncsepolia", async () => { + expect(await omnichainProposalSender.trustedRemoteLookup(LzChainId.zksyncsepolia)).to.be.equals( + ethers.utils.solidityPack( + ["address", "address"], + [zksyncsepolia.OMNICHAIN_GOVERNANCE_EXECUTOR, OMNICHAIN_PROPOSAL_SENDER], + ), + ); + }); + }); +}); diff --git a/simulations/vip-365/zksyncsepolia.ts b/simulations/vip-365/zksyncsepolia.ts new file mode 100644 index 000000000..5cd8838e4 --- /dev/null +++ b/simulations/vip-365/zksyncsepolia.ts @@ -0,0 +1,97 @@ +import { expect } from "chai"; +import { BigNumber, Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId } from "src/types"; +import { expectEvents, getOmnichainProposalSenderAddress } from "src/utils"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip010 from "../../multisig/proposals/zksyncsepolia/vip-010"; +import vip365, { ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER } from "../../vips/vip-365/bsctestnet"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; +import OMNICHAIN_EXECUTOR_OWNER_ABI from "./abi/OmnichainExecutorOwner_ABI.json"; +import OMNICHAIN_GOVERNANCE_EXECUTOR_ABI from "./abi/OmnichainGovernanceExecutor_ABI.json"; + +const { zksyncsepolia } = NETWORK_ADDRESSES; +const FAST_TRACK_TIMELOCK = "0xb055e028b27d53a455a6c040a6952e44E9E615c4"; +const CRITICAL_TIMELOCK = "0x0E6138bE0FA1915efC73670a20A10EFd720a6Cc8"; + +forking(3771669, async () => { + const provider = ethers.provider; + let lastProposalReceived: BigNumber; + let executor: Contract; + let executorOwner: Contract; + + before(async () => { + executor = new ethers.Contract( + zksyncsepolia.OMNICHAIN_GOVERNANCE_EXECUTOR, + OMNICHAIN_GOVERNANCE_EXECUTOR_ABI, + provider, + ); + executorOwner = new ethers.Contract(ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, OMNICHAIN_EXECUTOR_OWNER_ABI, provider); + lastProposalReceived = await executor.lastProposalReceived(); + await pretendExecutingVip(await vip010()); + }); + + testForkedNetworkVipCommands("vip365 configures bridge", await vip365(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [15]); + }, + }); + + describe("Post-VIP behaviour", async () => { + it("Proposal id should be incremented", async () => { + expect(await executor.lastProposalReceived()).to.be.equals(lastProposalReceived.add(1)); + }); + it("proposal should be executed", async () => { + const pId = await executor.lastProposalReceived(); + expect(await executor.state(pId)).to.be.equals(2); + }); + it("check configuration", async () => { + // Check Timelock configurations + expect(await executor.proposalTimelocks(0)).equals(zksyncsepolia.NORMAL_TIMELOCK); + expect(await executor.proposalTimelocks(1)).equals(FAST_TRACK_TIMELOCK); + expect(await executor.proposalTimelocks(2)).equals(CRITICAL_TIMELOCK); + + // Check trusted remote + expect(await executor.trustedRemoteLookup(LzChainId.bscmainnet)).equals( + ethers.utils.solidityPack( + ["address", "address"], + [getOmnichainProposalSenderAddress(), zksyncsepolia.OMNICHAIN_GOVERNANCE_EXECUTOR], + ), + ); + + // Check receiving limit + expect(await executor.maxDailyReceiveLimit()).equals(100); + expect(await executor.last24HourCommandsReceived()).equals(16); + + // Check function registry + const functionSignatures: string[] = [ + "forceResumeReceive(uint16,bytes)", + "pause()", + "unpause()", + "setSendVersion(uint16)", + "setReceiveVersion(uint16)", + "setMaxDailyReceiveLimit(uint256)", + "setTrustedRemoteAddress(uint16,bytes)", + "setPrecrime(address)", + "setMinDstGas(uint16,uint16,uint256)", + "setPayloadSizeLimit(uint16,uint256)", + "setConfig(uint16,uint16,uint256,bytes)", + "addTimelocks(ITimelock[])", + "setTimelockPendingAdmin(address,uint8)", + "retryMessage(uint16,bytes,uint64,bytes)", + "setGuardian(address)", + "setSrcChainId(uint16)", + ]; + const getFunctionSelector = (signature: string): string => { + return ethers.utils.keccak256(ethers.utils.toUtf8Bytes(signature)).substring(0, 10); + }; + + for (const signature of functionSignatures) { + const selector = getFunctionSelector(signature); + expect(await executorOwner.functionRegistry(selector)).equals(signature); + } + }); + }); +}); diff --git a/simulations/vip-366/abi/AccessControlManager_ABI.json b/simulations/vip-366/abi/AccessControlManager_ABI.json new file mode 100644 index 000000000..2ef119947 --- /dev/null +++ b/simulations/vip-366/abi/AccessControlManager_ABI.json @@ -0,0 +1,157 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } + ], + "name": "RoleAdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleRevoked", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_ADMIN_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleAdmin", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToPermit", "type": "address" } + ], + "name": "giveCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "grantRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "hasPermission", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "hasRole", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "isAllowedToCall", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "renounceRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToRevoke", "type": "address" } + ], + "name": "revokeCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "revokeRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], + "name": "supportsInterface", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-366/abi/OmnichainGovernanceExecutor_ABI.json b/simulations/vip-366/abi/OmnichainGovernanceExecutor_ABI.json new file mode 100644 index 000000000..b40c3cf44 --- /dev/null +++ b/simulations/vip-366/abi/OmnichainGovernanceExecutor_ABI.json @@ -0,0 +1,539 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "endpoint_", "type": "address" }, + { "internalType": "address", "name": "guardian_", "type": "address" }, + { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidProposalId", "type": "error" }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "indexed": false, "internalType": "bytes", "name": "_payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "_reason", "type": "bytes" } + ], + "name": "MessageFailed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldGuardian", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newGuardian", "type": "address" } + ], + "name": "NewGuardian", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint256", "name": "id", "type": "uint256" }], + "name": "ProposalCanceled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint256", "name": "id", "type": "uint256" }], + "name": "ProposalExecuted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "id", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "eta", "type": "uint256" } + ], + "name": "ProposalQueued", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "address[]", "name": "targets", "type": "address[]" }, + { "indexed": false, "internalType": "uint256[]", "name": "values", "type": "uint256[]" }, + { "indexed": false, "internalType": "string[]", "name": "signatures", "type": "string[]" }, + { "indexed": false, "internalType": "bytes[]", "name": "calldatas", "type": "bytes[]" }, + { "indexed": false, "internalType": "uint8", "name": "proposalType", "type": "uint8" } + ], + "name": "ProposalReceived", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "srcChainId", "type": "uint16" }, + { "indexed": true, "internalType": "bytes", "name": "srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "nonce", "type": "uint64" }, + { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } + ], + "name": "ReceivePayloadFailed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "indexed": false, "internalType": "bytes32", "name": "_payloadHash", "type": "bytes32" } + ], + "name": "RetryMessageSuccess", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyReceiveLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint16", "name": "_type", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "_minDstGas", "type": "uint256" } + ], + "name": "SetMinDstGas", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "precrime", "type": "address" }], + "name": "SetPrecrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "oldSrcChainId", "type": "uint16" }, + { "indexed": true, "internalType": "uint16", "name": "newSrcChainId", "type": "uint16" } + ], + "name": "SetSrcChainId", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "", "type": "address" }, + { "indexed": false, "internalType": "uint8", "name": "", "type": "uint8" } + ], + "name": "SetTimelockPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_path", "type": "bytes" } + ], + "name": "SetTrustedRemote", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint8", "name": "routeType", "type": "uint8" }, + { "indexed": true, "internalType": "address", "name": "oldTimelock", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newTimelock", "type": "address" } + ], + "name": "TimelockAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_PAYLOAD_SIZE_LIMIT", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ITimelock[]", "name": "timelocks_", "type": "address[]" }], + "name": "addTimelocks", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "proposalId_", "type": "uint256" }], + "name": "cancel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "proposalId_", "type": "uint256" }], + "name": "execute", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "", "type": "uint16" }, + { "internalType": "bytes", "name": "", "type": "bytes" }, + { "internalType": "uint64", "name": "", "type": "uint64" } + ], + "name": "failedMessages", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } + ], + "name": "forceResumeReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_version", "type": "uint16" }, + { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "_configType", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }], + "name": "getTrustedRemoteAddress", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "guardian", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } + ], + "name": "isTrustedRemote", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "last24HourCommandsReceived", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "last24HourReceiveWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "lastProposalReceived", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "lzEndpoint", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "internalType": "bytes", "name": "_payload", "type": "bytes" } + ], + "name": "lzReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxDailyReceiveLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "", "type": "uint16" }, + { "internalType": "uint16", "name": "", "type": "uint16" } + ], + "name": "minDstGasLookup", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "internalType": "bytes", "name": "_payload", "type": "bytes" } + ], + "name": "nonblockingLzReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "payloadSizeLimitLookup", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "precrime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "proposalTimelocks", + "outputs": [{ "internalType": "contract ITimelock", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "proposals", + "outputs": [ + { "internalType": "uint256", "name": "id", "type": "uint256" }, + { "internalType": "uint256", "name": "eta", "type": "uint256" }, + { "internalType": "bool", "name": "canceled", "type": "bool" }, + { "internalType": "bool", "name": "executed", "type": "bool" }, + { "internalType": "uint8", "name": "proposalType", "type": "uint8" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "queued", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "srcAddress_", "type": "bytes" }, + { "internalType": "uint64", "name": "nonce_", "type": "uint64" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" } + ], + "name": "retryMessage", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_version", "type": "uint16" }, + { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, + { "internalType": "uint256", "name": "_configType", "type": "uint256" }, + { "internalType": "bytes", "name": "_config", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newGuardian", "type": "address" }], + "name": "setGuardian", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit_", "type": "uint256" }], + "name": "setMaxDailyReceiveLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "internalType": "uint16", "name": "_packetType", "type": "uint16" }, + { "internalType": "uint256", "name": "_minGas", "type": "uint256" } + ], + "name": "setMinDstGas", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "internalType": "uint256", "name": "_size", "type": "uint256" } + ], + "name": "setPayloadSizeLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_precrime", "type": "address" }], + "name": "setPrecrime", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], + "name": "setReceiveVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }], + "name": "setSrcChainId", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "pendingAdmin_", "type": "address" }, + { "internalType": "uint8", "name": "proposalType_", "type": "uint8" } + ], + "name": "setTimelockPendingAdmin", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_path", "type": "bytes" } + ], + "name": "setTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "srcChainId", + "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "proposalId_", "type": "uint256" }], + "name": "state", + "outputs": [{ "internalType": "enum OmnichainGovernanceExecutor.ProposalState", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } +] diff --git a/simulations/vip-366/abi/OmnichainProposalSender.json b/simulations/vip-366/abi/OmnichainProposalSender.json new file mode 100644 index 000000000..66fd4df02 --- /dev/null +++ b/simulations/vip-366/abi/OmnichainProposalSender.json @@ -0,0 +1,314 @@ +[ + { + "inputs": [ + { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } + ], + "name": "ClearPayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } + ], + "name": "ExecuteRemoteProposal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "FallbackWithdraw", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } + ], + "name": "StorePayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], + "name": "TrustedRemoteRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "LZ_ENDPOINT", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourCommandsSent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLastProposalSentTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bool", "name": "useZro_", "type": "bool" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } + ], + "name": "estimateFees", + "outputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } + ], + "name": "execute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "fallbackWithdraw", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "proposalCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], + "name": "removeTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "retryExecute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" }, + { "internalType": "bytes", "name": "config_", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "storedExecutionHashes", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } +] diff --git a/simulations/vip-366/bsctestnet.ts b/simulations/vip-366/bsctestnet.ts new file mode 100644 index 000000000..a1f11cde2 --- /dev/null +++ b/simulations/vip-366/bsctestnet.ts @@ -0,0 +1,26 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; +import { forking, pretendExecutingVip, testVip } from "src/vip-framework"; + +import vip365 from "../../vips/vip-365/bsctestnet"; +import vip366 from "../../vips/vip-366/bsctestnet"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +const { bsctestnet } = NETWORK_ADDRESSES; + +forking(43839242, async () => { + before(async () => { + await pretendExecutingVip(await vip365(), bsctestnet.NORMAL_TIMELOCK); + }); + + testVip("vip329 give permissions to critical & fasttrack timelock", await vip366(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [1, 0], + ); + }, + }); +}); diff --git a/simulations/vip-366/zksyncsepolia.ts b/simulations/vip-366/zksyncsepolia.ts new file mode 100644 index 000000000..3ebb050de --- /dev/null +++ b/simulations/vip-366/zksyncsepolia.ts @@ -0,0 +1,45 @@ +import { expect } from "chai"; +import { BigNumber, Contract } from "ethers"; +import { ethers } from "hardhat"; +import vip010 from "multisig/proposals/zksyncsepolia/vip-010"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip366 from "../../vips/vip-366/bsctestnet"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; +import OMNICHAIN_GOVERNANCE_EXECUTOR_ABI from "./abi/OmnichainGovernanceExecutor_ABI.json"; + +const { zksyncsepolia } = NETWORK_ADDRESSES; + +forking(3771669, async () => { + const provider = ethers.provider; + let lastProposalReceived: BigNumber; + let executor: Contract; + + before(async () => { + executor = new ethers.Contract( + zksyncsepolia.OMNICHAIN_GOVERNANCE_EXECUTOR, + OMNICHAIN_GOVERNANCE_EXECUTOR_ABI, + provider, + ); + lastProposalReceived = await executor.lastProposalReceived(); + await pretendExecutingVip(await vip010()); + }); + + testForkedNetworkVipCommands("vip366 configures bridge", await vip366(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [12]); + }, + }); + + describe("Post-VIP behaviour", async () => { + it("Proposal id should be incremented", async () => { + expect(await executor.lastProposalReceived()).to.be.equals(lastProposalReceived.add(1)); + }); + it("proposal should be executed", async () => { + const pId = await executor.lastProposalReceived(); + expect(await executor.state(pId)).to.be.equals(2); + }); + }); +}); diff --git a/src/networkAddresses.ts b/src/networkAddresses.ts index 16922e8f8..69643392f 100644 --- a/src/networkAddresses.ts +++ b/src/networkAddresses.ts @@ -167,7 +167,7 @@ export const NETWORK_ADDRESSES = { GUARDIAN: "0x5961449d63149035aCfC0714D5155f24C9819004", }, zksyncsepolia: { - NORMAL_TIMELOCK: "", // To be deployed + NORMAL_TIMELOCK: "0x1730527a0f0930269313D77A317361b42971a67E", GUARDIAN: "0xa2f83de95E9F28eD443132C331B6a9C9B7a9F866", GENERIC_TEST_USER_ACCOUNT: "0x6f057A858171e187124ddEDF034dAc63De5dE5dB", RESILIENT_ORACLE: "0x748853B3bE26c46b4562Fd314dfb82708F395bDf", @@ -176,6 +176,9 @@ export const NETWORK_ADDRESSES = { XVS_VAULT_PROXY: "0x825f9EE3b2b1C159a5444A111A70607f3918564e", POOL_REGISTRY: "0x1401404e6279BB8C06E5E3999eCA3e2008B46A76", VTREASURY: "0x943eBE4460a12F551D60A68f510Ea10CD8d564BA", + ENDPOINT: "0x99b6359ce8E0eBdC27eBeDb76FE28F29303E78fF", + LZ_LIBRARY: "0xC6d12200b743A8F7e6b7228B8E920A71d94FA7Fb", + OMNICHAIN_GOVERNANCE_EXECUTOR: "0x83F79CfbaEee738173c0dfd866796743F4E25C9e", }, zksyncmainnet: { NORMAL_TIMELOCK: "", // To be deployed diff --git a/src/types.ts b/src/types.ts index bcc60a571..5c39ced0e 100644 --- a/src/types.ts +++ b/src/types.ts @@ -16,7 +16,8 @@ export type REMOTE_NETWORKS = | "opbnbtestnet" | "opbnbmainnet" | "arbitrumsepolia" - | "arbitrumone"; + | "arbitrumone" + | "zksyncsepolia"; export const REMOTE_TESTNET_NETWORKS = ["sepolia", "opbnbtestnet", "arbitrumsepolia", "zksyncsepolia"]; export const REMOTE_MAINNET_NETWORKS = ["ethereum", "opbnbmainnet", "arbitrumone", "zksyncmainnet"]; diff --git a/src/utils.ts b/src/utils.ts index 14cb60edc..54abb4fd2 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -143,6 +143,14 @@ export async function mineBlocks(blocks: NumberLike = 1, options: { interval?: N params: [blocksHex, intervalHex], }); } +export const mineOnZksync = async (blocks: number) => { + const blockTimestamp = (await ethers.provider.getBlock("latest")).timestamp; + // Actual timestamp on which block will get mine (assuming 1 sec/block) + const timestampOfBlocks = blocks * 1; + const targetTimestamp = blockTimestamp + timestampOfBlocks; + await ethers.provider.send("evm_setNextBlockTimestamp", [targetTimestamp.toString(16)]); + await mineBlocks(); +}; const getAdapterParam = (noOfCommands: number): string => { const requiredGas = calculateGasForAdapterParam(noOfCommands); diff --git a/src/vip-framework/index.ts b/src/vip-framework/index.ts index ff4bc7343..858c233e6 100644 --- a/src/vip-framework/index.ts +++ b/src/vip-framework/index.ts @@ -16,6 +16,8 @@ import { getPayload, getSourceChainId, initMainnetUser, + mineBlocks, + mineOnZksync, setForkBlock, } from "../utils"; import ENDPOINT_ABI from "./abi/LzEndpoint.json"; @@ -242,17 +244,25 @@ export const testForkedNetworkVipCommands = (description: string, proposal: Prop inboundNonce.add(1), gasLimit, ethers.utils.defaultAbiCoder.encode(["bytes", "uint256"], [payload, proposalId]), - { gasLimit: gasLimit }, + { gasLimit: gasLimit, maxFeePerGas: 2 * 10 ** 8 }, ); await tx.wait(); expect(await executor.queued(proposalId)).to.be.true; }); it("should be executed successfully", async () => { - await mineUpTo((await ethers.provider.getBlockNumber()) + DELAY_BLOCKS[proposalType]); + if (FORKED_NETWORK == "zksyncsepolia" || FORKED_NETWORK == "zksyncmainnet") { + await mineOnZksync((await ethers.provider.getBlockNumber()) + DELAY_BLOCKS[proposalType]); + } else { + await mineUpTo((await ethers.provider.getBlockNumber()) + DELAY_BLOCKS[proposalType]); + } const blockchainProposal = await executor.proposals(proposalId); + await ethers.provider.send("evm_setNextBlockTimestamp", [blockchainProposal.eta.toString(16)]); + await mineBlocks(); + await time.increaseTo(blockchainProposal.eta.toNumber()); - const tx = await executor.execute(proposalId); + const tx = await executor.execute(proposalId, { maxFeePerGas: 200000000 }); + await tx.wait(); if (options.callbackAfterExecution) { await options.callbackAfterExecution(tx); diff --git a/vips/vip-365/bsctestnet.ts b/vips/vip-365/bsctestnet.ts new file mode 100644 index 000000000..09ec70cad --- /dev/null +++ b/vips/vip-365/bsctestnet.ts @@ -0,0 +1,173 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +const { zksyncsepolia } = NETWORK_ADDRESSES; +export const OMNICHAIN_PROPOSAL_SENDER = "0xCfD34AEB46b1CB4779c945854d405E91D27A1899"; + +export const ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER = "0xa34607D58146FA02aF5f920f29C3D916acAb0bC5"; +export const ZKSYNCSEPOLIA_ACM = "0xD07f543d47c3a8997D6079958308e981AC14CD01"; + +export const MAX_DAILY_LIMIT = 100; + +const ZKSYNCSEPOLIA_CHAIN_ID = LzChainId.zksyncsepolia; + +const vip365 = () => { + const meta = { + version: "v2", + title: "VIP-365 Enable Multichain Governance on zksync sepolia (1/2)", + description: `### Summary + +`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: OMNICHAIN_PROPOSAL_SENDER, + signature: "setMaxDailyLimit(uint16,uint256)", + params: [ZKSYNCSEPOLIA_CHAIN_ID, MAX_DAILY_LIMIT], + }, + { + target: OMNICHAIN_PROPOSAL_SENDER, + signature: "setTrustedRemoteAddress(uint16,bytes)", + params: [ZKSYNCSEPOLIA_CHAIN_ID, zksyncsepolia.OMNICHAIN_GOVERNANCE_EXECUTOR], + }, + + { + target: ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + signature: "acceptOwnership()", + params: [], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setSrcChainId(uint16)", zksyncsepolia.NORMAL_TIMELOCK], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "transferBridgeOwnership(address)", + zksyncsepolia.NORMAL_TIMELOCK, + ], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setSendVersion(uint16)", zksyncsepolia.NORMAL_TIMELOCK], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setReceiveVersion(uint16)", zksyncsepolia.NORMAL_TIMELOCK], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "setMaxDailyReceiveLimit(uint256)", + zksyncsepolia.NORMAL_TIMELOCK, + ], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "pause()", zksyncsepolia.NORMAL_TIMELOCK], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setPrecrime(address)", zksyncsepolia.NORMAL_TIMELOCK], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "setMinDstGas(uint16,uint16,uint256)", + zksyncsepolia.NORMAL_TIMELOCK, + ], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "setPayloadSizeLimit(uint16,uint256)", + zksyncsepolia.NORMAL_TIMELOCK, + ], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "setConfig(uint16,uint16,uint256,bytes)", + zksyncsepolia.NORMAL_TIMELOCK, + ], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "addTimelocks(address[])", zksyncsepolia.NORMAL_TIMELOCK], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "setTrustedRemoteAddress(uint16,bytes)", + zksyncsepolia.NORMAL_TIMELOCK, + ], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "setTimelockPendingAdmin(address,uint8)", + zksyncsepolia.NORMAL_TIMELOCK, + ], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "retryMessage(uint16,bytes,uint64,bytes)", + zksyncsepolia.NORMAL_TIMELOCK, + ], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setGuardian(address)", zksyncsepolia.NORMAL_TIMELOCK], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip365; diff --git a/vips/vip-366/bsctestnet.ts b/vips/vip-366/bsctestnet.ts new file mode 100644 index 000000000..cc3c9b205 --- /dev/null +++ b/vips/vip-366/bsctestnet.ts @@ -0,0 +1,132 @@ +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +const ZKSYNCSEPOLIA_FASTTRACK_TIMELOCK = "0xb055e028b27d53a455a6c040a6952e44E9E615c4"; +const ZKSYNCSEPOLIA_CRITICAL_TIMELOCK = "0x0E6138bE0FA1915efC73670a20A10EFd720a6Cc8"; +export const ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER = "0xa34607D58146FA02aF5f920f29C3D916acAb0bC5"; +export const ZKSYNCSEPOLIA_ACM = "0xD07f543d47c3a8997D6079958308e981AC14CD01"; + +const ZKSYNCSEPOLIA_CHAIN_ID = LzChainId.zksyncsepolia; + +const vip366 = () => { + const meta = { + version: "v2", + title: "VIP-366 Enable Multichain Governance on Zksync sepolia (2/2)", + description: `### Description + +Related with the VIP-366, if passed, this VIP will grant permission to Fast-track and Critical timelocks to execute privilege commands on the OmnichainProposalExecutor on Zksync sepolia. Review VIP-365 for more details. + +### References +`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setReceiveVersion(uint16)", ZKSYNCSEPOLIA_FASTTRACK_TIMELOCK], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setReceiveVersion(uint16)", ZKSYNCSEPOLIA_CRITICAL_TIMELOCK], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "setMaxDailyReceiveLimit(uint256)", + ZKSYNCSEPOLIA_FASTTRACK_TIMELOCK, + ], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "setMaxDailyReceiveLimit(uint256)", + ZKSYNCSEPOLIA_CRITICAL_TIMELOCK, + ], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "pause()", ZKSYNCSEPOLIA_FASTTRACK_TIMELOCK], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "pause()", ZKSYNCSEPOLIA_CRITICAL_TIMELOCK], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "setConfig(uint16,uint16,uint256,bytes)", + ZKSYNCSEPOLIA_FASTTRACK_TIMELOCK, + ], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "setConfig(uint16,uint16,uint256,bytes)", + ZKSYNCSEPOLIA_CRITICAL_TIMELOCK, + ], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "addTimelocks(address[])", ZKSYNCSEPOLIA_FASTTRACK_TIMELOCK], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "addTimelocks(address[])", ZKSYNCSEPOLIA_CRITICAL_TIMELOCK], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "retryMessage(uint16,bytes,uint64,bytes)", + ZKSYNCSEPOLIA_FASTTRACK_TIMELOCK, + ], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + + { + target: ZKSYNCSEPOLIA_ACM, + signature: "giveCallPermission(address,string,address)", + params: [ + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + "retryMessage(uint16,bytes,uint64,bytes)", + ZKSYNCSEPOLIA_CRITICAL_TIMELOCK, + ], + dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip366; From a5c31829a09ee6afc6bdb1bded95e778c960ad58 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Tue, 17 Sep 2024 18:40:53 +0530 Subject: [PATCH 002/178] refactor: network name and vip framework --- hardhat.config.zksync.ts | 6 ++-- .../zksyncsepolia/vip-010/index.ts | 4 +-- simulations/vip-365/zksyncsepolia.ts | 2 +- simulations/vip-366/zksyncsepolia.ts | 2 +- src/utils.ts | 8 ++--- src/vip-framework/index.ts | 35 +++++++++++++------ 6 files changed, 36 insertions(+), 21 deletions(-) diff --git a/hardhat.config.zksync.ts b/hardhat.config.zksync.ts index 7a02859e6..583458f71 100644 --- a/hardhat.config.zksync.ts +++ b/hardhat.config.zksync.ts @@ -40,7 +40,7 @@ task("test", "Update fork config") .setAction(async function (taskArguments, hre, runSuper) { const { fork } = taskArguments; - if (hre.network.name === "zkSyncTestNode") { + if (hre.network.name === "zksynctestnode") { if (!process.env["ZKSYNC_ERA_LOCAL_TEST_NODE"]) { throw new Error("ZKSYNC_ERA_LOCAL_TEST_NODE env variable is not set"); } @@ -61,7 +61,7 @@ task("test", "Update fork config") allowUnlimitedContractSize: false, loggingEnabled: false, forking: - hre.network.name === "zkSyncTestNode" + hre.network.name === "zksynctestnode" ? { enabled: false, url: process.env["ZKSYNC_ERA_LOCAL_TEST_NODE"] as string, @@ -137,7 +137,7 @@ const config: HardhatUserConfig = { blockGasLimit: BLOCK_GAS_LIMIT_PER_NETWORK.zksyncmainnet, zksync: true, }, - zkSyncTestNode: { + zksynctestnode: { url: process.env.ZKSYNC_ERA_LOCAL_TEST_NODE || "http://localhost:8011", chainId: 260, accounts: DEPLOYER_PRIVATE_KEY ? [`0x${DEPLOYER_PRIVATE_KEY}`] : [], diff --git a/multisig/simulations/zksyncsepolia/vip-010/index.ts b/multisig/simulations/zksyncsepolia/vip-010/index.ts index 7f0b96c1d..e91f8531b 100644 --- a/multisig/simulations/zksyncsepolia/vip-010/index.ts +++ b/multisig/simulations/zksyncsepolia/vip-010/index.ts @@ -4,7 +4,7 @@ import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { forking, pretendExecutingVip } from "src/vip-framework"; -import vip009, { +import vip010, { ZKSYNCSEPOLIA_ACM, ZKSYNCSEPOLIA_NORMAL_TIMELOCK, ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, @@ -46,7 +46,7 @@ forking(3771669, async () => { }); describe("Post-VIP behavior", async () => { before(async () => { - await pretendExecutingVip(await vip009()); + await pretendExecutingVip(await vip010()); }); it("Normal Timelock has default admin role", async () => { const hasRole = await acm.hasRole(defaultAdminRole, ZKSYNCSEPOLIA_NORMAL_TIMELOCK); diff --git a/simulations/vip-365/zksyncsepolia.ts b/simulations/vip-365/zksyncsepolia.ts index 5cd8838e4..e42cb42a5 100644 --- a/simulations/vip-365/zksyncsepolia.ts +++ b/simulations/vip-365/zksyncsepolia.ts @@ -54,7 +54,7 @@ forking(3771669, async () => { expect(await executor.proposalTimelocks(2)).equals(CRITICAL_TIMELOCK); // Check trusted remote - expect(await executor.trustedRemoteLookup(LzChainId.bscmainnet)).equals( + expect(await executor.trustedRemoteLookup(LzChainId.bsctestnet)).equals( ethers.utils.solidityPack( ["address", "address"], [getOmnichainProposalSenderAddress(), zksyncsepolia.OMNICHAIN_GOVERNANCE_EXECUTOR], diff --git a/simulations/vip-366/zksyncsepolia.ts b/simulations/vip-366/zksyncsepolia.ts index 3ebb050de..9237d82e8 100644 --- a/simulations/vip-366/zksyncsepolia.ts +++ b/simulations/vip-366/zksyncsepolia.ts @@ -1,11 +1,11 @@ import { expect } from "chai"; import { BigNumber, Contract } from "ethers"; import { ethers } from "hardhat"; -import vip010 from "multisig/proposals/zksyncsepolia/vip-010"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; +import vip010 from "../../multisig/proposals/zksyncsepolia/vip-010"; import vip366 from "../../vips/vip-366/bsctestnet"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_GOVERNANCE_EXECUTOR_ABI from "./abi/OmnichainGovernanceExecutor_ABI.json"; diff --git a/src/utils.ts b/src/utils.ts index 54abb4fd2..db2452a53 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -48,8 +48,8 @@ export const getPayload = (proposal: Proposal) => { const gasUsedPerCommand = 300000; export async function setForkBlock(_blockNumber: number) { - if (network.name === "zkSyncTestNode") { - console.log("zkSyncTestNode network does not support forking, skipping fork"); + if (network.name === "zksynctestnode") { + console.log("zksynctestnode network does not support forking, skipping fork"); return; } @@ -97,8 +97,8 @@ export const initMainnetUser = async (user: string, balance: NumberLike) => { let signer = await ethers.getSigner(user); // zksync test node provider does not support default impersonation - if (network.name === "zkSyncTestNode") { - provider = new ethers.providers.JsonRpcProvider(config.networks.hardhat.forking?.url); + if (network.name === "zksynctestnode" && config.networks.hardhat.forking?.url) { + provider = new ethers.providers.JsonRpcProvider({ url: config.networks.hardhat.forking.url, timeout: 1200000 }); signer = provider.getSigner(user) as unknown as SignerWithAddress; } diff --git a/src/vip-framework/index.ts b/src/vip-framework/index.ts index 858c233e6..86c84caef 100644 --- a/src/vip-framework/index.ts +++ b/src/vip-framework/index.ts @@ -3,7 +3,7 @@ import { loadFixture, mine, mineUpTo, time } from "@nomicfoundation/hardhat-netw import { SignerWithAddress } from "@nomiclabs/hardhat-ethers/signers"; import { expect } from "chai"; import cliProgress from "cli-progress"; -import { Contract, ContractInterface } from "ethers"; +import { BigNumber, Contract, ContractInterface } from "ethers"; import { FORKED_NETWORK, ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "../networkAddresses"; @@ -235,7 +235,16 @@ export const testForkedNetworkVipCommands = (description: string, proposal: Prop const srcChainId = getSourceChainId(FORKED_NETWORK as REMOTE_NETWORKS); const inboundNonce = await endpoint.connect(impersonatedLibrary).getInboundNonce(srcChainId, srcAddress); const gasLimit = calculateGasForAdapterParam(targets.length); - const tx = await endpoint + + const feeData = await ethers.provider.getFeeData(); + const txnParams: { maxFeePerGas?: BigNumber; gasLimit: number } = { gasLimit: gasLimit }; + + if (feeData.maxFeePerGas) { + // Sometimes the gas estimation is wrong with some networks like zksync + txnParams.maxFeePerGas = feeData.maxFeePerGas.mul(15).div(10); + } + + await endpoint .connect(impersonatedLibrary) .receivePayload( srcChainId, @@ -244,25 +253,31 @@ export const testForkedNetworkVipCommands = (description: string, proposal: Prop inboundNonce.add(1), gasLimit, ethers.utils.defaultAbiCoder.encode(["bytes", "uint256"], [payload, proposalId]), - { gasLimit: gasLimit, maxFeePerGas: 2 * 10 ** 8 }, + txnParams, ); - await tx.wait(); + expect(await executor.queued(proposalId)).to.be.true; }); it("should be executed successfully", async () => { if (FORKED_NETWORK == "zksyncsepolia" || FORKED_NETWORK == "zksyncmainnet") { - await mineOnZksync((await ethers.provider.getBlockNumber()) + DELAY_BLOCKS[proposalType]); + await mineOnZksync(DELAY_BLOCKS[proposalType]); } else { - await mineUpTo((await ethers.provider.getBlockNumber()) + DELAY_BLOCKS[proposalType]); + await mine(DELAY_BLOCKS[proposalType]); } const blockchainProposal = await executor.proposals(proposalId); - await ethers.provider.send("evm_setNextBlockTimestamp", [blockchainProposal.eta.toString(16)]); + await ethers.provider.send("evm_setNextBlockTimestamp", [blockchainProposal.eta.toHexString()]); await mineBlocks(); - await time.increaseTo(blockchainProposal.eta.toNumber()); - const tx = await executor.execute(proposalId, { maxFeePerGas: 200000000 }); - await tx.wait(); + const feeData = await ethers.provider.getFeeData(); + const txnParams: { maxFeePerGas?: BigNumber } = {}; + + if (feeData.maxFeePerGas) { + // Sometimes the gas estimation is wrong with some networks like zksync + txnParams.maxFeePerGas = feeData.maxFeePerGas.mul(15).div(10); + } + + const tx = await executor.execute(proposalId, txnParams); if (options.callbackAfterExecution) { await options.callbackAfterExecution(tx); From 43c5c5a7e9167002a0d016db0675bfc5d9f99b81 Mon Sep 17 00:00:00 2001 From: Narayan Prusty Date: Tue, 24 Sep 2024 23:16:52 +0400 Subject: [PATCH 003/178] fix: added multisig txns to transfer ownership --- .../proposals/arbitrumone/vip-014/index.ts | 135 ++++++++++++ .../arbitrumsepolia/vip-014/index.ts | 136 ++++++++++++ multisig/proposals/ethereum/vip-061/index.ts | 197 ++++++++++++++++++ .../proposals/opbnbmainnet/vip-021/index.ts | 111 ++++++++++ .../proposals/opbnbtestnet/vip-021/index.ts | 109 ++++++++++ multisig/proposals/sepolia/vip-060/index.ts | 188 +++++++++++++++++ 6 files changed, 876 insertions(+) create mode 100644 multisig/proposals/arbitrumone/vip-014/index.ts create mode 100644 multisig/proposals/arbitrumsepolia/vip-014/index.ts create mode 100644 multisig/proposals/ethereum/vip-061/index.ts create mode 100644 multisig/proposals/opbnbmainnet/vip-021/index.ts create mode 100644 multisig/proposals/opbnbtestnet/vip-021/index.ts create mode 100644 multisig/proposals/sepolia/vip-060/index.ts diff --git a/multisig/proposals/arbitrumone/vip-014/index.ts b/multisig/proposals/arbitrumone/vip-014/index.ts new file mode 100644 index 000000000..25f3f2287 --- /dev/null +++ b/multisig/proposals/arbitrumone/vip-014/index.ts @@ -0,0 +1,135 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { makeProposal } from "src/utils"; + +const { arbitrumone } = NETWORK_ADDRESSES; + +export const DEFAULT_PROXY_ADMIN = "0xF6fF3e9459227f0cDE8B102b90bE25960317b216"; +export const ACM = "0xD9dD18EB0cf10CbA837677f28A8F9Bda4bc2b157"; +export const PRIME = "0xFE69720424C954A2da05648a0FAC84f9bf11Ef49"; +export const PLP = "0x86bf21dB200f29F21253080942Be8af61046Ec29"; +export const REWARD_DISTRIBUTORS = ["0x53b488baA4052094495b6De9E5505FE1Ee3EAc7a"]; +export const PSR = "0xF9263eaF7eB50815194f26aCcAB6765820B13D41"; +export const COMPTROLLER_BEACON = "0x8b6c2E8672504523Ca3a29a5527EcF47fC7d43FC"; +export const VTOKEN_BEACON = "0xE9381D8CA7006c12Ae9eB97890575E705996fa66"; +export const POOL_REGISTRY = "0x382238f07Bc4Fe4aA99e561adE8A4164b5f815DA"; +export const XVS_STORE = "0x507D9923c954AAD8eC530ed8Dedb75bFc893Ec5e"; +export const COMPTROLLERS = ["0x317c1A5739F39046E20b08ac9BeEa3f10fD43326"]; +export const XVS_BRIDGE_ADMIN_PROXY = "0xf5d81C6F7DAA3F97A6265C8441f92eFda22Ad784"; +export const XVS = "0xc1Eb7689147C81aC840d4FF0D298489fc7986d52"; +export const BOUND_VALIDATOR = "0x2245FA2420925Cd3C2D889Ddc5bA1aefEF0E14CF"; + +export const VTOKENS = [ + "0xaDa57840B372D4c28623E87FC175dE8490792811", + "0x68a34332983f4Bf866768DD6D6E638b02eF5e1f0", + "0xB9F9117d4200dC296F9AcD1e8bE1937df834a2fD", + "0x7D8609f8da70fF9027E9bc5229Af4F6727662707", + "0xAeB0FEd69354f34831fe1D16475D9A83ddaCaDA6", +]; + +const vip014 = () => { + return makeProposal([ + { + target: DEFAULT_PROXY_ADMIN, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }, + { + target: PRIME, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }, + { + target: PLP, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }, + ...REWARD_DISTRIBUTORS.map(rewardDistributor => { + return { + target: rewardDistributor, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }; + }), + { + target: PSR, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }, + { + target: COMPTROLLER_BEACON, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }, + { + target: VTOKEN_BEACON, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }, + { + target: POOL_REGISTRY, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }, + ...COMPTROLLERS.map(comptroller => { + return { + target: comptroller, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }; + }), + ...VTOKENS.map(comptroller => { + return { + target: comptroller, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }; + }), + { + target: arbitrumone.XVS_VAULT_PROXY, + signature: "_setPendingAdmin(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }, + { + target: XVS_STORE, + signature: "setPendingAdmin(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }, + { + target: XVS_BRIDGE_ADMIN_PROXY, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }, + { + target: XVS, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }, + { + target: arbitrumone.RESILIENT_ORACLE, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }, + { + target: arbitrumone.CHAINLINK_ORACLE, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }, + { + target: arbitrumone.REDSTONE_ORACLE, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }, + { + target: BOUND_VALIDATOR, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }, + { + target: arbitrumone.VTREASURY, + signature: "transferOwnership(address)", + params: [arbitrumone.NORMAL_TIMELOCK], + }, + ]); +}; + +export default vip014; \ No newline at end of file diff --git a/multisig/proposals/arbitrumsepolia/vip-014/index.ts b/multisig/proposals/arbitrumsepolia/vip-014/index.ts new file mode 100644 index 000000000..c3d11cdfa --- /dev/null +++ b/multisig/proposals/arbitrumsepolia/vip-014/index.ts @@ -0,0 +1,136 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { makeProposal } from "src/utils"; + +const { arbitrumsepolia } = NETWORK_ADDRESSES; +export const DEFAULT_PROXY_ADMIN = "0xA78A1Df376c3CEeBC5Fab574fe6EdDbbF76fd03e"; +export const PRIME = "0xadb04ac4942683bc41e27d18234c8dc884786e89"; +export const PLP = "0xe82c2c10f55d3268126c29ec813dc6f086904694"; +export const REWARD_DISTRIBUTORS = ["0x6c65135d102e2Dfa1b0852351cF9b2cbc1788972"]; +export const PSR = "0x09267d30798B59c581ce54E861A084C6FC298666"; +export const COMPTROLLER_BEACON = "0x12Dcb8D9F1eE7Ad7410F5B36B07bcC7891ab4cEf"; +export const VTOKEN_BEACON = "0x74ae9919F5866cE148c81331a5FCdE71b81c4056"; +export const ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; +export const POOL_REGISTRY = "0xf93Df3135e0D555185c0BC888073374cA551C5fE"; + +export const COMPTROLLERS = ["0x006D44b6f5927b3eD83bD0c1C36Fb1A3BaCaC208"]; +export const XVS_STORE = "0x4e909DA6693215dC630104715c035B159dDb67Dd"; +export const XVS_BRIDGE_ADMIN_PROXY = "0xc94578caCC89a29B044a0a1D54d20d48A645E5C8"; +export const XVS = "0x877Dc896e7b13096D3827872e396927BbE704407"; + +export const VTOKENS = [ + "0x49FB90A5815904649C44B87001a160C1301D6a2C", + "0x807dCB6946dDF4C5C6446B1B07ACd248B08F45e2", + "0xdEFbf0F9Ab6CdDd0a1FdDC894b358D0c0a39B052", + "0xd9d1e754464eFc7493B177d2c7be04816E089b4C", + "0x292Ec2b45C549Bc2c6B31937dBd511beaAEabea8", +]; +export const BOUND_VALIDATOR = "0xfe6bc1545Cc14C131bacA97476D6035ffcC0b889"; + + +const vip014 = () => { + return makeProposal([ + { + target: DEFAULT_PROXY_ADMIN, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }, + { + target: PRIME, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }, + { + target: PLP, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }, + ...REWARD_DISTRIBUTORS.map(rewardDistributor => { + return { + target: rewardDistributor, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }; + }), + { + target: PSR, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }, + { + target: COMPTROLLER_BEACON, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }, + { + target: VTOKEN_BEACON, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }, + { + target: POOL_REGISTRY, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }, + ...COMPTROLLERS.map(comptroller => { + return { + target: comptroller, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }; + }), + ...VTOKENS.map(comptroller => { + return { + target: comptroller, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }; + }), + { + target: arbitrumsepolia.XVS_VAULT_PROXY, + signature: "_setPendingAdmin(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }, + { + target: XVS_STORE, + signature: "setPendingAdmin(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }, + { + target: XVS_BRIDGE_ADMIN_PROXY, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }, + { + target: XVS, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }, + { + target: arbitrumsepolia.RESILIENT_ORACLE, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }, + { + target: arbitrumsepolia.CHAINLINK_ORACLE, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }, + { + target: arbitrumsepolia.REDSTONE_ORACLE, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }, + { + target: BOUND_VALIDATOR, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }, + { + target: arbitrumsepolia.VTREASURY, + signature: "transferOwnership(address)", + params: [arbitrumsepolia.NORMAL_TIMELOCK], + }, + ]); +}; + +export default vip014; \ No newline at end of file diff --git a/multisig/proposals/ethereum/vip-061/index.ts b/multisig/proposals/ethereum/vip-061/index.ts new file mode 100644 index 000000000..afe78d153 --- /dev/null +++ b/multisig/proposals/ethereum/vip-061/index.ts @@ -0,0 +1,197 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { makeProposal } from "src/utils"; + +const { ethereum } = NETWORK_ADDRESSES; +export const DEFAULT_PROXY_ADMIN = "0x567e4cc5e085d09f66f836fa8279f38b4e5866b9"; +export const CONVERTERS = [ + "0xaE39C38AF957338b3cEE2b3E5d825ea88df02EfE", + "0x4f55cb0a24D5542a3478B0E284259A6B850B06BD", + "0xcEB9503f10B781E30213c0b320bCf3b3cE54216E", + "0xDcCDE673Cd8988745dA384A7083B0bd22085dEA0", + "0xb8fD67f215117FADeF06447Af31590309750529D", + "0x1FD30e761C3296fE36D9067b1e398FD97B4C0407", +]; +export const SINGLE_TOKEN_CONVERTER_BEACON = "0x5C0b5D09388F2BA6441E74D40666C4d96e4527D1"; +export const CONVERTER_NETWORK = "0x232CC47AECCC55C2CAcE4372f5B268b27ef7cac8"; +export const PRIME = "0x14C4525f47A7f7C984474979c57a2Dccb8EACB39"; +export const PLP = "0x8ba6aFfd0e7Bcd0028D1639225C84DdCf53D8872"; +export const REWARD_DISTRIBUTORS = [ + "0x134bfDEa7e68733921Bc6A87159FB0d68aBc6Cf8", + "0x76611EEA26aF8842281B56Bb742129E77133592F", + "0x886767B62C7ACD601672607373048FFD96Cf27B2", + "0x8473B767F68250F5309bae939337136a899E43F9", + "0x5f65A7b60b4F91229B8484F80bc2EEc52758EAf9", + "0x461dE281c453F447200D67C9Dd31b3046c8f49f8", + "0x7A91bEd36D96E4e644d3A181c287E0fcf9E9cc98", + "0xe72Aa7BaB160eaa2605964D2379AA56Cb4b9A1BB", + "0xDCB0CfA130496c749738Acbe2d6aA06C7C320f06", + "0x1e25CF968f12850003Db17E0Dba32108509C4359", +]; +export const PSR = "0x8c8c8530464f7D95552A11eC31Adbd4dC4AC4d3E"; +export const COMPTROLLER_BEACON = "0xAE2C3F21896c02510aA187BdA0791cDA77083708"; +export const VTOKEN_BEACON = "0xfc08aADC7a1A93857f6296C3fb78aBA1d286533a"; +export const ETHEREUM_ACM = "0x230058da2D23eb8836EC5DB7037ef7250c56E25E"; +export const POOL_REGISTRY = "0x61CAff113CCaf05FFc6540302c37adcf077C5179"; + +export const COMPTROLLERS = [ + "0x687a01ecF6d3907658f7A7c714749fAC32336D1B", + "0x67aA3eCc5831a65A5Ba7be76BED3B5dc7DB60796", + "0xF522cd0360EF8c2FF48B648d53EA1717Ec0F3Ac3", +]; + +export const VTOKENS = [ + "0x672208C10aaAA2F9A6719F449C4C8227bc0BC202", + "0xd8AdD9B41D4E1cd64Edad8722AB0bA8D35536657", + "0x4fAfbDc4F2a9876Bd1764827b26fb8dc4FD1dB95", + "0x17142a05fe678e9584FA1d88EfAC1bF181bF7ABe", + "0x13eB80FDBe5C5f4a7039728E258A6f05fb3B912b", + "0x17C07e0c232f2f80DfDbd7a95b942D893A4C5ACb", + "0x8C3e3821259B82fFb32B2450A95d2dcbf161C24E", + "0x8716554364f20BCA783cb2BAA744d39361fd1D8d", + "0x7c8ff7d2A1372433726f879BD945fFb250B94c65", + "0x2d499800239C4CD3012473Cb1EAE33562F0A6933", + "0x30aD10Bd5Be62CAb37863C2BfcC6E8fb4fD85BDa", + "0xA854D35664c658280fFf27B6eDC6C4195c3229B3", + "0x76697f8eaeA4bE01C678376aAb97498Ee8f80D5C", + "0xDB6C345f864883a8F4cae87852Ac342589E76D1B", + "0xF9E9Fe17C00a8B96a8ac20c4E344C8688D7b947E", + "0xc82780Db1257C788F262FBbDA960B3706Dfdcaf2", + "0x4a240F0ee138697726C8a3E43eFE6Ac3593432CB", + "0xb4933AF59868986316Ed37fa865C829Eba2df0C7", +]; +export const XVS_STORE = "0x1Db646E1Ab05571AF99e47e8F909801e5C99d37B"; +export const XVS_BRIDGE_ADMIN_PROXY = "0x9C6C95632A8FB3A74f2fB4B7FfC50B003c992b96"; +export const XVS = "0xd3CC9d8f3689B83c91b7B59cAB4946B063EB894A"; +export const BOUND_VALIDATOR = "0x1Cd5f336A1d28Dff445619CC63d3A0329B4d8a58"; +export const SFrxETHOracle = "0x5E06A5f48692E4Fff376fDfCA9E4C0183AAADCD1"; + + +const vip061 = () => { + return makeProposal([ + { + target: DEFAULT_PROXY_ADMIN, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + { + target: SINGLE_TOKEN_CONVERTER_BEACON, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + { + target: CONVERTER_NETWORK, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + ...CONVERTERS.map(converter => { + return { + target: converter, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }; + }), + { + target: PRIME, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + { + target: PLP, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + ...REWARD_DISTRIBUTORS.map(rewardDistributor => { + return { + target: rewardDistributor, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }; + }), + { + target: PSR, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + { + target: COMPTROLLER_BEACON, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + { + target: VTOKEN_BEACON, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + { + target: POOL_REGISTRY, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + ...COMPTROLLERS.map(comptroller => { + return { + target: comptroller, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }; + }), + ...VTOKENS.map(comptroller => { + return { + target: comptroller, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }; + }), + { + target: ethereum.XVS_VAULT_PROXY, + signature: "_setPendingAdmin(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + { + target: XVS_STORE, + signature: "setPendingAdmin(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + { + target: XVS_BRIDGE_ADMIN_PROXY, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + { + target: XVS, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + { + target: ethereum.RESILIENT_ORACLE, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + { + target: ethereum.CHAINLINK_ORACLE, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + { + target: ethereum.REDSTONE_ORACLE, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + { + target: BOUND_VALIDATOR, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + { + target: SFrxETHOracle, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + { + target: ethereum.VTREASURY, + signature: "transferOwnership(address)", + params: [ethereum.NORMAL_TIMELOCK], + }, + ]); +}; + +export default vip061; \ No newline at end of file diff --git a/multisig/proposals/opbnbmainnet/vip-021/index.ts b/multisig/proposals/opbnbmainnet/vip-021/index.ts new file mode 100644 index 000000000..0cf2c27bc --- /dev/null +++ b/multisig/proposals/opbnbmainnet/vip-021/index.ts @@ -0,0 +1,111 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { makeProposal } from "src/utils"; + +const { opbnbmainnet } = NETWORK_ADDRESSES; +export const DEFAULT_PROXY_ADMIN = "0xF77bD1D893F67b3EB2Cd256239c98Ba3F238fb52"; +export const PSR = "0xA2EDD515B75aBD009161B15909C19959484B0C1e"; +export const COMPTROLLER_BEACON = "0x11C3e19236ce17729FC66b74B537de00C54d44e7"; +export const VTOKEN_BEACON = "0xfeD1d3a13597c5aBc893Af41ED5cb17e64c847c7"; +export const ACM = "0xA60Deae5344F1152426cA440fb6552eA0e3005D6"; +export const POOL_REGISTRY = "0x345a030Ad22e2317ac52811AC41C1A63cfa13aEe"; + +export const COMPTROLLERS = ["0xD6e3E2A1d8d95caE355D15b3b9f8E5c2511874dd"]; + +export const VTOKENS = [ + "0xED827b80Bd838192EA95002C01B5c6dA8354219a", + "0x509e81eF638D489936FA85BC58F52Df01190d26C", + "0x13B492B8A03d072Bab5C54AC91Dba5b830a50917", + "0xb7a01Ba126830692238521a1aA7E7A7509410b8e", + "0x53d11cB8A0e5320Cd7229C3acc80d1A0707F2672", +]; +export const XVS_STORE = "0xc3279442a5aCaCF0A2EcB015d1cDDBb3E0f3F775"; +export const XVS_BRIDGE_ADMIN_PROXY = "0x52fcE05aDbf6103d71ed2BA8Be7A317282731831"; +export const XVS = "0x3E2e61F1c075881F3fB8dd568043d8c221fd5c61"; +export const BOUND_VALIDATOR = "0xd1f80C371C6E2Fa395A5574DB3E3b4dAf43dadCE"; + + +const vip021 = () => { + return makeProposal([ + { + target: DEFAULT_PROXY_ADMIN, + signature: "transferOwnership(address)", + params: [opbnbmainnet.NORMAL_TIMELOCK], + }, + { + target: PSR, + signature: "transferOwnership(address)", + params: [opbnbmainnet.NORMAL_TIMELOCK], + }, + { + target: COMPTROLLER_BEACON, + signature: "transferOwnership(address)", + params: [opbnbmainnet.NORMAL_TIMELOCK], + }, + { + target: VTOKEN_BEACON, + signature: "transferOwnership(address)", + params: [opbnbmainnet.NORMAL_TIMELOCK], + }, + { + target: POOL_REGISTRY, + signature: "transferOwnership(address)", + params: [opbnbmainnet.NORMAL_TIMELOCK], + }, + ...COMPTROLLERS.map(comptroller => { + return { + target: comptroller, + signature: "transferOwnership(address)", + params: [opbnbmainnet.NORMAL_TIMELOCK], + }; + }), + ...VTOKENS.map(comptroller => { + return { + target: comptroller, + signature: "transferOwnership(address)", + params: [opbnbmainnet.NORMAL_TIMELOCK], + }; + }), + { + target: opbnbmainnet.XVS_VAULT_PROXY, + signature: "_setPendingAdmin(address)", + params: [opbnbmainnet.NORMAL_TIMELOCK], + }, + { + target: XVS_STORE, + signature: "setPendingAdmin(address)", + params: [opbnbmainnet.NORMAL_TIMELOCK], + }, + { + target: XVS_BRIDGE_ADMIN_PROXY, + signature: "transferOwnership(address)", + params: [opbnbmainnet.NORMAL_TIMELOCK], + }, + { + target: XVS, + signature: "transferOwnership(address)", + params: [opbnbmainnet.NORMAL_TIMELOCK], + }, + { + target: opbnbmainnet.RESILIENT_ORACLE, + signature: "transferOwnership(address)", + params: [opbnbmainnet.NORMAL_TIMELOCK], + }, + { + target: opbnbmainnet.BINANCE_ORACLE, + signature: "transferOwnership(address)", + params: [opbnbmainnet.NORMAL_TIMELOCK], + }, + { + target: BOUND_VALIDATOR, + signature: "transferOwnership(address)", + params: [opbnbmainnet.NORMAL_TIMELOCK], + }, + { + target: opbnbmainnet.VTREASURY, + signature: "transferOwnership(address)", + params: [opbnbmainnet.NORMAL_TIMELOCK], + }, + ]); +}; + +export default vip021; \ No newline at end of file diff --git a/multisig/proposals/opbnbtestnet/vip-021/index.ts b/multisig/proposals/opbnbtestnet/vip-021/index.ts new file mode 100644 index 000000000..7c928b931 --- /dev/null +++ b/multisig/proposals/opbnbtestnet/vip-021/index.ts @@ -0,0 +1,109 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { makeProposal } from "src/utils"; + +const { opbnbtestnet } = NETWORK_ADDRESSES; +export const DEFAULT_PROXY_ADMIN = "0xB1281ADC816fba7df64B798D7A0BC4bd2a6d42f4"; +export const PSR = "0xc355dEb1A9289f8C58CFAa076EEdBf51F3A8Da7F"; +export const COMPTROLLER_BEACON = "0x2020BDa1F931E07B14C9d346E2f6D5943b4cd56D"; +export const VTOKEN_BEACON = "0xcc633492097078Ae590C0d11924e82A23f3Ab3E2"; +export const ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; +export const POOL_REGISTRY = "0x560eA4e1cC42591E9f5F5D83Ad2fd65F30128951"; + +export const COMPTROLLERS = ["0x2FCABb31E57F010D623D8d68e1E18Aed11d5A388"]; + +export const VTOKENS = [ + "0x86F82bca79774fc04859966917D2291A68b870A9", + "0x034Cc5097379B13d3Ed5F6c85c8FAf20F48aE480", + "0xe3923805f6E117E51f5387421240a86EF1570abC", + "0xD36a31AcD3d901AeD998da6E24e848798378474e", +]; +export const XVS_STORE = "0x06473fB3f7bF11e2E8EfEcC95aC55ABEFCb2e0A0"; +export const XVS_BRIDGE_ADMIN_PROXY = "0x19252AFD0B2F539C400aEab7d460CBFbf74c17ff"; +export const XVS = "0xc2931B1fEa69b6D6dA65a50363A8D75d285e4da9"; +export const BOUND_VALIDATOR = "0x049537Bb065e6253e9D8D08B45Bf6b753657A746"; + +const vip021 = () => { + return makeProposal([ + { + target: DEFAULT_PROXY_ADMIN, + signature: "transferOwnership(address)", + params: [opbnbtestnet.NORMAL_TIMELOCK], + }, + { + target: PSR, + signature: "transferOwnership(address)", + params: [opbnbtestnet.NORMAL_TIMELOCK], + }, + { + target: COMPTROLLER_BEACON, + signature: "transferOwnership(address)", + params: [opbnbtestnet.NORMAL_TIMELOCK], + }, + { + target: VTOKEN_BEACON, + signature: "transferOwnership(address)", + params: [opbnbtestnet.NORMAL_TIMELOCK], + }, + { + target: POOL_REGISTRY, + signature: "transferOwnership(address)", + params: [opbnbtestnet.NORMAL_TIMELOCK], + }, + ...COMPTROLLERS.map(comptroller => { + return { + target: comptroller, + signature: "transferOwnership(address)", + params: [opbnbtestnet.NORMAL_TIMELOCK], + }; + }), + ...VTOKENS.map(comptroller => { + return { + target: comptroller, + signature: "transferOwnership(address)", + params: [opbnbtestnet.NORMAL_TIMELOCK], + }; + }), + { + target: opbnbtestnet.XVS_VAULT_PROXY, + signature: "_setPendingAdmin(address)", + params: [opbnbtestnet.NORMAL_TIMELOCK], + }, + { + target: XVS_STORE, + signature: "setPendingAdmin(address)", + params: [opbnbtestnet.NORMAL_TIMELOCK], + }, + { + target: XVS_BRIDGE_ADMIN_PROXY, + signature: "transferOwnership(address)", + params: [opbnbtestnet.NORMAL_TIMELOCK], + }, + { + target: XVS, + signature: "transferOwnership(address)", + params: [opbnbtestnet.NORMAL_TIMELOCK], + }, + { + target: opbnbtestnet.RESILIENT_ORACLE, + signature: "transferOwnership(address)", + params: [opbnbtestnet.NORMAL_TIMELOCK], + }, + { + target: opbnbtestnet.BINANCE_ORACLE, + signature: "transferOwnership(address)", + params: [opbnbtestnet.NORMAL_TIMELOCK], + }, + { + target: BOUND_VALIDATOR, + signature: "transferOwnership(address)", + params: [opbnbtestnet.NORMAL_TIMELOCK], + }, + { + target: opbnbtestnet.VTREASURY, + signature: "transferOwnership(address)", + params: [opbnbtestnet.NORMAL_TIMELOCK], + }, + ]); +}; + +export default vip021; \ No newline at end of file diff --git a/multisig/proposals/sepolia/vip-060/index.ts b/multisig/proposals/sepolia/vip-060/index.ts new file mode 100644 index 000000000..bc4ba4268 --- /dev/null +++ b/multisig/proposals/sepolia/vip-060/index.ts @@ -0,0 +1,188 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { makeProposal } from "src/utils"; + +const { sepolia } = NETWORK_ADDRESSES; +export const DEFAULT_PROXY_ADMIN = "0xe98a3110929c6650c73031756288Ec518f65e846"; +export const CONVERTERS = [ + "0xCCB08e5107b406E67Ad8356023dd489CEbc79B40", + "0x3716C24EA86A67cAf890d7C9e4C4505cDDC2F8A2", + "0x511a559a699cBd665546a1F75908f7E9454Bfc67", + "0x8a3937F27921e859db3FDA05729CbCea8cfd82AE", + "0x274a834eFFA8D5479502dD6e78925Bc04ae82B46", + "0xc203bfA9dCB0B5fEC510Db644A494Ff7f4968ed2", +]; +export const SINGLE_TOKEN_CONVERTER_BEACON = "0xb86e532a5333d413A1c35d86cCdF1484B40219eF"; +export const CONVERTER_NETWORK = "0xB5A4208bFC4cC2C4670744849B8fC35B21A690Fa"; +export const PRIME = "0x2Ec432F123FEbb114e6fbf9f4F14baF0B1F14AbC"; +export const PLP = "0x15242a55Ad1842A1aEa09c59cf8366bD2f3CE9B4"; +export const REWARD_DISTRIBUTORS = [ + "0xB60666395bEFeE02a28938b75ea620c7191cA77a", + "0x341f52BfecC10115087e46eB94AA06E384b8925E", + "0x67dA6435b35d43081c7c27685fAbb2662b7f1290", + "0xF6D57F8e37b1cb627470b5254fAb08dE07B49A0F", + "0x4597B9287fE0DF3c5513D66886706E0719bD270f", + "0xec594364d2B7eB3678f351Ac632cC71E718E0F89", + "0x92e8E3C202093A495e98C10f9fcaa5Abe288F74A", +]; +export const PSR = "0xbea70755cc3555708ca11219adB0db4C80F6721B"; +export const COMPTROLLER_BEACON = "0x6cE54143a88CC22500D49D744fb6535D66a8294F"; +export const VTOKEN_BEACON = "0x0463a7E5221EAE1990cEddB51A5821a68cdA6008"; +export const ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; +export const POOL_REGISTRY = "0x758f5715d817e02857Ba40889251201A5aE3E186"; + +export const COMPTROLLERS = ["0x7Aa39ab4BcA897F403425C9C6FDbd0f882Be0D70"]; + +export const VTOKENS = [ + "0xA09cFAd2e138fe6d8FF62df803892cbCb79ED082", + "0x121E3be152F283319310D807ed847E8b98319C1e", + "0xfe050f628bF5278aCfA1e7B13b59fF207e769235", + "0xE23A1fC1545F1b072308c846a38447b23d322Ee2", + "0xF87bceab8DD37489015B426bA931e08A4D787616", + "0x19252AFD0B2F539C400aEab7d460CBFbf74c17ff", + "0x74E708A7F5486ed73CCCAe54B63e71B1988F1383", + "0xc2931B1fEa69b6D6dA65a50363A8D75d285e4da9", + "0x33942B932159A67E3274f54bC4082cbA4A704340", + "0x18995825f033F33fa30CF59c117aD21ff6BdB48c", + "0xc7be132027e191636172798B933202E0f9CAD548", + "0x9Db62c5BBc6fb79416545FcCBDB2204099217b78", + "0xF4C1B7528f8B266D8ADf1a85c91d93114FeDbA2A", + "0x3AF2bE7AbEF0f840b196D99d79F4B803a5dB14a1", + "0x20a83DE526F2CF2fCec2131E07b11F956d8f3Cdf", + "0x83F63118dcAAdAACBFF36D78ffB88dd474309e70", + "0x9f6213dFa9069a5426Fe8fAE73857712E1259Ed4", + "0x0a95088403229331FeF1EB26a11F9d6C8E73f23D", + "0x30c31bA6f4652B548fe7a142A949987c3f3Bf80b", + "0x9C5e7a3B4db931F07A6534f9e44100DDDc78c408", + "0xD5f83FCbb4a62779D0B37b9E603CD19Ad84884F0", + "0x93dff2053D4B08823d8B39F1dCdf8497f15200f4", +]; +export const XVS_STORE = "0x03B868C7858F50900fecE4eBc851199e957b5d3D"; +export const XVS_BRIDGE_ADMIN_PROXY = "0xd3c6bdeeadB2359F726aD4cF42EAa8B7102DAd9B"; +export const XVS = "0x66ebd019E86e0af5f228a0439EBB33f045CBe63E"; +export const BOUND_VALIDATOR = "0x60c4Aa92eEb6884a76b309Dd8B3731ad514d6f9B"; +export const SFrxETHOracle = "0x61EB836afA467677e6b403D504fe69D6940e7996"; + +const vip060 = () => { + return makeProposal([ + { + target: DEFAULT_PROXY_ADMIN, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + { + target: SINGLE_TOKEN_CONVERTER_BEACON, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + { + target: CONVERTER_NETWORK, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + ...CONVERTERS.map(converter => { + return { + target: converter, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }; + }), + { + target: PRIME, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + { + target: PLP, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + ...REWARD_DISTRIBUTORS.map(rewardDistributor => { + return { + target: rewardDistributor, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }; + }), + { + target: PSR, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + { + target: COMPTROLLER_BEACON, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + { + target: VTOKEN_BEACON, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + { + target: POOL_REGISTRY, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + ...COMPTROLLERS.map(comptroller => { + return { + target: comptroller, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }; + }), + ...VTOKENS.map(comptroller => { + return { + target: comptroller, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }; + }), + { + target: sepolia.XVS_VAULT_PROXY, + signature: "_setPendingAdmin(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + { + target: XVS_STORE, + signature: "setPendingAdmin(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + { + target: XVS_BRIDGE_ADMIN_PROXY, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + { + target: XVS, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + { + target: sepolia.RESILIENT_ORACLE, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + { + target: sepolia.CHAINLINK_ORACLE, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + { + target: sepolia.REDSTONE_ORACLE, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + { + target: BOUND_VALIDATOR, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + { + target: SFrxETHOracle, + signature: "transferOwnership(address)", + params: [sepolia.NORMAL_TIMELOCK], + }, + ]); +}; + +export default vip060; \ No newline at end of file From 4954bfef40d7aeb332bcaa57e451f8454c548fa1 Mon Sep 17 00:00:00 2001 From: Narayan Prusty Date: Tue, 24 Sep 2024 23:53:33 +0400 Subject: [PATCH 004/178] fix: added simulations for multisig --- .../proposals/arbitrumone/vip-014/index.ts | 2 +- .../arbitrumsepolia/vip-014/index.ts | 3 +- multisig/proposals/ethereum/vip-061/index.ts | 3 +- .../proposals/opbnbmainnet/vip-021/index.ts | 3 +- .../proposals/opbnbtestnet/vip-021/index.ts | 2 +- multisig/proposals/sepolia/vip-060/index.ts | 2 +- .../arbitrumone/vip-014/abi/Comptroller.json | 929 ++++++++++++++++++ .../vip-014/abi/ComptrollerBeacon.json | 51 + .../vip-014/abi/DefaultProxyAdmin.json | 76 ++ .../arbitrumone/vip-014/abi/PoolRegistry.json | 379 +++++++ .../arbitrumone/vip-014/abi/Prime.json | 763 ++++++++++++++ .../vip-014/abi/PrimeLiquidityProvider.json | 385 ++++++++ .../vip-014/abi/ProtocolShareReserve.json | 356 +++++++ .../vip-014/abi/RewardDistrbutor.json | 532 ++++++++++ .../arbitrumone/vip-014/abi/VToken.json | 861 ++++++++++++++++ .../arbitrumone/vip-014/abi/VTokenBeacon.json | 51 + .../arbitrumone/vip-014/abi/XVSStore.json | 130 +++ .../arbitrumone/vip-014/abi/XVSVault.json | 787 +++++++++++++++ .../vip-014/abi/boundValidator.json | 498 ++++++++++ .../vip-014/abi/chainlinkOracle.json | 459 +++++++++ .../vip-014/abi/resilientOracle.json | 640 ++++++++++++ .../arbitrumone/vip-014/abi/treasury.json | 86 ++ .../arbitrumone/vip-014/abi/xvs.json | 716 ++++++++++++++ .../vip-014/abi/xvsBridgeAdmin.json | 329 +++++++ .../simulations/arbitrumone/vip-014/index.ts | 225 +++++ .../vip-014/abi/Comptroller.json | 929 ++++++++++++++++++ .../vip-014/abi/ComptrollerBeacon.json | 51 + .../vip-014/abi/DefaultProxyAdmin.json | 76 ++ .../vip-014/abi/PoolRegistry.json | 379 +++++++ .../arbitrumsepolia/vip-014/abi/Prime.json | 763 ++++++++++++++ .../vip-014/abi/PrimeLiquidityProvider.json | 385 ++++++++ .../vip-014/abi/ProtocolShareReserve.json | 356 +++++++ .../vip-014/abi/RewardDistrbutor.json | 532 ++++++++++ .../arbitrumsepolia/vip-014/abi/VToken.json | 861 ++++++++++++++++ .../vip-014/abi/VTokenBeacon.json | 51 + .../arbitrumsepolia/vip-014/abi/XVSStore.json | 130 +++ .../arbitrumsepolia/vip-014/abi/XVSVault.json | 787 +++++++++++++++ .../vip-014/abi/boundValidator.json | 498 ++++++++++ .../vip-014/abi/chainlinkOracle.json | 459 +++++++++ .../vip-014/abi/resilientOracle.json | 640 ++++++++++++ .../arbitrumsepolia/vip-014/abi/treasury.json | 86 ++ .../arbitrumsepolia/vip-014/abi/xvs.json | 716 ++++++++++++++ .../vip-014/abi/xvsBridgeAdmin.json | 329 +++++++ .../arbitrumsepolia/vip-014/index.ts | 225 +++++ .../ethereum/vip-061/abi/Comptroller.json | 929 ++++++++++++++++++ .../vip-061/abi/ComptrollerBeacon.json | 51 + .../vip-061/abi/ConverterNetwork.json | 205 ++++ .../vip-061/abi/DefaultProxyAdmin.json | 76 ++ .../ethereum/vip-061/abi/PoolRegistry.json | 379 +++++++ .../ethereum/vip-061/abi/Prime.json | 763 ++++++++++++++ .../vip-061/abi/PrimeLiquidityProvider.json | 385 ++++++++ .../vip-061/abi/ProtocolShareReserve.json | 356 +++++++ .../vip-061/abi/RewardDistrbutor.json | 532 ++++++++++ .../vip-061/abi/SingleTokenConverter.json | 587 +++++++++++ .../abi/SingleTokenConverterBeacon.json | 51 + .../ethereum/vip-061/abi/VToken.json | 861 ++++++++++++++++ .../ethereum/vip-061/abi/VTokenBeacon.json | 51 + .../ethereum/vip-061/abi/XVSStore.json | 130 +++ .../ethereum/vip-061/abi/XVSVault.json | 787 +++++++++++++++ .../ethereum/vip-061/abi/boundValidator.json | 498 ++++++++++ .../ethereum/vip-061/abi/chainlinkOracle.json | 459 +++++++++ .../ethereum/vip-061/abi/resilientOracle.json | 640 ++++++++++++ .../ethereum/vip-061/abi/sFrxETHOracle.json | 148 +++ .../ethereum/vip-061/abi/treasury.json | 86 ++ .../simulations/ethereum/vip-061/abi/xvs.json | 716 ++++++++++++++ .../ethereum/vip-061/abi/xvsBridgeAdmin.json | 329 +++++++ .../simulations/ethereum/vip-061/index.ts | 277 ++++++ .../opbnbmainnet/vip-021/abi/Comptroller.json | 929 ++++++++++++++++++ .../vip-021/abi/ComptrollerBeacon.json | 51 + .../vip-021/abi/ConverterNetwork.json | 205 ++++ .../vip-021/abi/DefaultProxyAdmin.json | 76 ++ .../vip-021/abi/PoolRegistry.json | 379 +++++++ .../opbnbmainnet/vip-021/abi/Prime.json | 763 ++++++++++++++ .../vip-021/abi/PrimeLiquidityProvider.json | 385 ++++++++ .../vip-021/abi/ProtocolShareReserve.json | 356 +++++++ .../vip-021/abi/RewardDistrbutor.json | 532 ++++++++++ .../vip-021/abi/SingleTokenConverter.json | 587 +++++++++++ .../abi/SingleTokenConverterBeacon.json | 51 + .../opbnbmainnet/vip-021/abi/VToken.json | 861 ++++++++++++++++ .../vip-021/abi/VTokenBeacon.json | 51 + .../opbnbmainnet/vip-021/abi/XVSStore.json | 130 +++ .../opbnbmainnet/vip-021/abi/XVSVault.json | 787 +++++++++++++++ .../vip-021/abi/boundValidator.json | 498 ++++++++++ .../vip-021/abi/chainlinkOracle.json | 459 +++++++++ .../vip-021/abi/resilientOracle.json | 640 ++++++++++++ .../vip-021/abi/sFrxETHOracle.json | 148 +++ .../opbnbmainnet/vip-021/abi/treasury.json | 86 ++ .../opbnbmainnet/vip-021/abi/xvs.json | 716 ++++++++++++++ .../vip-021/abi/xvsBridgeAdmin.json | 329 +++++++ .../simulations/opbnbmainnet/vip-021/index.ts | 181 ++++ .../opbnbtestnet/vip-021/abi/Comptroller.json | 929 ++++++++++++++++++ .../vip-021/abi/ComptrollerBeacon.json | 51 + .../vip-021/abi/ConverterNetwork.json | 205 ++++ .../vip-021/abi/DefaultProxyAdmin.json | 76 ++ .../vip-021/abi/PoolRegistry.json | 379 +++++++ .../opbnbtestnet/vip-021/abi/Prime.json | 763 ++++++++++++++ .../vip-021/abi/PrimeLiquidityProvider.json | 385 ++++++++ .../vip-021/abi/ProtocolShareReserve.json | 356 +++++++ .../vip-021/abi/RewardDistrbutor.json | 532 ++++++++++ .../vip-021/abi/SingleTokenConverter.json | 587 +++++++++++ .../abi/SingleTokenConverterBeacon.json | 51 + .../opbnbtestnet/vip-021/abi/VToken.json | 861 ++++++++++++++++ .../vip-021/abi/VTokenBeacon.json | 51 + .../opbnbtestnet/vip-021/abi/XVSStore.json | 130 +++ .../opbnbtestnet/vip-021/abi/XVSVault.json | 787 +++++++++++++++ .../vip-021/abi/boundValidator.json | 498 ++++++++++ .../vip-021/abi/chainlinkOracle.json | 459 +++++++++ .../vip-021/abi/resilientOracle.json | 640 ++++++++++++ .../vip-021/abi/sFrxETHOracle.json | 148 +++ .../opbnbtestnet/vip-021/abi/treasury.json | 86 ++ .../opbnbtestnet/vip-021/abi/xvs.json | 716 ++++++++++++++ .../vip-021/abi/xvsBridgeAdmin.json | 329 +++++++ .../simulations/opbnbtestnet/vip-021/index.ts | 181 ++++ .../sepolia/vip-060/abi/Comptroller.json | 929 ++++++++++++++++++ .../vip-060/abi/ComptrollerBeacon.json | 51 + .../sepolia/vip-060/abi/ConverterNetwork.json | 205 ++++ .../vip-060/abi/DefaultProxyAdmin.json | 76 ++ .../sepolia/vip-060/abi/PoolRegistry.json | 379 +++++++ .../sepolia/vip-060/abi/Prime.json | 763 ++++++++++++++ .../vip-060/abi/PrimeLiquidityProvider.json | 385 ++++++++ .../vip-060/abi/ProtocolShareReserve.json | 356 +++++++ .../sepolia/vip-060/abi/RewardDistrbutor.json | 532 ++++++++++ .../vip-060/abi/SingleTokenConverter.json | 587 +++++++++++ .../abi/SingleTokenConverterBeacon.json | 51 + .../sepolia/vip-060/abi/VToken.json | 861 ++++++++++++++++ .../sepolia/vip-060/abi/VTokenBeacon.json | 51 + .../sepolia/vip-060/abi/XVSStore.json | 130 +++ .../sepolia/vip-060/abi/XVSVault.json | 787 +++++++++++++++ .../sepolia/vip-060/abi/boundValidator.json | 498 ++++++++++ .../sepolia/vip-060/abi/chainlinkOracle.json | 459 +++++++++ .../sepolia/vip-060/abi/resilientOracle.json | 640 ++++++++++++ .../sepolia/vip-060/abi/sFrxETHOracle.json | 148 +++ .../sepolia/vip-060/abi/treasury.json | 86 ++ .../simulations/sepolia/vip-060/abi/xvs.json | 716 ++++++++++++++ .../sepolia/vip-060/abi/xvsBridgeAdmin.json | 329 +++++++ multisig/simulations/sepolia/vip-060/index.ts | 270 +++++ 136 files changed, 53497 insertions(+), 9 deletions(-) create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/Comptroller.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/ComptrollerBeacon.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/DefaultProxyAdmin.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/PoolRegistry.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/Prime.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/PrimeLiquidityProvider.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/ProtocolShareReserve.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/RewardDistrbutor.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/VToken.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/VTokenBeacon.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/XVSStore.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/XVSVault.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/boundValidator.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/chainlinkOracle.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/resilientOracle.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/treasury.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/xvs.json create mode 100644 multisig/simulations/arbitrumone/vip-014/abi/xvsBridgeAdmin.json create mode 100644 multisig/simulations/arbitrumone/vip-014/index.ts create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/Comptroller.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/ComptrollerBeacon.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/DefaultProxyAdmin.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/PoolRegistry.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/Prime.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/PrimeLiquidityProvider.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/ProtocolShareReserve.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/RewardDistrbutor.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/VToken.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/VTokenBeacon.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/XVSStore.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/XVSVault.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/boundValidator.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/chainlinkOracle.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/resilientOracle.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/treasury.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/xvs.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/xvsBridgeAdmin.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-014/index.ts create mode 100644 multisig/simulations/ethereum/vip-061/abi/Comptroller.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/ComptrollerBeacon.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/ConverterNetwork.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/DefaultProxyAdmin.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/PoolRegistry.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/Prime.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/PrimeLiquidityProvider.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/ProtocolShareReserve.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/RewardDistrbutor.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/SingleTokenConverter.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/SingleTokenConverterBeacon.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/VToken.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/VTokenBeacon.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/XVSStore.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/XVSVault.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/boundValidator.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/chainlinkOracle.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/resilientOracle.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/sFrxETHOracle.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/treasury.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/xvs.json create mode 100644 multisig/simulations/ethereum/vip-061/abi/xvsBridgeAdmin.json create mode 100644 multisig/simulations/ethereum/vip-061/index.ts create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/Comptroller.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/ComptrollerBeacon.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/ConverterNetwork.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/DefaultProxyAdmin.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/PoolRegistry.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/Prime.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/PrimeLiquidityProvider.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/ProtocolShareReserve.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/RewardDistrbutor.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/SingleTokenConverter.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/SingleTokenConverterBeacon.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/VToken.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/VTokenBeacon.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/XVSStore.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/XVSVault.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/boundValidator.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/chainlinkOracle.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/resilientOracle.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/sFrxETHOracle.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/treasury.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/xvs.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/xvsBridgeAdmin.json create mode 100644 multisig/simulations/opbnbmainnet/vip-021/index.ts create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/Comptroller.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/ComptrollerBeacon.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/ConverterNetwork.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/DefaultProxyAdmin.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/PoolRegistry.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/Prime.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/PrimeLiquidityProvider.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/ProtocolShareReserve.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/RewardDistrbutor.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/SingleTokenConverter.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/SingleTokenConverterBeacon.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/VToken.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/VTokenBeacon.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/XVSStore.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/XVSVault.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/boundValidator.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/chainlinkOracle.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/resilientOracle.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/sFrxETHOracle.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/treasury.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/xvs.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/xvsBridgeAdmin.json create mode 100644 multisig/simulations/opbnbtestnet/vip-021/index.ts create mode 100644 multisig/simulations/sepolia/vip-060/abi/Comptroller.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/ComptrollerBeacon.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/ConverterNetwork.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/DefaultProxyAdmin.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/PoolRegistry.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/Prime.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/PrimeLiquidityProvider.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/ProtocolShareReserve.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/RewardDistrbutor.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/SingleTokenConverter.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/SingleTokenConverterBeacon.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/VToken.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/VTokenBeacon.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/XVSStore.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/XVSVault.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/boundValidator.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/chainlinkOracle.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/resilientOracle.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/sFrxETHOracle.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/treasury.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/xvs.json create mode 100644 multisig/simulations/sepolia/vip-060/abi/xvsBridgeAdmin.json create mode 100644 multisig/simulations/sepolia/vip-060/index.ts diff --git a/multisig/proposals/arbitrumone/vip-014/index.ts b/multisig/proposals/arbitrumone/vip-014/index.ts index 25f3f2287..72a1e273a 100644 --- a/multisig/proposals/arbitrumone/vip-014/index.ts +++ b/multisig/proposals/arbitrumone/vip-014/index.ts @@ -132,4 +132,4 @@ const vip014 = () => { ]); }; -export default vip014; \ No newline at end of file +export default vip014; diff --git a/multisig/proposals/arbitrumsepolia/vip-014/index.ts b/multisig/proposals/arbitrumsepolia/vip-014/index.ts index c3d11cdfa..5b2de90f6 100644 --- a/multisig/proposals/arbitrumsepolia/vip-014/index.ts +++ b/multisig/proposals/arbitrumsepolia/vip-014/index.ts @@ -26,7 +26,6 @@ export const VTOKENS = [ ]; export const BOUND_VALIDATOR = "0xfe6bc1545Cc14C131bacA97476D6035ffcC0b889"; - const vip014 = () => { return makeProposal([ { @@ -133,4 +132,4 @@ const vip014 = () => { ]); }; -export default vip014; \ No newline at end of file +export default vip014; diff --git a/multisig/proposals/ethereum/vip-061/index.ts b/multisig/proposals/ethereum/vip-061/index.ts index afe78d153..518851abc 100644 --- a/multisig/proposals/ethereum/vip-061/index.ts +++ b/multisig/proposals/ethereum/vip-061/index.ts @@ -65,7 +65,6 @@ export const XVS = "0xd3CC9d8f3689B83c91b7B59cAB4946B063EB894A"; export const BOUND_VALIDATOR = "0x1Cd5f336A1d28Dff445619CC63d3A0329B4d8a58"; export const SFrxETHOracle = "0x5E06A5f48692E4Fff376fDfCA9E4C0183AAADCD1"; - const vip061 = () => { return makeProposal([ { @@ -194,4 +193,4 @@ const vip061 = () => { ]); }; -export default vip061; \ No newline at end of file +export default vip061; diff --git a/multisig/proposals/opbnbmainnet/vip-021/index.ts b/multisig/proposals/opbnbmainnet/vip-021/index.ts index 0cf2c27bc..6d84d9708 100644 --- a/multisig/proposals/opbnbmainnet/vip-021/index.ts +++ b/multisig/proposals/opbnbmainnet/vip-021/index.ts @@ -23,7 +23,6 @@ export const XVS_BRIDGE_ADMIN_PROXY = "0x52fcE05aDbf6103d71ed2BA8Be7A31728273183 export const XVS = "0x3E2e61F1c075881F3fB8dd568043d8c221fd5c61"; export const BOUND_VALIDATOR = "0xd1f80C371C6E2Fa395A5574DB3E3b4dAf43dadCE"; - const vip021 = () => { return makeProposal([ { @@ -108,4 +107,4 @@ const vip021 = () => { ]); }; -export default vip021; \ No newline at end of file +export default vip021; diff --git a/multisig/proposals/opbnbtestnet/vip-021/index.ts b/multisig/proposals/opbnbtestnet/vip-021/index.ts index 7c928b931..f476b6ed7 100644 --- a/multisig/proposals/opbnbtestnet/vip-021/index.ts +++ b/multisig/proposals/opbnbtestnet/vip-021/index.ts @@ -106,4 +106,4 @@ const vip021 = () => { ]); }; -export default vip021; \ No newline at end of file +export default vip021; diff --git a/multisig/proposals/sepolia/vip-060/index.ts b/multisig/proposals/sepolia/vip-060/index.ts index bc4ba4268..0cc438000 100644 --- a/multisig/proposals/sepolia/vip-060/index.ts +++ b/multisig/proposals/sepolia/vip-060/index.ts @@ -185,4 +185,4 @@ const vip060 = () => { ]); }; -export default vip060; \ No newline at end of file +export default vip060; diff --git a/multisig/simulations/arbitrumone/vip-014/abi/Comptroller.json b/multisig/simulations/arbitrumone/vip-014/abi/Comptroller.json new file mode 100644 index 000000000..f3b2445ac --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/Comptroller.json @@ -0,0 +1,929 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, + { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, + { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, + { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, + { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, + { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "TooMuchRepay", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "expectedSender", "type": "address" }, + { "internalType": "address", "name": "actualSender", "type": "address" } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, + { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "accountAssets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "actionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allMarkets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "approvedDelegates", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "borrowCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "contract VToken", "name": "vToken", "type": "address" } + ], + "name": "checkMembership", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], + "name": "enterMarkets", + "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], + "name": "exitMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAssetsIn", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getBorrowingPower", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "vTokenModify", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isForcedLiquidationEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "isMarketListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [ + { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "bool", "name": "isListed", "type": "bool" }, + { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "seizerContract", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, + { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, + { "internalType": "bool", "name": "paused", "type": "bool" } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "supplyCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "delegate", "type": "address" }, + { "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/ComptrollerBeacon.json b/multisig/simulations/arbitrumone/vip-014/abi/ComptrollerBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/ComptrollerBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/DefaultProxyAdmin.json b/multisig/simulations/arbitrumone/vip-014/abi/DefaultProxyAdmin.json new file mode 100644 index 000000000..9801cfcc7 --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/DefaultProxyAdmin.json @@ -0,0 +1,76 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "changeProxyAdmin", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" } + ], + "name": "upgrade", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" }, + { "internalType": "bytes", "name": "data", "type": "bytes" } + ], + "name": "upgradeAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/PoolRegistry.json b/multisig/simulations/arbitrumone/vip-014/abi/PoolRegistry.json new file mode 100644 index 000000000..31b1e2a17 --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/PoolRegistry.json @@ -0,0 +1,379 @@ +[ + { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, + { + "name": "Unauthorized", + "type": "error", + "inputs": [ + { "name": "sender", "type": "address", "internalType": "address" }, + { "name": "calledContract", "type": "address", "internalType": "address" }, + { "name": "methodSignature", "type": "string", "internalType": "string" } + ] + }, + { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, + { + "name": "Initialized", + "type": "event", + "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], + "anonymous": false, + "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" + }, + { + "name": "MarketAdded", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" + }, + { + "name": "NewAccessControlManager", + "type": "event", + "inputs": [ + { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, + { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" + }, + { + "name": "OwnershipTransferStarted", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" + }, + { + "name": "OwnershipTransferred", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" + }, + { + "name": "PoolMetadataUpdated", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "oldMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + }, + { + "name": "newMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "anonymous": false, + "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" + }, + { + "name": "PoolNameSet", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, + { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } + ], + "anonymous": false, + "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" + }, + { + "name": "PoolRegistered", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "pool", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "anonymous": false, + "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" + }, + { + "name": "acceptOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x79ba5097", + "stateMutability": "nonpayable" + }, + { + "name": "accessControlManager", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "contract IAccessControlManagerV8" + } + ], + "constant": true, + "signature": "0xb4a0bdf3", + "stateMutability": "view" + }, + { + "name": "addMarket", + "type": "function", + "inputs": [ + { + "name": "input", + "type": "tuple", + "components": [ + { "name": "vToken", "type": "address", "internalType": "contract VToken" }, + { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, + { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, + { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, + { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, + { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistry.AddMarketInput" + } + ], + "outputs": [], + "signature": "0x23dc8d64", + "stateMutability": "nonpayable" + }, + { + "name": "addPool", + "type": "function", + "inputs": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, + { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, + { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } + ], + "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], + "signature": "0xeed873c2", + "stateMutability": "nonpayable" + }, + { + "name": "getAllPools", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "tuple[]", + "value": [], + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool[]" + } + ], + "constant": true, + "signature": "0xd88ff1f4", + "stateMutability": "view" + }, + { + "name": "getPoolByComptroller", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "constant": true, + "signature": "0x7aee632d", + "stateMutability": "view" + }, + { + "name": "getPoolsSupportedByAsset", + "type": "function", + "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], + "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], + "constant": true, + "signature": "0xf36dba38", + "stateMutability": "view" + }, + { + "name": "getVTokenForAsset", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "asset", "type": "address", "internalType": "address" } + ], + "outputs": [{ "name": "", "type": "address", "internalType": "address" }], + "constant": true, + "signature": "0x266e0a7f", + "stateMutability": "view" + }, + { + "name": "getVenusPoolMetadata", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "constant": true, + "signature": "0xa3aefa2c", + "stateMutability": "view" + }, + { + "name": "initialize", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xc4d66de8", + "stateMutability": "nonpayable" + }, + { + "name": "metadata", + "type": "function", + "inputs": [{ "name": "", "type": "address", "internalType": "address" }], + "outputs": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "constant": true, + "signature": "0x2ba21572", + "stateMutability": "view" + }, + { + "name": "owner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x8da5cb5b", + "stateMutability": "view" + }, + { + "name": "pendingOwner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0xe30c3978", + "stateMutability": "view" + }, + { + "name": "renounceOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x715018a6", + "stateMutability": "nonpayable" + }, + { + "name": "setAccessControlManager", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0x0e32cb86", + "stateMutability": "nonpayable" + }, + { + "name": "setPoolName", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "name", "type": "string", "internalType": "string" } + ], + "outputs": [], + "signature": "0x1cb6bb7e", + "stateMutability": "nonpayable" + }, + { + "name": "transferOwnership", + "type": "function", + "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xf2fde38b", + "stateMutability": "nonpayable" + }, + { + "name": "updatePoolMetadata", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { + "name": "metadata_", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "outputs": [], + "signature": "0xff94d958", + "stateMutability": "nonpayable" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/Prime.json b/multisig/simulations/arbitrumone/vip-014/abi/Prime.json new file mode 100644 index 000000000..e8bfa99ff --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/Prime.json @@ -0,0 +1,763 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, + { "internalType": "address", "name": "_nativeMarket", "type": "address" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, + { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, + { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, + { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, + { "internalType": "bool", "name": "_timeBased", "type": "bool" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, + { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidComptroller", "type": "error" }, + { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "n", "type": "uint256" }, + { "internalType": "uint256", "name": "d", "type": "uint256" } + ], + "name": "InvalidFraction", + "type": "error" + }, + { "inputs": [], "name": "InvalidLength", "type": "error" }, + { "inputs": [], "name": "InvalidLimit", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, + { "inputs": [], "name": "InvalidVToken", "type": "error" }, + { + "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], + "name": "LnNonRealResult", + "type": "error" + }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, + { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, + { "inputs": [], "name": "MarketNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, + { "inputs": [], "name": "WaitMoreTime", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, + { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } + ], + "name": "AlphaUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "Burn", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "InterestClaimed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } + ], + "name": "MintLimitsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } + ], + "name": "MultiplierUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } + ], + "name": "StakedAtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "TokenUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "UserScoreUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "MAXIMUM_XVS_CAP", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MINIMUM_STAKED_XVS", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_MARKET", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "STAKING_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WRAPPED_NATIVE_TOKEN", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "accrueInterest", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" } + ], + "name": "accrueInterestAndUpdateScore", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "alphaDenominator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "alphaNumerator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "calculateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "claimTimeRemaining", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "uint256", "name": "borrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supply", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } + ], + "name": "estimateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "getInterestAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "getPendingRewards", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "internalType": "struct PrimeStorageV1.PendingReward[]", + "name": "pendingRewards", + "type": "tuple[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "incomeDistributionYearly", + "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "xvsVault_", "type": "address" }, + { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, + { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, + { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, + { "internalType": "address", "name": "comptroller_", "type": "address" }, + { "internalType": "address", "name": "oracle_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "name": "initializeV2", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "interests", + "outputs": [ + { "internalType": "uint256", "name": "accrued", "type": "uint256" }, + { "internalType": "uint256", "name": "score", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "irrevocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "isScoreUpdated", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "isUserPrimeHolder", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, + { "internalType": "address[]", "name": "users", "type": "address[]" } + ], + "name": "issue", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, + { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, + { "internalType": "bool", "name": "exists", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "nextScoreUpdateRoundId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingScoreUpdates", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "primeLiquidityProvider", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "revocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } + ], + "name": "setLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "users", "type": "address[]" }, + { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } + ], + "name": "setStakedAt", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "stakedAt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokens", + "outputs": [ + { "internalType": "bool", "name": "exists", "type": "bool" }, + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalIrrevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalRevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalScoreUpdatesRequired", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "unreleasedPLPIncome", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, + { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } + ], + "name": "updateAlpha", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "updateMultipliers", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], + "name": "updateScores", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "vTokenForAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "xvsUpdated", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVault", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultPoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/PrimeLiquidityProvider.json b/multisig/simulations/arbitrumone/vip-014/abi/PrimeLiquidityProvider.json new file mode 100644 index 000000000..02ca8e0bf --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/PrimeLiquidityProvider.json @@ -0,0 +1,385 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "_timeBased", "type": "bool" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, + { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "balance", "type": "uint256" } + ], + "name": "InsufficientBalance", + "type": "error" + }, + { "inputs": [], "name": "InvalidArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidCaller", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "speed", "type": "uint256" }, + { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } + ], + "name": "InvalidDistributionSpeed", + "type": "error" + }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenAlreadyInitialized", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "TokenNotInitialized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "MaxTokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } + ], + "name": "PrimeTokenUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenDistributionInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "TokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokenTransferredToPrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokensAccrued", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "accrueTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "getEffectiveDistributionSpeed", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], + "name": "initializeTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "lastAccruedBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastAccruedBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "maxTokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } + ], + "name": "setMaxTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } + ], + "name": "setTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "tokenAmountAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/ProtocolShareReserve.json b/multisig/simulations/arbitrumone/vip-014/abi/ProtocolShareReserve.json new file mode 100644 index 000000000..b33d7c495 --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/ProtocolShareReserve.json @@ -0,0 +1,356 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, + { "internalType": "address", "name": "_wbnb", "type": "address" }, + { "internalType": "address", "name": "_vbnb", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetReleased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IProtocolShareReserve.IncomeType", + "name": "incomeType", + "type": "uint8" + }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "AssetsReservesUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } + ], + "name": "PoolRegistryUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "ReservesUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "CORE_POOL_COMPTROLLER", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MAX_PERCENT", + "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "internalType": "struct ProtocolShareReserve.DistributionConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "addOrUpdateDistributionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } + ], + "name": "assetsReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "distributionTargets", + "outputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "getPercentageDistribution", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "getUnreleasedFunds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address[]", "name": "assets", "type": "address[]" } + ], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "name": "removeDistributionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], + "name": "setPoolRegistry", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAssetReserve", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalDistributions", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/RewardDistrbutor.json b/multisig/simulations/arbitrumone/vip-014/abi/RewardDistrbutor.json new file mode 100644 index 000000000..249fdd111 --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/RewardDistrbutor.json @@ -0,0 +1,532 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "BorrowLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "BorrowLastRewardingBlockUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "ContributorRewardTokenSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } + ], + "name": "ContributorRewardsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } + ], + "name": "DistributedBorrowerRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } + ], + "name": "DistributedSupplierRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "MarketInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "indexed": false, + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "RewardTokenBorrowIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenBorrowSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RewardTokenGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "RewardTokenSupplyIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenSupplySpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "SupplyLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "SupplyLastRewardingBlockUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "INITIAL_INDEX", + "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "holder", "type": "address" }, + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } + ], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "distributeBorrowerRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "supplier", "type": "address" } + ], + "name": "distributeSupplierRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "grantRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, + { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "initializeMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastContributorBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "rewardToken", + "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenBorrowerIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenContributorSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenSupplierIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplySpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contributor", "type": "address" }, + { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } + ], + "name": "setContributorRewardTokenSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } + ], + "name": "setLastRewardingBlockTimestamps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, + { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } + ], + "name": "setLastRewardingBlocks", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } + ], + "name": "setRewardTokenSpeeds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], + "name": "updateContributorRewards", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "updateRewardTokenBorrowIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "updateRewardTokenSupplyIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/VToken.json b/multisig/simulations/arbitrumone/vip-014/abi/VToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/VToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/VTokenBeacon.json b/multisig/simulations/arbitrumone/vip-014/abi/VTokenBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/VTokenBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/XVSStore.json b/multisig/simulations/arbitrumone/vip-014/abi/XVSStore.json new file mode 100644 index 000000000..2d9ea2bb2 --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/XVSStore.json @@ -0,0 +1,130 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "AdminTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } + ], + "name": "NewPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnerTransferred", + "type": "event" + }, + { + "constant": false, + "inputs": [], + "name": "acceptAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "emergencyRewardWithdraw", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokens", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "token", "type": "address" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "safeRewardTransfer", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], + "name": "setNewOwner", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], + "name": "setPendingAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "bool", "name": "status", "type": "bool" } + ], + "name": "setRewardToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/XVSVault.json b/multisig/simulations/arbitrumone/vip-014/abi/XVSVault.json new file mode 100644 index 000000000..51d8d540c --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/XVSVault.json @@ -0,0 +1,787 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Claim", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } + ], + "name": "DelegateChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "DelegateVotesChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Deposit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ExecutedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "name": "PoolAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } + ], + "name": "PoolUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RequestedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } + ], + "name": "RewardAmountUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } + ], + "name": "StoreUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } + ], + "name": "VaultDebtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } + ], + "name": "WithdrawalLockingPeriodUpdated", + "type": "event" + }, + { + "constant": true, + "inputs": [], + "name": "DELEGATION_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "DOMAIN_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "MAX_LOCK_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "SECONDS_PER_YEAR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], + "name": "_become", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, + { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, + { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } + ], + "name": "add", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint32", "name": "", "type": "uint32" } + ], + "name": "checkpoints", + "outputs": [ + { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, + { "internalType": "uint96", "name": "votes", "type": "uint96" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_account", "type": "address" }, + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "claim", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], + "name": "delegate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "delegatee", "type": "address" }, + { "internalType": "uint256", "name": "nonce", "type": "uint256" }, + { "internalType": "uint256", "name": "expiry", "type": "uint256" }, + { "internalType": "uint8", "name": "v", "type": "uint8" }, + { "internalType": "bytes32", "name": "r", "type": "bytes32" }, + { "internalType": "bytes32", "name": "s", "type": "bytes32" } + ], + "name": "delegateBySig", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "delegates", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "deposit", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "executeWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getCurrentVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getEligibleWithdrawalAmount", + "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } + ], + "name": "getPriorVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getRequestedAmount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getUserInfo", + "outputs": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, + { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getWithdrawalRequests", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, + { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } + ], + "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", + "name": "", + "type": "tuple[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "name": "initializeTimeManager", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isStakedToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "nonces", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "numCheckpoints", + "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "pause", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingReward", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "pendingRewardTransfers", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingWithdrawalsBeforeUpgrade", + "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingXVSVaultImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "poolInfos", + "outputs": [ + { "internalType": "contract IBEP20", "name": "token", "type": "address" }, + { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, + { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], + "name": "poolLength", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primePoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeToken", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "requestWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "resume", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], + "name": "rewardTokenAmountsPerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAmountsPerBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } + ], + "name": "set", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], + "name": "setAccessControl", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, + { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } + ], + "name": "setPrimeToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } + ], + "name": "setRewardAmountPerBlockOrSecond", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } + ], + "name": "setWithdrawalLockingPeriod", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_xvs", "type": "address" }, + { "internalType": "address", "name": "_xvsStore", "type": "address" } + ], + "name": "setXvsStore", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAllocPoints", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "totalPendingWithdrawals", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "updatePool", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "vaultPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsStore", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/boundValidator.json b/multisig/simulations/arbitrumone/vip-014/abi/boundValidator.json new file mode 100644 index 000000000..d16c8fb08 --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/boundValidator.json @@ -0,0 +1,498 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "previousAdmin", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAdmin", + "type": "address" + } + ], + "name": "AdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "beacon", + "type": "address" + } + ], + "name": "BeaconUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "implementation", + "type": "address" + } + ], + "name": "Upgraded", + "type": "event" + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "inputs": [], + "name": "admin", + "outputs": [ + { + "internalType": "address", + "name": "admin_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [ + { + "internalType": "address", + "name": "implementation_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + } + ], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "upgradeToAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "stateMutability": "payable", + "type": "receive" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "upperBound", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "lowerBound", + "type": "uint256" + } + ], + "name": "ValidateConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig", + "name": "config", + "type": "tuple" + } + ], + "name": "setValidateConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "setValidateConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "validateConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "reportedPrice", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "anchorPrice", + "type": "uint256" + } + ], + "name": "validatePriceWithAnchorPrice", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_logic", + "type": "address" + }, + { + "internalType": "address", + "name": "admin_", + "type": "address" + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes" + } + ], + "stateMutability": "payable", + "type": "constructor" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/chainlinkOracle.json b/multisig/simulations/arbitrumone/vip-014/abi/chainlinkOracle.json new file mode 100644 index 000000000..cdd689acb --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/chainlinkOracle.json @@ -0,0 +1,459 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "vBnbAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "previousPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "requestedPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newPriceMantissa", + "type": "uint256" + } + ], + "name": "PricePosted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManager", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "prices", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + } + ], + "name": "setDirectPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VBep20Interface", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "underlyingPriceMantissa", + "type": "uint256" + } + ], + "name": "setUnderlyingPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "tokenConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/resilientOracle.json b/multisig/simulations/arbitrumone/vip-014/abi/resilientOracle.json new file mode 100644 index 000000000..35f52caa0 --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/resilientOracle.json @@ -0,0 +1,640 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "nativeMarketAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + }, + { + "internalType": "contract BoundValidatorInterface", + "name": "_boundValidator", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "mainOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "pivotOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "fallbackOracle", + "type": "address" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [ + { + "internalType": "contract BoundValidatorInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "getOracle", + "outputs": [ + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "bool", + "name": "enabled", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/treasury.json b/multisig/simulations/arbitrumone/vip-014/abi/treasury.json new file mode 100644 index 000000000..18aabb61a --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/treasury.json @@ -0,0 +1,86 @@ +[ + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryNative", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryToken", + "type": "event" + }, + { "stateMutability": "payable", "type": "fallback" }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryNative", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "stateMutability": "payable", "type": "receive" } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/xvs.json b/multisig/simulations/arbitrumone/vip-014/abi/xvs.json new file mode 100644 index 000000000..69092bb4a --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/xvs.json @@ -0,0 +1,716 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "AccountBlacklisted", + "type": "error" + }, + { + "inputs": [], + "name": "AddressesMustDiffer", + "type": "error" + }, + { + "inputs": [], + "name": "MintLimitExceed", + "type": "error" + }, + { + "inputs": [], + "name": "MintedAmountExceed", + "type": "error" + }, + { + "inputs": [], + "name": "NewCapNotGreaterThanMintedTokens", + "type": "error" + }, + { + "inputs": [], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "value", + "type": "bool" + } + ], + "name": "BlacklistUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "MintCapChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitDecreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "source", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "destination", + "type": "address" + } + ], + "name": "MintedTokensMigrated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "address", + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + } + ], + "name": "isBlackListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "source_", + "type": "address" + }, + { + "internalType": "address", + "name": "destination_", + "type": "address" + } + ], + "name": "migrateMinterTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToCap", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToMintedAmount", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newAccessControlAddress_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "minter_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "setMintCap", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + }, + { + "internalType": "bool", + "name": "value_", + "type": "bool" + } + ], + "name": "updateBlacklist", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/xvsBridgeAdmin.json b/multisig/simulations/arbitrumone/vip-014/abi/xvsBridgeAdmin.json new file mode 100644 index 000000000..024450a40 --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/abi/xvsBridgeAdmin.json @@ -0,0 +1,329 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "XVSBridge_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "string", + "name": "signature", + "type": "string" + }, + { + "indexed": false, + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "name": "FunctionRegistryChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "stateMutability": "nonpayable", + "type": "fallback" + }, + { + "inputs": [], + "name": "XVSBridge", + "outputs": [ + { + "internalType": "contract IXVSProxyOFT", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "", + "type": "bytes4" + } + ], + "name": "functionRegistry", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "isTrustedRemote", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner_", + "type": "address" + } + ], + "name": "transferBridgeOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "string[]", + "name": "signatures_", + "type": "string[]" + }, + { + "internalType": "bool[]", + "name": "active_", + "type": "bool[]" + } + ], + "name": "upsertSignature", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-014/index.ts b/multisig/simulations/arbitrumone/vip-014/index.ts new file mode 100644 index 000000000..d96e62355 --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-014/index.ts @@ -0,0 +1,225 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip014, { + BOUND_VALIDATOR, + COMPTROLLERS, + COMPTROLLER_BEACON, + DEFAULT_PROXY_ADMIN, + PLP, + PRIME, + PSR, + REWARD_DISTRIBUTORS, + VTOKENS, + VTOKEN_BEACON, + XVS, + XVS_BRIDGE_ADMIN_PROXY, + XVS_STORE, +} from "../../../proposals/arbitrumone/vip-014"; +import COMPTROLLER_ABI from "./abi/Comptroller.json"; +import COMPTROLLER_BEACON_ABI from "./abi/ComptrollerBeacon.json"; +import DEFAULT_PROXY_ADMIN_ABI from "./abi/DefaultProxyAdmin.json"; +import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; +import PRIME_ABI from "./abi/Prime.json"; +import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; +import PSR_ABI from "./abi/ProtocolShareReserve.json"; +import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistrbutor.json"; +import VTOKEN_ABI from "./abi/VToken.json"; +import VTOKEN_BEACON_ABI from "./abi/VTokenBeacon.json"; +import XVS_STORE_ABI from "./abi/XVSStore.json"; +import XVS_VAULT_ABI from "./abi/XVSVault.json"; +import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; +import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; +import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; +import TREASURY_ABI from "./abi/treasury.json"; +import XVS_ABI from "./abi/xvs.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; + +const { arbitrumone } = NETWORK_ADDRESSES; + +const RESILIENT_ORACLE = arbitrumone.RESILIENT_ORACLE; +const CHAINLINK_ORACLE = arbitrumone.CHAINLINK_ORACLE; +const REDSTONE_ORACLE = arbitrumone.REDSTONE_ORACLE; +const NORMAL_TIMELOCK = arbitrumone.NORMAL_TIMELOCK; + +forking(241039405, async () => { + const provider = ethers.provider; + let proxyAdmin: Contract; + let prime: Contract; + let plp: Contract; + let psr: Contract; + let comptrollerBeacon: Contract; + let vTokenBeacon: Contract; + let poolRegistry: Contract; + let xvsVault: Contract; + let xvsStore: Contract; + let xvs: Contract; + let xvsBridgeAdmin: Contract; + let resilientOracle: Contract; + let chainLinkOracle: Contract; + let redstoneOracle: Contract; + let boundValidator: Contract; + let treasury: Contract; + + describe("Pre-VIP behavior", async () => { + before(async () => { + proxyAdmin = new ethers.Contract(DEFAULT_PROXY_ADMIN, DEFAULT_PROXY_ADMIN_ABI, provider); + prime = new ethers.Contract(PRIME, PRIME_ABI, provider); + plp = new ethers.Contract(PLP, PLP_ABI, provider); + psr = new ethers.Contract(PSR, PSR_ABI, provider); + comptrollerBeacon = new ethers.Contract(COMPTROLLER_BEACON, COMPTROLLER_BEACON_ABI, provider); + vTokenBeacon = new ethers.Contract(VTOKEN_BEACON, VTOKEN_BEACON_ABI, provider); + poolRegistry = new ethers.Contract(arbitrumone.POOL_REGISTRY, POOL_REGISTRY_ABI, provider); + xvsVault = new ethers.Contract(arbitrumone.XVS_VAULT_PROXY, XVS_VAULT_ABI, provider); + xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); + xvs = await ethers.getContractAt(XVS_ABI, XVS); + xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, XVS_BRIDGE_ADMIN_PROXY); + resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); + chainLinkOracle = new ethers.Contract(CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); + redstoneOracle = new ethers.Contract(REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); + boundValidator = new ethers.Contract(BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); + treasury = await ethers.getContractAt(TREASURY_ABI, NETWORK_ADDRESSES.arbitrumone.VTREASURY); + }); + + it("owner of proxy admin is guardian", async () => { + expect(await proxyAdmin.owner()).to.equal(arbitrumone.GUARDIAN); + }); + it("pending owner", async () => { + expect(await prime.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await plp.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + + for (const rewardDistributor of REWARD_DISTRIBUTORS) { + it(`should have no pending owner for ${rewardDistributor}`, async () => { + const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + it("pending owner of psr", async () => { + expect(await psr.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`should have no pending owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`should have no pending owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + it("owner of ComptrollerBeacon is guardian", async () => { + expect(await comptrollerBeacon.owner()).to.equal(arbitrumone.GUARDIAN); + }); + + it("owner of VTokenBeacon is guardian", async () => { + expect(await vTokenBeacon.owner()).to.equal(arbitrumone.GUARDIAN); + }); + + it("pending owner of PoolRegistry", async () => { + expect(await poolRegistry.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + it("should have no pending owner", async () => { + expect(await xvsVault.pendingAdmin()).to.equal(ethers.constants.AddressZero); + }); + + it("should have no pending owner", async () => { + expect(await xvsStore.pendingAdmin()).to.equal(ethers.constants.AddressZero); + }); + + it("should have no pending owner", async () => { + expect(await resilientOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await chainLinkOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await redstoneOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await boundValidator.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + }); + + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip014()); + }); + + it("owner of proxy admin is timelock", async () => { + expect(await proxyAdmin.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); + }); + + it("pending owner", async () => { + expect(await prime.pendingOwner()).to.equal(arbitrumone.NORMAL_TIMELOCK); + expect(await plp.pendingOwner()).to.equal(arbitrumone.NORMAL_TIMELOCK); + }); + + for (const rewardDistributor of REWARD_DISTRIBUTORS) { + it(`should have Normal Timelock as pending owner for ${rewardDistributor}`, async () => { + const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); + expect(await c.pendingOwner()).to.equal(arbitrumone.NORMAL_TIMELOCK); + }); + } + + it("pending owner of psr", async () => { + expect(await psr.pendingOwner()).to.equal(arbitrumone.NORMAL_TIMELOCK); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`correct pending owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.pendingOwner()).to.equal(arbitrumone.NORMAL_TIMELOCK); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`correct pending owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.pendingOwner()).to.equal(arbitrumone.NORMAL_TIMELOCK); + }); + } + + it("owner of ComptrollerBeacon is NT", async () => { + expect(await comptrollerBeacon.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); + }); + + it("owner of VTokenBeacon is NT", async () => { + expect(await vTokenBeacon.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); + }); + + it("pending owner of PoolRegistry is NT", async () => { + expect(await poolRegistry.pendingOwner()).to.equal(arbitrumone.NORMAL_TIMELOCK); + }); + + it("correct pending owner", async () => { + expect(await xvsVault.pendingAdmin()).to.equal(NORMAL_TIMELOCK); + }); + + it("correct pending owner", async () => { + expect(await xvsStore.pendingAdmin()).to.equal(NORMAL_TIMELOCK); + }); + + it("Should set bridge pending owner to Normal Timelock", async () => { + const pendingOwner = await xvsBridgeAdmin.pendingOwner(); + expect(pendingOwner).equals(arbitrumone.NORMAL_TIMELOCK); + }); + it("Should set XVS owner to Normal Timelock", async () => { + const owner = await xvs.owner(); + expect(owner).equals(arbitrumone.NORMAL_TIMELOCK); + }); + it("correct pending owner", async () => { + expect(await resilientOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); + expect(await chainLinkOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); + expect(await redstoneOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); + expect(await boundValidator.pendingOwner()).to.equal(NORMAL_TIMELOCK); + }); + it("Should set pendingOwner to Normal Timelock", async () => { + const pendingOwner = await treasury.pendingOwner(); + expect(pendingOwner).equals(NETWORK_ADDRESSES.arbitrumone.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/Comptroller.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/Comptroller.json new file mode 100644 index 000000000..f3b2445ac --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/Comptroller.json @@ -0,0 +1,929 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, + { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, + { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, + { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, + { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, + { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "TooMuchRepay", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "expectedSender", "type": "address" }, + { "internalType": "address", "name": "actualSender", "type": "address" } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, + { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "accountAssets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "actionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allMarkets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "approvedDelegates", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "borrowCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "contract VToken", "name": "vToken", "type": "address" } + ], + "name": "checkMembership", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], + "name": "enterMarkets", + "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], + "name": "exitMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAssetsIn", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getBorrowingPower", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "vTokenModify", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isForcedLiquidationEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "isMarketListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [ + { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "bool", "name": "isListed", "type": "bool" }, + { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "seizerContract", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, + { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, + { "internalType": "bool", "name": "paused", "type": "bool" } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "supplyCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "delegate", "type": "address" }, + { "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/ComptrollerBeacon.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/ComptrollerBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/ComptrollerBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/DefaultProxyAdmin.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/DefaultProxyAdmin.json new file mode 100644 index 000000000..9801cfcc7 --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/DefaultProxyAdmin.json @@ -0,0 +1,76 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "changeProxyAdmin", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" } + ], + "name": "upgrade", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" }, + { "internalType": "bytes", "name": "data", "type": "bytes" } + ], + "name": "upgradeAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/PoolRegistry.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/PoolRegistry.json new file mode 100644 index 000000000..31b1e2a17 --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/PoolRegistry.json @@ -0,0 +1,379 @@ +[ + { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, + { + "name": "Unauthorized", + "type": "error", + "inputs": [ + { "name": "sender", "type": "address", "internalType": "address" }, + { "name": "calledContract", "type": "address", "internalType": "address" }, + { "name": "methodSignature", "type": "string", "internalType": "string" } + ] + }, + { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, + { + "name": "Initialized", + "type": "event", + "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], + "anonymous": false, + "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" + }, + { + "name": "MarketAdded", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" + }, + { + "name": "NewAccessControlManager", + "type": "event", + "inputs": [ + { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, + { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" + }, + { + "name": "OwnershipTransferStarted", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" + }, + { + "name": "OwnershipTransferred", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" + }, + { + "name": "PoolMetadataUpdated", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "oldMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + }, + { + "name": "newMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "anonymous": false, + "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" + }, + { + "name": "PoolNameSet", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, + { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } + ], + "anonymous": false, + "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" + }, + { + "name": "PoolRegistered", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "pool", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "anonymous": false, + "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" + }, + { + "name": "acceptOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x79ba5097", + "stateMutability": "nonpayable" + }, + { + "name": "accessControlManager", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "contract IAccessControlManagerV8" + } + ], + "constant": true, + "signature": "0xb4a0bdf3", + "stateMutability": "view" + }, + { + "name": "addMarket", + "type": "function", + "inputs": [ + { + "name": "input", + "type": "tuple", + "components": [ + { "name": "vToken", "type": "address", "internalType": "contract VToken" }, + { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, + { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, + { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, + { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, + { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistry.AddMarketInput" + } + ], + "outputs": [], + "signature": "0x23dc8d64", + "stateMutability": "nonpayable" + }, + { + "name": "addPool", + "type": "function", + "inputs": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, + { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, + { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } + ], + "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], + "signature": "0xeed873c2", + "stateMutability": "nonpayable" + }, + { + "name": "getAllPools", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "tuple[]", + "value": [], + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool[]" + } + ], + "constant": true, + "signature": "0xd88ff1f4", + "stateMutability": "view" + }, + { + "name": "getPoolByComptroller", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "constant": true, + "signature": "0x7aee632d", + "stateMutability": "view" + }, + { + "name": "getPoolsSupportedByAsset", + "type": "function", + "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], + "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], + "constant": true, + "signature": "0xf36dba38", + "stateMutability": "view" + }, + { + "name": "getVTokenForAsset", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "asset", "type": "address", "internalType": "address" } + ], + "outputs": [{ "name": "", "type": "address", "internalType": "address" }], + "constant": true, + "signature": "0x266e0a7f", + "stateMutability": "view" + }, + { + "name": "getVenusPoolMetadata", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "constant": true, + "signature": "0xa3aefa2c", + "stateMutability": "view" + }, + { + "name": "initialize", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xc4d66de8", + "stateMutability": "nonpayable" + }, + { + "name": "metadata", + "type": "function", + "inputs": [{ "name": "", "type": "address", "internalType": "address" }], + "outputs": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "constant": true, + "signature": "0x2ba21572", + "stateMutability": "view" + }, + { + "name": "owner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x8da5cb5b", + "stateMutability": "view" + }, + { + "name": "pendingOwner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0xe30c3978", + "stateMutability": "view" + }, + { + "name": "renounceOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x715018a6", + "stateMutability": "nonpayable" + }, + { + "name": "setAccessControlManager", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0x0e32cb86", + "stateMutability": "nonpayable" + }, + { + "name": "setPoolName", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "name", "type": "string", "internalType": "string" } + ], + "outputs": [], + "signature": "0x1cb6bb7e", + "stateMutability": "nonpayable" + }, + { + "name": "transferOwnership", + "type": "function", + "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xf2fde38b", + "stateMutability": "nonpayable" + }, + { + "name": "updatePoolMetadata", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { + "name": "metadata_", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "outputs": [], + "signature": "0xff94d958", + "stateMutability": "nonpayable" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/Prime.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/Prime.json new file mode 100644 index 000000000..e8bfa99ff --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/Prime.json @@ -0,0 +1,763 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, + { "internalType": "address", "name": "_nativeMarket", "type": "address" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, + { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, + { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, + { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, + { "internalType": "bool", "name": "_timeBased", "type": "bool" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, + { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidComptroller", "type": "error" }, + { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "n", "type": "uint256" }, + { "internalType": "uint256", "name": "d", "type": "uint256" } + ], + "name": "InvalidFraction", + "type": "error" + }, + { "inputs": [], "name": "InvalidLength", "type": "error" }, + { "inputs": [], "name": "InvalidLimit", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, + { "inputs": [], "name": "InvalidVToken", "type": "error" }, + { + "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], + "name": "LnNonRealResult", + "type": "error" + }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, + { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, + { "inputs": [], "name": "MarketNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, + { "inputs": [], "name": "WaitMoreTime", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, + { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } + ], + "name": "AlphaUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "Burn", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "InterestClaimed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } + ], + "name": "MintLimitsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } + ], + "name": "MultiplierUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } + ], + "name": "StakedAtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "TokenUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "UserScoreUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "MAXIMUM_XVS_CAP", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MINIMUM_STAKED_XVS", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_MARKET", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "STAKING_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WRAPPED_NATIVE_TOKEN", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "accrueInterest", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" } + ], + "name": "accrueInterestAndUpdateScore", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "alphaDenominator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "alphaNumerator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "calculateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "claimTimeRemaining", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "uint256", "name": "borrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supply", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } + ], + "name": "estimateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "getInterestAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "getPendingRewards", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "internalType": "struct PrimeStorageV1.PendingReward[]", + "name": "pendingRewards", + "type": "tuple[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "incomeDistributionYearly", + "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "xvsVault_", "type": "address" }, + { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, + { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, + { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, + { "internalType": "address", "name": "comptroller_", "type": "address" }, + { "internalType": "address", "name": "oracle_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "name": "initializeV2", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "interests", + "outputs": [ + { "internalType": "uint256", "name": "accrued", "type": "uint256" }, + { "internalType": "uint256", "name": "score", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "irrevocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "isScoreUpdated", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "isUserPrimeHolder", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, + { "internalType": "address[]", "name": "users", "type": "address[]" } + ], + "name": "issue", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, + { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, + { "internalType": "bool", "name": "exists", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "nextScoreUpdateRoundId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingScoreUpdates", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "primeLiquidityProvider", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "revocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } + ], + "name": "setLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "users", "type": "address[]" }, + { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } + ], + "name": "setStakedAt", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "stakedAt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokens", + "outputs": [ + { "internalType": "bool", "name": "exists", "type": "bool" }, + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalIrrevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalRevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalScoreUpdatesRequired", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "unreleasedPLPIncome", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, + { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } + ], + "name": "updateAlpha", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "updateMultipliers", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], + "name": "updateScores", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "vTokenForAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "xvsUpdated", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVault", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultPoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/PrimeLiquidityProvider.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/PrimeLiquidityProvider.json new file mode 100644 index 000000000..02ca8e0bf --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/PrimeLiquidityProvider.json @@ -0,0 +1,385 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "_timeBased", "type": "bool" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, + { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "balance", "type": "uint256" } + ], + "name": "InsufficientBalance", + "type": "error" + }, + { "inputs": [], "name": "InvalidArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidCaller", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "speed", "type": "uint256" }, + { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } + ], + "name": "InvalidDistributionSpeed", + "type": "error" + }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenAlreadyInitialized", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "TokenNotInitialized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "MaxTokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } + ], + "name": "PrimeTokenUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenDistributionInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "TokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokenTransferredToPrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokensAccrued", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "accrueTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "getEffectiveDistributionSpeed", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], + "name": "initializeTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "lastAccruedBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastAccruedBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "maxTokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } + ], + "name": "setMaxTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } + ], + "name": "setTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "tokenAmountAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/ProtocolShareReserve.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/ProtocolShareReserve.json new file mode 100644 index 000000000..b33d7c495 --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/ProtocolShareReserve.json @@ -0,0 +1,356 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, + { "internalType": "address", "name": "_wbnb", "type": "address" }, + { "internalType": "address", "name": "_vbnb", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetReleased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IProtocolShareReserve.IncomeType", + "name": "incomeType", + "type": "uint8" + }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "AssetsReservesUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } + ], + "name": "PoolRegistryUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "ReservesUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "CORE_POOL_COMPTROLLER", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MAX_PERCENT", + "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "internalType": "struct ProtocolShareReserve.DistributionConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "addOrUpdateDistributionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } + ], + "name": "assetsReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "distributionTargets", + "outputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "getPercentageDistribution", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "getUnreleasedFunds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address[]", "name": "assets", "type": "address[]" } + ], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "name": "removeDistributionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], + "name": "setPoolRegistry", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAssetReserve", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalDistributions", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/RewardDistrbutor.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/RewardDistrbutor.json new file mode 100644 index 000000000..249fdd111 --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/RewardDistrbutor.json @@ -0,0 +1,532 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "BorrowLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "BorrowLastRewardingBlockUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "ContributorRewardTokenSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } + ], + "name": "ContributorRewardsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } + ], + "name": "DistributedBorrowerRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } + ], + "name": "DistributedSupplierRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "MarketInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "indexed": false, + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "RewardTokenBorrowIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenBorrowSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RewardTokenGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "RewardTokenSupplyIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenSupplySpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "SupplyLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "SupplyLastRewardingBlockUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "INITIAL_INDEX", + "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "holder", "type": "address" }, + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } + ], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "distributeBorrowerRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "supplier", "type": "address" } + ], + "name": "distributeSupplierRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "grantRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, + { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "initializeMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastContributorBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "rewardToken", + "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenBorrowerIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenContributorSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenSupplierIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplySpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contributor", "type": "address" }, + { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } + ], + "name": "setContributorRewardTokenSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } + ], + "name": "setLastRewardingBlockTimestamps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, + { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } + ], + "name": "setLastRewardingBlocks", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } + ], + "name": "setRewardTokenSpeeds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], + "name": "updateContributorRewards", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "updateRewardTokenBorrowIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "updateRewardTokenSupplyIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/VToken.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/VToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/VToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/VTokenBeacon.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/VTokenBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/VTokenBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/XVSStore.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/XVSStore.json new file mode 100644 index 000000000..2d9ea2bb2 --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/XVSStore.json @@ -0,0 +1,130 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "AdminTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } + ], + "name": "NewPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnerTransferred", + "type": "event" + }, + { + "constant": false, + "inputs": [], + "name": "acceptAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "emergencyRewardWithdraw", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokens", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "token", "type": "address" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "safeRewardTransfer", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], + "name": "setNewOwner", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], + "name": "setPendingAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "bool", "name": "status", "type": "bool" } + ], + "name": "setRewardToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/XVSVault.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/XVSVault.json new file mode 100644 index 000000000..51d8d540c --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/XVSVault.json @@ -0,0 +1,787 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Claim", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } + ], + "name": "DelegateChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "DelegateVotesChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Deposit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ExecutedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "name": "PoolAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } + ], + "name": "PoolUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RequestedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } + ], + "name": "RewardAmountUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } + ], + "name": "StoreUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } + ], + "name": "VaultDebtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } + ], + "name": "WithdrawalLockingPeriodUpdated", + "type": "event" + }, + { + "constant": true, + "inputs": [], + "name": "DELEGATION_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "DOMAIN_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "MAX_LOCK_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "SECONDS_PER_YEAR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], + "name": "_become", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, + { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, + { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } + ], + "name": "add", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint32", "name": "", "type": "uint32" } + ], + "name": "checkpoints", + "outputs": [ + { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, + { "internalType": "uint96", "name": "votes", "type": "uint96" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_account", "type": "address" }, + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "claim", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], + "name": "delegate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "delegatee", "type": "address" }, + { "internalType": "uint256", "name": "nonce", "type": "uint256" }, + { "internalType": "uint256", "name": "expiry", "type": "uint256" }, + { "internalType": "uint8", "name": "v", "type": "uint8" }, + { "internalType": "bytes32", "name": "r", "type": "bytes32" }, + { "internalType": "bytes32", "name": "s", "type": "bytes32" } + ], + "name": "delegateBySig", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "delegates", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "deposit", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "executeWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getCurrentVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getEligibleWithdrawalAmount", + "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } + ], + "name": "getPriorVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getRequestedAmount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getUserInfo", + "outputs": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, + { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getWithdrawalRequests", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, + { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } + ], + "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", + "name": "", + "type": "tuple[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "name": "initializeTimeManager", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isStakedToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "nonces", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "numCheckpoints", + "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "pause", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingReward", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "pendingRewardTransfers", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingWithdrawalsBeforeUpgrade", + "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingXVSVaultImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "poolInfos", + "outputs": [ + { "internalType": "contract IBEP20", "name": "token", "type": "address" }, + { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, + { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], + "name": "poolLength", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primePoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeToken", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "requestWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "resume", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], + "name": "rewardTokenAmountsPerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAmountsPerBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } + ], + "name": "set", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], + "name": "setAccessControl", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, + { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } + ], + "name": "setPrimeToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } + ], + "name": "setRewardAmountPerBlockOrSecond", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } + ], + "name": "setWithdrawalLockingPeriod", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_xvs", "type": "address" }, + { "internalType": "address", "name": "_xvsStore", "type": "address" } + ], + "name": "setXvsStore", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAllocPoints", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "totalPendingWithdrawals", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "updatePool", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "vaultPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsStore", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/boundValidator.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/boundValidator.json new file mode 100644 index 000000000..d16c8fb08 --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/boundValidator.json @@ -0,0 +1,498 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "previousAdmin", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAdmin", + "type": "address" + } + ], + "name": "AdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "beacon", + "type": "address" + } + ], + "name": "BeaconUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "implementation", + "type": "address" + } + ], + "name": "Upgraded", + "type": "event" + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "inputs": [], + "name": "admin", + "outputs": [ + { + "internalType": "address", + "name": "admin_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [ + { + "internalType": "address", + "name": "implementation_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + } + ], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "upgradeToAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "stateMutability": "payable", + "type": "receive" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "upperBound", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "lowerBound", + "type": "uint256" + } + ], + "name": "ValidateConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig", + "name": "config", + "type": "tuple" + } + ], + "name": "setValidateConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "setValidateConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "validateConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "reportedPrice", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "anchorPrice", + "type": "uint256" + } + ], + "name": "validatePriceWithAnchorPrice", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_logic", + "type": "address" + }, + { + "internalType": "address", + "name": "admin_", + "type": "address" + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes" + } + ], + "stateMutability": "payable", + "type": "constructor" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/chainlinkOracle.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/chainlinkOracle.json new file mode 100644 index 000000000..cdd689acb --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/chainlinkOracle.json @@ -0,0 +1,459 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "vBnbAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "previousPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "requestedPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newPriceMantissa", + "type": "uint256" + } + ], + "name": "PricePosted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManager", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "prices", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + } + ], + "name": "setDirectPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VBep20Interface", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "underlyingPriceMantissa", + "type": "uint256" + } + ], + "name": "setUnderlyingPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "tokenConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/resilientOracle.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/resilientOracle.json new file mode 100644 index 000000000..35f52caa0 --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/resilientOracle.json @@ -0,0 +1,640 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "nativeMarketAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + }, + { + "internalType": "contract BoundValidatorInterface", + "name": "_boundValidator", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "mainOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "pivotOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "fallbackOracle", + "type": "address" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [ + { + "internalType": "contract BoundValidatorInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "getOracle", + "outputs": [ + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "bool", + "name": "enabled", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/treasury.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/treasury.json new file mode 100644 index 000000000..18aabb61a --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/treasury.json @@ -0,0 +1,86 @@ +[ + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryNative", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryToken", + "type": "event" + }, + { "stateMutability": "payable", "type": "fallback" }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryNative", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "stateMutability": "payable", "type": "receive" } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/xvs.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/xvs.json new file mode 100644 index 000000000..69092bb4a --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/xvs.json @@ -0,0 +1,716 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "AccountBlacklisted", + "type": "error" + }, + { + "inputs": [], + "name": "AddressesMustDiffer", + "type": "error" + }, + { + "inputs": [], + "name": "MintLimitExceed", + "type": "error" + }, + { + "inputs": [], + "name": "MintedAmountExceed", + "type": "error" + }, + { + "inputs": [], + "name": "NewCapNotGreaterThanMintedTokens", + "type": "error" + }, + { + "inputs": [], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "value", + "type": "bool" + } + ], + "name": "BlacklistUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "MintCapChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitDecreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "source", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "destination", + "type": "address" + } + ], + "name": "MintedTokensMigrated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "address", + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + } + ], + "name": "isBlackListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "source_", + "type": "address" + }, + { + "internalType": "address", + "name": "destination_", + "type": "address" + } + ], + "name": "migrateMinterTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToCap", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToMintedAmount", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newAccessControlAddress_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "minter_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "setMintCap", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + }, + { + "internalType": "bool", + "name": "value_", + "type": "bool" + } + ], + "name": "updateBlacklist", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/xvsBridgeAdmin.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/xvsBridgeAdmin.json new file mode 100644 index 000000000..024450a40 --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/abi/xvsBridgeAdmin.json @@ -0,0 +1,329 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "XVSBridge_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "string", + "name": "signature", + "type": "string" + }, + { + "indexed": false, + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "name": "FunctionRegistryChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "stateMutability": "nonpayable", + "type": "fallback" + }, + { + "inputs": [], + "name": "XVSBridge", + "outputs": [ + { + "internalType": "contract IXVSProxyOFT", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "", + "type": "bytes4" + } + ], + "name": "functionRegistry", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "isTrustedRemote", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner_", + "type": "address" + } + ], + "name": "transferBridgeOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "string[]", + "name": "signatures_", + "type": "string[]" + }, + { + "internalType": "bool[]", + "name": "active_", + "type": "bool[]" + } + ], + "name": "upsertSignature", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/index.ts b/multisig/simulations/arbitrumsepolia/vip-014/index.ts new file mode 100644 index 000000000..b41f4c84e --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-014/index.ts @@ -0,0 +1,225 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip014, { + BOUND_VALIDATOR, + COMPTROLLERS, + COMPTROLLER_BEACON, + DEFAULT_PROXY_ADMIN, + PLP, + PRIME, + PSR, + REWARD_DISTRIBUTORS, + VTOKENS, + VTOKEN_BEACON, + XVS, + XVS_BRIDGE_ADMIN_PROXY, + XVS_STORE, +} from "../../../proposals/arbitrumsepolia/vip-014"; +import COMPTROLLER_ABI from "./abi/Comptroller.json"; +import COMPTROLLER_BEACON_ABI from "./abi/ComptrollerBeacon.json"; +import DEFAULT_PROXY_ADMIN_ABI from "./abi/DefaultProxyAdmin.json"; +import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; +import PRIME_ABI from "./abi/Prime.json"; +import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; +import PSR_ABI from "./abi/ProtocolShareReserve.json"; +import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistrbutor.json"; +import VTOKEN_ABI from "./abi/VToken.json"; +import VTOKEN_BEACON_ABI from "./abi/VTokenBeacon.json"; +import XVS_STORE_ABI from "./abi/XVSStore.json"; +import XVS_VAULT_ABI from "./abi/XVSVault.json"; +import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; +import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; +import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; +import TREASURY_ABI from "./abi/treasury.json"; +import XVS_ABI from "./abi/xvs.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; + +const { arbitrumsepolia } = NETWORK_ADDRESSES; + +const RESILIENT_ORACLE = arbitrumsepolia.RESILIENT_ORACLE; +const CHAINLINK_ORACLE = arbitrumsepolia.CHAINLINK_ORACLE; +const REDSTONE_ORACLE = arbitrumsepolia.REDSTONE_ORACLE; +const NORMAL_TIMELOCK = arbitrumsepolia.NORMAL_TIMELOCK; + +forking(69942668, async () => { + const provider = ethers.provider; + let proxyAdmin: Contract; + let prime: Contract; + let plp: Contract; + let psr: Contract; + let comptrollerBeacon: Contract; + let vTokenBeacon: Contract; + let poolRegistry: Contract; + let xvsVault: Contract; + let xvsStore: Contract; + let xvs: Contract; + let xvsBridgeAdmin: Contract; + let resilientOracle: Contract; + let chainLinkOracle: Contract; + let redstoneOracle: Contract; + let boundValidator: Contract; + let treasury: Contract; + + describe("Pre-VIP behavior", async () => { + before(async () => { + proxyAdmin = new ethers.Contract(DEFAULT_PROXY_ADMIN, DEFAULT_PROXY_ADMIN_ABI, provider); + prime = new ethers.Contract(PRIME, PRIME_ABI, provider); + plp = new ethers.Contract(PLP, PLP_ABI, provider); + psr = new ethers.Contract(PSR, PSR_ABI, provider); + comptrollerBeacon = new ethers.Contract(COMPTROLLER_BEACON, COMPTROLLER_BEACON_ABI, provider); + vTokenBeacon = new ethers.Contract(VTOKEN_BEACON, VTOKEN_BEACON_ABI, provider); + poolRegistry = new ethers.Contract(arbitrumsepolia.POOL_REGISTRY, POOL_REGISTRY_ABI, provider); + xvsVault = new ethers.Contract(arbitrumsepolia.XVS_VAULT_PROXY, XVS_VAULT_ABI, provider); + xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); + xvs = await ethers.getContractAt(XVS_ABI, XVS); + xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, XVS_BRIDGE_ADMIN_PROXY); + resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); + chainLinkOracle = new ethers.Contract(CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); + redstoneOracle = new ethers.Contract(REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); + boundValidator = new ethers.Contract(BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); + treasury = await ethers.getContractAt(TREASURY_ABI, NETWORK_ADDRESSES.arbitrumsepolia.VTREASURY); + }); + + it("owner of proxy admin is guardian", async () => { + expect(await proxyAdmin.owner()).to.equal(arbitrumsepolia.GUARDIAN); + }); + it("pending owner", async () => { + expect(await prime.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await plp.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + + for (const rewardDistributor of REWARD_DISTRIBUTORS) { + it(`should have no pending owner for ${rewardDistributor}`, async () => { + const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + it("pending owner of psr", async () => { + expect(await psr.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`should have no pending owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`should have no pending owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + it("owner of ComptrollerBeacon is guardian", async () => { + expect(await comptrollerBeacon.owner()).to.equal(arbitrumsepolia.GUARDIAN); + }); + + it("owner of VTokenBeacon is guardian", async () => { + expect(await vTokenBeacon.owner()).to.equal(arbitrumsepolia.GUARDIAN); + }); + + it("pending owner of PoolRegistry", async () => { + expect(await poolRegistry.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + it("should have no pending owner", async () => { + expect(await xvsVault.pendingAdmin()).to.equal(ethers.constants.AddressZero); + }); + + it("should have no pending owner", async () => { + expect(await xvsStore.pendingAdmin()).to.equal(ethers.constants.AddressZero); + }); + + it("should have no pending owner", async () => { + expect(await resilientOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await chainLinkOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await redstoneOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await boundValidator.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + }); + + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip014()); + }); + + it("owner of proxy admin is timelock", async () => { + expect(await proxyAdmin.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + + it("pending owner", async () => { + expect(await prime.pendingOwner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + expect(await plp.pendingOwner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + + for (const rewardDistributor of REWARD_DISTRIBUTORS) { + it(`should have Normal Timelock as pending owner for ${rewardDistributor}`, async () => { + const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); + expect(await c.pendingOwner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + } + + it("pending owner of psr", async () => { + expect(await psr.pendingOwner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`correct pending owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.pendingOwner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`correct pending owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.pendingOwner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + } + + it("owner of ComptrollerBeacon is NT", async () => { + expect(await comptrollerBeacon.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + + it("owner of VTokenBeacon is NT", async () => { + expect(await vTokenBeacon.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + + it("pending owner of PoolRegistry is NT", async () => { + expect(await poolRegistry.pendingOwner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + + it("correct pending owner", async () => { + expect(await xvsVault.pendingAdmin()).to.equal(NORMAL_TIMELOCK); + }); + + it("correct pending owner", async () => { + expect(await xvsStore.pendingAdmin()).to.equal(NORMAL_TIMELOCK); + }); + + it("Should set bridge pending owner to Normal Timelock", async () => { + const pendingOwner = await xvsBridgeAdmin.pendingOwner(); + expect(pendingOwner).equals(arbitrumsepolia.NORMAL_TIMELOCK); + }); + it("Should set XVS owner to Normal Timelock", async () => { + const owner = await xvs.owner(); + expect(owner).equals(arbitrumsepolia.NORMAL_TIMELOCK); + }); + it("correct pending owner", async () => { + expect(await resilientOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); + expect(await chainLinkOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); + expect(await redstoneOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); + expect(await boundValidator.pendingOwner()).to.equal(NORMAL_TIMELOCK); + }); + it("Should set pendingOwner to Normal Timelock", async () => { + const pendingOwner = await treasury.pendingOwner(); + expect(pendingOwner).equals(NETWORK_ADDRESSES.arbitrumsepolia.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/multisig/simulations/ethereum/vip-061/abi/Comptroller.json b/multisig/simulations/ethereum/vip-061/abi/Comptroller.json new file mode 100644 index 000000000..f3b2445ac --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/Comptroller.json @@ -0,0 +1,929 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, + { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, + { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, + { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, + { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, + { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "TooMuchRepay", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "expectedSender", "type": "address" }, + { "internalType": "address", "name": "actualSender", "type": "address" } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, + { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "accountAssets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "actionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allMarkets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "approvedDelegates", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "borrowCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "contract VToken", "name": "vToken", "type": "address" } + ], + "name": "checkMembership", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], + "name": "enterMarkets", + "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], + "name": "exitMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAssetsIn", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getBorrowingPower", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "vTokenModify", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isForcedLiquidationEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "isMarketListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [ + { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "bool", "name": "isListed", "type": "bool" }, + { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "seizerContract", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, + { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, + { "internalType": "bool", "name": "paused", "type": "bool" } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "supplyCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "delegate", "type": "address" }, + { "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/ComptrollerBeacon.json b/multisig/simulations/ethereum/vip-061/abi/ComptrollerBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/ComptrollerBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/ConverterNetwork.json b/multisig/simulations/ethereum/vip-061/abi/ConverterNetwork.json new file mode 100644 index 000000000..396f12a91 --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/ConverterNetwork.json @@ -0,0 +1,205 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { "inputs": [], "name": "ConverterAlreadyExists", "type": "error" }, + { "inputs": [], "name": "ConverterDoesNotExist", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "InvalidMaxLoopsLimit", + "type": "error" + }, + { "inputs": [], "name": "InvalidTokenConverterAddress", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], + "name": "ConverterAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], + "name": "ConverterRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], + "name": "addTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allConverters", + "outputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } + ], + "name": "findTokenConverters", + "outputs": [ + { "internalType": "address[]", "name": "converters", "type": "address[]" }, + { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } + ], + "name": "findTokenConvertersForConverters", + "outputs": [ + { "internalType": "address[]", "name": "converters", "type": "address[]" }, + { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getAllConverters", + "outputs": [{ "internalType": "contract IAbstractTokenConverter[]", "name": "converters", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_tokenConverter", "type": "address" }], + "name": "isTokenConverter", + "outputs": [{ "internalType": "bool", "name": "isConverter", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], + "name": "removeTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/DefaultProxyAdmin.json b/multisig/simulations/ethereum/vip-061/abi/DefaultProxyAdmin.json new file mode 100644 index 000000000..9801cfcc7 --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/DefaultProxyAdmin.json @@ -0,0 +1,76 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "changeProxyAdmin", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" } + ], + "name": "upgrade", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" }, + { "internalType": "bytes", "name": "data", "type": "bytes" } + ], + "name": "upgradeAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/PoolRegistry.json b/multisig/simulations/ethereum/vip-061/abi/PoolRegistry.json new file mode 100644 index 000000000..31b1e2a17 --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/PoolRegistry.json @@ -0,0 +1,379 @@ +[ + { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, + { + "name": "Unauthorized", + "type": "error", + "inputs": [ + { "name": "sender", "type": "address", "internalType": "address" }, + { "name": "calledContract", "type": "address", "internalType": "address" }, + { "name": "methodSignature", "type": "string", "internalType": "string" } + ] + }, + { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, + { + "name": "Initialized", + "type": "event", + "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], + "anonymous": false, + "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" + }, + { + "name": "MarketAdded", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" + }, + { + "name": "NewAccessControlManager", + "type": "event", + "inputs": [ + { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, + { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" + }, + { + "name": "OwnershipTransferStarted", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" + }, + { + "name": "OwnershipTransferred", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" + }, + { + "name": "PoolMetadataUpdated", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "oldMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + }, + { + "name": "newMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "anonymous": false, + "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" + }, + { + "name": "PoolNameSet", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, + { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } + ], + "anonymous": false, + "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" + }, + { + "name": "PoolRegistered", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "pool", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "anonymous": false, + "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" + }, + { + "name": "acceptOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x79ba5097", + "stateMutability": "nonpayable" + }, + { + "name": "accessControlManager", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "contract IAccessControlManagerV8" + } + ], + "constant": true, + "signature": "0xb4a0bdf3", + "stateMutability": "view" + }, + { + "name": "addMarket", + "type": "function", + "inputs": [ + { + "name": "input", + "type": "tuple", + "components": [ + { "name": "vToken", "type": "address", "internalType": "contract VToken" }, + { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, + { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, + { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, + { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, + { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistry.AddMarketInput" + } + ], + "outputs": [], + "signature": "0x23dc8d64", + "stateMutability": "nonpayable" + }, + { + "name": "addPool", + "type": "function", + "inputs": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, + { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, + { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } + ], + "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], + "signature": "0xeed873c2", + "stateMutability": "nonpayable" + }, + { + "name": "getAllPools", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "tuple[]", + "value": [], + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool[]" + } + ], + "constant": true, + "signature": "0xd88ff1f4", + "stateMutability": "view" + }, + { + "name": "getPoolByComptroller", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "constant": true, + "signature": "0x7aee632d", + "stateMutability": "view" + }, + { + "name": "getPoolsSupportedByAsset", + "type": "function", + "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], + "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], + "constant": true, + "signature": "0xf36dba38", + "stateMutability": "view" + }, + { + "name": "getVTokenForAsset", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "asset", "type": "address", "internalType": "address" } + ], + "outputs": [{ "name": "", "type": "address", "internalType": "address" }], + "constant": true, + "signature": "0x266e0a7f", + "stateMutability": "view" + }, + { + "name": "getVenusPoolMetadata", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "constant": true, + "signature": "0xa3aefa2c", + "stateMutability": "view" + }, + { + "name": "initialize", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xc4d66de8", + "stateMutability": "nonpayable" + }, + { + "name": "metadata", + "type": "function", + "inputs": [{ "name": "", "type": "address", "internalType": "address" }], + "outputs": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "constant": true, + "signature": "0x2ba21572", + "stateMutability": "view" + }, + { + "name": "owner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x8da5cb5b", + "stateMutability": "view" + }, + { + "name": "pendingOwner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0xe30c3978", + "stateMutability": "view" + }, + { + "name": "renounceOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x715018a6", + "stateMutability": "nonpayable" + }, + { + "name": "setAccessControlManager", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0x0e32cb86", + "stateMutability": "nonpayable" + }, + { + "name": "setPoolName", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "name", "type": "string", "internalType": "string" } + ], + "outputs": [], + "signature": "0x1cb6bb7e", + "stateMutability": "nonpayable" + }, + { + "name": "transferOwnership", + "type": "function", + "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xf2fde38b", + "stateMutability": "nonpayable" + }, + { + "name": "updatePoolMetadata", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { + "name": "metadata_", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "outputs": [], + "signature": "0xff94d958", + "stateMutability": "nonpayable" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/Prime.json b/multisig/simulations/ethereum/vip-061/abi/Prime.json new file mode 100644 index 000000000..e8bfa99ff --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/Prime.json @@ -0,0 +1,763 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, + { "internalType": "address", "name": "_nativeMarket", "type": "address" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, + { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, + { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, + { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, + { "internalType": "bool", "name": "_timeBased", "type": "bool" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, + { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidComptroller", "type": "error" }, + { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "n", "type": "uint256" }, + { "internalType": "uint256", "name": "d", "type": "uint256" } + ], + "name": "InvalidFraction", + "type": "error" + }, + { "inputs": [], "name": "InvalidLength", "type": "error" }, + { "inputs": [], "name": "InvalidLimit", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, + { "inputs": [], "name": "InvalidVToken", "type": "error" }, + { + "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], + "name": "LnNonRealResult", + "type": "error" + }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, + { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, + { "inputs": [], "name": "MarketNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, + { "inputs": [], "name": "WaitMoreTime", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, + { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } + ], + "name": "AlphaUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "Burn", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "InterestClaimed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } + ], + "name": "MintLimitsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } + ], + "name": "MultiplierUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } + ], + "name": "StakedAtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "TokenUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "UserScoreUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "MAXIMUM_XVS_CAP", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MINIMUM_STAKED_XVS", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_MARKET", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "STAKING_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WRAPPED_NATIVE_TOKEN", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "accrueInterest", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" } + ], + "name": "accrueInterestAndUpdateScore", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "alphaDenominator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "alphaNumerator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "calculateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "claimTimeRemaining", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "uint256", "name": "borrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supply", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } + ], + "name": "estimateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "getInterestAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "getPendingRewards", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "internalType": "struct PrimeStorageV1.PendingReward[]", + "name": "pendingRewards", + "type": "tuple[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "incomeDistributionYearly", + "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "xvsVault_", "type": "address" }, + { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, + { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, + { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, + { "internalType": "address", "name": "comptroller_", "type": "address" }, + { "internalType": "address", "name": "oracle_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "name": "initializeV2", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "interests", + "outputs": [ + { "internalType": "uint256", "name": "accrued", "type": "uint256" }, + { "internalType": "uint256", "name": "score", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "irrevocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "isScoreUpdated", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "isUserPrimeHolder", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, + { "internalType": "address[]", "name": "users", "type": "address[]" } + ], + "name": "issue", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, + { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, + { "internalType": "bool", "name": "exists", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "nextScoreUpdateRoundId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingScoreUpdates", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "primeLiquidityProvider", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "revocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } + ], + "name": "setLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "users", "type": "address[]" }, + { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } + ], + "name": "setStakedAt", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "stakedAt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokens", + "outputs": [ + { "internalType": "bool", "name": "exists", "type": "bool" }, + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalIrrevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalRevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalScoreUpdatesRequired", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "unreleasedPLPIncome", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, + { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } + ], + "name": "updateAlpha", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "updateMultipliers", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], + "name": "updateScores", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "vTokenForAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "xvsUpdated", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVault", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultPoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/PrimeLiquidityProvider.json b/multisig/simulations/ethereum/vip-061/abi/PrimeLiquidityProvider.json new file mode 100644 index 000000000..02ca8e0bf --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/PrimeLiquidityProvider.json @@ -0,0 +1,385 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "_timeBased", "type": "bool" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, + { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "balance", "type": "uint256" } + ], + "name": "InsufficientBalance", + "type": "error" + }, + { "inputs": [], "name": "InvalidArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidCaller", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "speed", "type": "uint256" }, + { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } + ], + "name": "InvalidDistributionSpeed", + "type": "error" + }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenAlreadyInitialized", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "TokenNotInitialized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "MaxTokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } + ], + "name": "PrimeTokenUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenDistributionInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "TokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokenTransferredToPrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokensAccrued", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "accrueTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "getEffectiveDistributionSpeed", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], + "name": "initializeTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "lastAccruedBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastAccruedBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "maxTokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } + ], + "name": "setMaxTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } + ], + "name": "setTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "tokenAmountAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/ProtocolShareReserve.json b/multisig/simulations/ethereum/vip-061/abi/ProtocolShareReserve.json new file mode 100644 index 000000000..b33d7c495 --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/ProtocolShareReserve.json @@ -0,0 +1,356 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, + { "internalType": "address", "name": "_wbnb", "type": "address" }, + { "internalType": "address", "name": "_vbnb", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetReleased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IProtocolShareReserve.IncomeType", + "name": "incomeType", + "type": "uint8" + }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "AssetsReservesUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } + ], + "name": "PoolRegistryUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "ReservesUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "CORE_POOL_COMPTROLLER", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MAX_PERCENT", + "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "internalType": "struct ProtocolShareReserve.DistributionConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "addOrUpdateDistributionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } + ], + "name": "assetsReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "distributionTargets", + "outputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "getPercentageDistribution", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "getUnreleasedFunds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address[]", "name": "assets", "type": "address[]" } + ], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "name": "removeDistributionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], + "name": "setPoolRegistry", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAssetReserve", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalDistributions", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/RewardDistrbutor.json b/multisig/simulations/ethereum/vip-061/abi/RewardDistrbutor.json new file mode 100644 index 000000000..249fdd111 --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/RewardDistrbutor.json @@ -0,0 +1,532 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "BorrowLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "BorrowLastRewardingBlockUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "ContributorRewardTokenSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } + ], + "name": "ContributorRewardsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } + ], + "name": "DistributedBorrowerRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } + ], + "name": "DistributedSupplierRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "MarketInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "indexed": false, + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "RewardTokenBorrowIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenBorrowSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RewardTokenGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "RewardTokenSupplyIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenSupplySpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "SupplyLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "SupplyLastRewardingBlockUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "INITIAL_INDEX", + "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "holder", "type": "address" }, + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } + ], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "distributeBorrowerRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "supplier", "type": "address" } + ], + "name": "distributeSupplierRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "grantRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, + { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "initializeMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastContributorBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "rewardToken", + "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenBorrowerIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenContributorSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenSupplierIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplySpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contributor", "type": "address" }, + { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } + ], + "name": "setContributorRewardTokenSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } + ], + "name": "setLastRewardingBlockTimestamps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, + { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } + ], + "name": "setLastRewardingBlocks", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } + ], + "name": "setRewardTokenSpeeds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], + "name": "updateContributorRewards", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "updateRewardTokenBorrowIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "updateRewardTokenSupplyIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/SingleTokenConverter.json b/multisig/simulations/ethereum/vip-061/abi/SingleTokenConverter.json new file mode 100644 index 000000000..8ea10cc8d --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/SingleTokenConverter.json @@ -0,0 +1,587 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { "inputs": [], "name": "AmountInMismatched", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, + { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, + { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, + { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, + { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, + { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, + { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, + { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, + { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, + { "inputs": [], "name": "InvalidToAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, + { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetTransferredToDestination", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } + ], + "name": "BaseAssetUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, + { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "baseAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "conversionConfigurations", + "outputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, + { "internalType": "address", "name": "destinationAddress_", "type": "address" }, + { "internalType": "address", "name": "baseAsset_", "type": "address" }, + { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], + "name": "setBaseAsset", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/SingleTokenConverterBeacon.json b/multisig/simulations/ethereum/vip-061/abi/SingleTokenConverterBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/SingleTokenConverterBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/VToken.json b/multisig/simulations/ethereum/vip-061/abi/VToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/VToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/VTokenBeacon.json b/multisig/simulations/ethereum/vip-061/abi/VTokenBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/VTokenBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/XVSStore.json b/multisig/simulations/ethereum/vip-061/abi/XVSStore.json new file mode 100644 index 000000000..2d9ea2bb2 --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/XVSStore.json @@ -0,0 +1,130 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "AdminTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } + ], + "name": "NewPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnerTransferred", + "type": "event" + }, + { + "constant": false, + "inputs": [], + "name": "acceptAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "emergencyRewardWithdraw", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokens", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "token", "type": "address" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "safeRewardTransfer", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], + "name": "setNewOwner", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], + "name": "setPendingAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "bool", "name": "status", "type": "bool" } + ], + "name": "setRewardToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/XVSVault.json b/multisig/simulations/ethereum/vip-061/abi/XVSVault.json new file mode 100644 index 000000000..51d8d540c --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/XVSVault.json @@ -0,0 +1,787 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Claim", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } + ], + "name": "DelegateChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "DelegateVotesChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Deposit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ExecutedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "name": "PoolAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } + ], + "name": "PoolUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RequestedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } + ], + "name": "RewardAmountUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } + ], + "name": "StoreUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } + ], + "name": "VaultDebtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } + ], + "name": "WithdrawalLockingPeriodUpdated", + "type": "event" + }, + { + "constant": true, + "inputs": [], + "name": "DELEGATION_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "DOMAIN_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "MAX_LOCK_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "SECONDS_PER_YEAR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], + "name": "_become", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, + { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, + { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } + ], + "name": "add", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint32", "name": "", "type": "uint32" } + ], + "name": "checkpoints", + "outputs": [ + { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, + { "internalType": "uint96", "name": "votes", "type": "uint96" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_account", "type": "address" }, + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "claim", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], + "name": "delegate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "delegatee", "type": "address" }, + { "internalType": "uint256", "name": "nonce", "type": "uint256" }, + { "internalType": "uint256", "name": "expiry", "type": "uint256" }, + { "internalType": "uint8", "name": "v", "type": "uint8" }, + { "internalType": "bytes32", "name": "r", "type": "bytes32" }, + { "internalType": "bytes32", "name": "s", "type": "bytes32" } + ], + "name": "delegateBySig", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "delegates", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "deposit", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "executeWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getCurrentVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getEligibleWithdrawalAmount", + "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } + ], + "name": "getPriorVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getRequestedAmount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getUserInfo", + "outputs": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, + { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getWithdrawalRequests", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, + { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } + ], + "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", + "name": "", + "type": "tuple[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "name": "initializeTimeManager", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isStakedToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "nonces", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "numCheckpoints", + "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "pause", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingReward", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "pendingRewardTransfers", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingWithdrawalsBeforeUpgrade", + "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingXVSVaultImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "poolInfos", + "outputs": [ + { "internalType": "contract IBEP20", "name": "token", "type": "address" }, + { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, + { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], + "name": "poolLength", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primePoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeToken", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "requestWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "resume", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], + "name": "rewardTokenAmountsPerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAmountsPerBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } + ], + "name": "set", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], + "name": "setAccessControl", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, + { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } + ], + "name": "setPrimeToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } + ], + "name": "setRewardAmountPerBlockOrSecond", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } + ], + "name": "setWithdrawalLockingPeriod", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_xvs", "type": "address" }, + { "internalType": "address", "name": "_xvsStore", "type": "address" } + ], + "name": "setXvsStore", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAllocPoints", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "totalPendingWithdrawals", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "updatePool", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "vaultPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsStore", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/boundValidator.json b/multisig/simulations/ethereum/vip-061/abi/boundValidator.json new file mode 100644 index 000000000..d16c8fb08 --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/boundValidator.json @@ -0,0 +1,498 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "previousAdmin", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAdmin", + "type": "address" + } + ], + "name": "AdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "beacon", + "type": "address" + } + ], + "name": "BeaconUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "implementation", + "type": "address" + } + ], + "name": "Upgraded", + "type": "event" + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "inputs": [], + "name": "admin", + "outputs": [ + { + "internalType": "address", + "name": "admin_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [ + { + "internalType": "address", + "name": "implementation_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + } + ], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "upgradeToAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "stateMutability": "payable", + "type": "receive" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "upperBound", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "lowerBound", + "type": "uint256" + } + ], + "name": "ValidateConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig", + "name": "config", + "type": "tuple" + } + ], + "name": "setValidateConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "setValidateConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "validateConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "reportedPrice", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "anchorPrice", + "type": "uint256" + } + ], + "name": "validatePriceWithAnchorPrice", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_logic", + "type": "address" + }, + { + "internalType": "address", + "name": "admin_", + "type": "address" + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes" + } + ], + "stateMutability": "payable", + "type": "constructor" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/chainlinkOracle.json b/multisig/simulations/ethereum/vip-061/abi/chainlinkOracle.json new file mode 100644 index 000000000..cdd689acb --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/chainlinkOracle.json @@ -0,0 +1,459 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "vBnbAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "previousPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "requestedPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newPriceMantissa", + "type": "uint256" + } + ], + "name": "PricePosted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManager", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "prices", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + } + ], + "name": "setDirectPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VBep20Interface", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "underlyingPriceMantissa", + "type": "uint256" + } + ], + "name": "setUnderlyingPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "tokenConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/resilientOracle.json b/multisig/simulations/ethereum/vip-061/abi/resilientOracle.json new file mode 100644 index 000000000..35f52caa0 --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/resilientOracle.json @@ -0,0 +1,640 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "nativeMarketAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + }, + { + "internalType": "contract BoundValidatorInterface", + "name": "_boundValidator", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "mainOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "pivotOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "fallbackOracle", + "type": "address" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [ + { + "internalType": "contract BoundValidatorInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "getOracle", + "outputs": [ + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "bool", + "name": "enabled", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/sFrxETHOracle.json b/multisig/simulations/ethereum/vip-061/abi/sFrxETHOracle.json new file mode 100644 index 000000000..b461549ba --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/sFrxETHOracle.json @@ -0,0 +1,148 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_sfrxEthFraxOracle", "type": "address" }, + { "internalType": "address", "name": "_sfrxETH", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "BadPriceData", "type": "error" }, + { "inputs": [], "name": "InvalidTokenAddress", "type": "error" }, + { "inputs": [], "name": "PriceDifferenceExceeded", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxAllowedPriceDifference", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxAllowedPriceDifference", "type": "uint256" } + ], + "name": "MaxAllowedPriceDifferenceUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "SFRXETH", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "SFRXETH_FRAX_ORACLE", + "outputs": [{ "internalType": "contract ISfrxEthFraxOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxAllowedPriceDifference", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" }], + "name": "setMaxAllowedPriceDifference", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/treasury.json b/multisig/simulations/ethereum/vip-061/abi/treasury.json new file mode 100644 index 000000000..18aabb61a --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/treasury.json @@ -0,0 +1,86 @@ +[ + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryNative", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryToken", + "type": "event" + }, + { "stateMutability": "payable", "type": "fallback" }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryNative", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "stateMutability": "payable", "type": "receive" } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/xvs.json b/multisig/simulations/ethereum/vip-061/abi/xvs.json new file mode 100644 index 000000000..69092bb4a --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/xvs.json @@ -0,0 +1,716 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "AccountBlacklisted", + "type": "error" + }, + { + "inputs": [], + "name": "AddressesMustDiffer", + "type": "error" + }, + { + "inputs": [], + "name": "MintLimitExceed", + "type": "error" + }, + { + "inputs": [], + "name": "MintedAmountExceed", + "type": "error" + }, + { + "inputs": [], + "name": "NewCapNotGreaterThanMintedTokens", + "type": "error" + }, + { + "inputs": [], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "value", + "type": "bool" + } + ], + "name": "BlacklistUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "MintCapChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitDecreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "source", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "destination", + "type": "address" + } + ], + "name": "MintedTokensMigrated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "address", + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + } + ], + "name": "isBlackListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "source_", + "type": "address" + }, + { + "internalType": "address", + "name": "destination_", + "type": "address" + } + ], + "name": "migrateMinterTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToCap", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToMintedAmount", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newAccessControlAddress_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "minter_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "setMintCap", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + }, + { + "internalType": "bool", + "name": "value_", + "type": "bool" + } + ], + "name": "updateBlacklist", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/abi/xvsBridgeAdmin.json b/multisig/simulations/ethereum/vip-061/abi/xvsBridgeAdmin.json new file mode 100644 index 000000000..024450a40 --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/abi/xvsBridgeAdmin.json @@ -0,0 +1,329 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "XVSBridge_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "string", + "name": "signature", + "type": "string" + }, + { + "indexed": false, + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "name": "FunctionRegistryChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "stateMutability": "nonpayable", + "type": "fallback" + }, + { + "inputs": [], + "name": "XVSBridge", + "outputs": [ + { + "internalType": "contract IXVSProxyOFT", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "", + "type": "bytes4" + } + ], + "name": "functionRegistry", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "isTrustedRemote", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner_", + "type": "address" + } + ], + "name": "transferBridgeOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "string[]", + "name": "signatures_", + "type": "string[]" + }, + { + "internalType": "bool[]", + "name": "active_", + "type": "bool[]" + } + ], + "name": "upsertSignature", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-061/index.ts b/multisig/simulations/ethereum/vip-061/index.ts new file mode 100644 index 000000000..6f790b852 --- /dev/null +++ b/multisig/simulations/ethereum/vip-061/index.ts @@ -0,0 +1,277 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip061, { + BOUND_VALIDATOR, + COMPTROLLERS, + COMPTROLLER_BEACON, + CONVERTERS, + CONVERTER_NETWORK, + DEFAULT_PROXY_ADMIN, + PLP, + PRIME, + PSR, + REWARD_DISTRIBUTORS, + SFrxETHOracle, + SINGLE_TOKEN_CONVERTER_BEACON, + VTOKENS, + VTOKEN_BEACON, + XVS, + XVS_BRIDGE_ADMIN_PROXY, + XVS_STORE, +} from "../../../proposals/ethereum/vip-061"; +import COMPTROLLER_ABI from "./abi/Comptroller.json"; +import COMPTROLLER_BEACON_ABI from "./abi/ComptrollerBeacon.json"; +import CONVERTER_NETWORK_ABI from "./abi/ConverterNetwork.json"; +import DEFAULT_PROXY_ADMIN_ABI from "./abi/DefaultProxyAdmin.json"; +import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; +import PRIME_ABI from "./abi/Prime.json"; +import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; +import PSR_ABI from "./abi/ProtocolShareReserve.json"; +import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistrbutor.json"; +import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; +import SINGLE_TOKEN_CONVERTER_BEACON_ABI from "./abi/SingleTokenConverterBeacon.json"; +import VTOKEN_ABI from "./abi/VToken.json"; +import VTOKEN_BEACON_ABI from "./abi/VTokenBeacon.json"; +import XVS_STORE_ABI from "./abi/XVSStore.json"; +import XVS_VAULT_ABI from "./abi/XVSVault.json"; +import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; +import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; +import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; +import SFRAXETH_ORACLE_ABI from "./abi/sFrxETHOracle.json"; +import TREASURY_ABI from "./abi/treasury.json"; +import XVS_ABI from "./abi/xvs.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; + +const { ethereum } = NETWORK_ADDRESSES; + +const RESILIENT_ORACLE = ethereum.RESILIENT_ORACLE; +const CHAINLINK_ORACLE = ethereum.CHAINLINK_ORACLE; +const REDSTONE_ORACLE = ethereum.REDSTONE_ORACLE; +const NORMAL_TIMELOCK = ethereum.NORMAL_TIMELOCK; + +forking(20482219, async () => { + const provider = ethers.provider; + let proxyAdmin: Contract; + let prime: Contract; + let plp: Contract; + let psr: Contract; + let comptrollerBeacon: Contract; + let vTokenBeacon: Contract; + let poolRegistry: Contract; + let xvsVault: Contract; + let xvsStore: Contract; + let xvs: Contract; + let xvsBridgeAdmin: Contract; + let resilientOracle: Contract; + let chainLinkOracle: Contract; + let redstoneOracle: Contract; + let boundValidator: Contract; + let treasury: Contract; + let sfrxETHOracle: Contract; + + describe("Pre-VIP behavior", async () => { + before(async () => { + proxyAdmin = new ethers.Contract(DEFAULT_PROXY_ADMIN, DEFAULT_PROXY_ADMIN_ABI, provider); + prime = new ethers.Contract(PRIME, PRIME_ABI, provider); + plp = new ethers.Contract(PLP, PLP_ABI, provider); + psr = new ethers.Contract(PSR, PSR_ABI, provider); + comptrollerBeacon = new ethers.Contract(COMPTROLLER_BEACON, COMPTROLLER_BEACON_ABI, provider); + vTokenBeacon = new ethers.Contract(VTOKEN_BEACON, VTOKEN_BEACON_ABI, provider); + poolRegistry = new ethers.Contract(ethereum.POOL_REGISTRY, POOL_REGISTRY_ABI, provider); + xvsVault = new ethers.Contract(ethereum.XVS_VAULT_PROXY, XVS_VAULT_ABI, provider); + xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); + xvs = await ethers.getContractAt(XVS_ABI, XVS); + xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, XVS_BRIDGE_ADMIN_PROXY); + resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); + chainLinkOracle = new ethers.Contract(CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); + redstoneOracle = new ethers.Contract(REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); + boundValidator = new ethers.Contract(BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); + treasury = await ethers.getContractAt(TREASURY_ABI, NETWORK_ADDRESSES.ethereum.VTREASURY); + sfrxETHOracle = new ethers.Contract(SFrxETHOracle, SFRAXETH_ORACLE_ABI, provider); + }); + + it("owner of proxy admin is guardian", async () => { + expect(await proxyAdmin.owner()).to.equal(ethereum.GUARDIAN); + }); + it("pending owner", async () => { + expect(await prime.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await plp.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + + for (const rewardDistributor of REWARD_DISTRIBUTORS) { + it(`should have no pending owner for ${rewardDistributor}`, async () => { + const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + it("pending owner of psr", async () => { + expect(await psr.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`should have no pending owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`should have no pending owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + it("owner of ComptrollerBeacon is guardian", async () => { + expect(await comptrollerBeacon.owner()).to.equal(ethereum.GUARDIAN); + }); + + it("owner of VTokenBeacon is guardian", async () => { + expect(await vTokenBeacon.owner()).to.equal(ethereum.GUARDIAN); + }); + + it("pending owner of PoolRegistry", async () => { + expect(await poolRegistry.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + it("should have no pending owner", async () => { + expect(await xvsVault.pendingAdmin()).to.equal(ethers.constants.AddressZero); + }); + + it("should have no pending owner", async () => { + expect(await xvsStore.pendingAdmin()).to.equal(ethers.constants.AddressZero); + }); + + it("should have no pending owner", async () => { + expect(await resilientOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await chainLinkOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await redstoneOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await boundValidator.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + + for (const converter of CONVERTERS) { + it(`should have no pending owner for ${converter}`, async () => { + const c = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + it(`should have no pending owner for converter network`, async () => { + const c = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + + it(`should have guardian as owner for converer beacon`, async () => { + const c = new ethers.Contract(SINGLE_TOKEN_CONVERTER_BEACON, SINGLE_TOKEN_CONVERTER_BEACON_ABI, provider); + expect(await c.owner()).to.equal(ethereum.GUARDIAN); + }); + + it("should have no pending owner", async () => { + expect(await sfrxETHOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + }); + + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip061()); + }); + + it("owner of proxy admin is timelock", async () => { + expect(await proxyAdmin.owner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + + it("pending owner", async () => { + expect(await prime.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); + expect(await plp.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + + for (const rewardDistributor of REWARD_DISTRIBUTORS) { + it(`should have Normal Timelock as pending owner for ${rewardDistributor}`, async () => { + const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + } + + it("pending owner of psr", async () => { + expect(await psr.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`correct pending owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`correct pending owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + } + + it("owner of ComptrollerBeacon is NT", async () => { + expect(await comptrollerBeacon.owner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + + it("owner of VTokenBeacon is NT", async () => { + expect(await vTokenBeacon.owner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + + it("pending owner of PoolRegistry is NT", async () => { + expect(await poolRegistry.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + + it("correct pending owner", async () => { + expect(await xvsVault.pendingAdmin()).to.equal(NORMAL_TIMELOCK); + }); + + it("correct pending owner", async () => { + expect(await xvsStore.pendingAdmin()).to.equal(NORMAL_TIMELOCK); + }); + + it("Should set bridge pending owner to Normal Timelock", async () => { + const pendingOwner = await xvsBridgeAdmin.pendingOwner(); + expect(pendingOwner).equals(ethereum.NORMAL_TIMELOCK); + }); + it("Should set XVS owner to Normal Timelock", async () => { + const owner = await xvs.owner(); + expect(owner).equals(ethereum.NORMAL_TIMELOCK); + }); + it("correct pending owner", async () => { + expect(await resilientOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); + expect(await chainLinkOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); + expect(await redstoneOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); + expect(await boundValidator.pendingOwner()).to.equal(NORMAL_TIMELOCK); + }); + it("Should set pendingOwner to Normal Timelock", async () => { + const pendingOwner = await treasury.pendingOwner(); + expect(pendingOwner).equals(NETWORK_ADDRESSES.ethereum.NORMAL_TIMELOCK); + }); + + for (const converter of CONVERTERS) { + it(`should have no pending owner for ${converter}`, async () => { + const c = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + } + + it(`should have no pending owner for converter network`, async () => { + const c = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + + it(`should have NT as owner for converer beacon`, async () => { + const c = new ethers.Contract(SINGLE_TOKEN_CONVERTER_BEACON, SINGLE_TOKEN_CONVERTER_BEACON_ABI, provider); + expect(await c.owner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + + it("correct pending owner", async () => { + expect(await sfrxETHOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); + }); + }); +}); diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/Comptroller.json b/multisig/simulations/opbnbmainnet/vip-021/abi/Comptroller.json new file mode 100644 index 000000000..f3b2445ac --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/Comptroller.json @@ -0,0 +1,929 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, + { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, + { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, + { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, + { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, + { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "TooMuchRepay", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "expectedSender", "type": "address" }, + { "internalType": "address", "name": "actualSender", "type": "address" } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, + { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "accountAssets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "actionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allMarkets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "approvedDelegates", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "borrowCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "contract VToken", "name": "vToken", "type": "address" } + ], + "name": "checkMembership", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], + "name": "enterMarkets", + "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], + "name": "exitMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAssetsIn", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getBorrowingPower", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "vTokenModify", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isForcedLiquidationEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "isMarketListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [ + { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "bool", "name": "isListed", "type": "bool" }, + { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "seizerContract", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, + { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, + { "internalType": "bool", "name": "paused", "type": "bool" } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "supplyCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "delegate", "type": "address" }, + { "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/ComptrollerBeacon.json b/multisig/simulations/opbnbmainnet/vip-021/abi/ComptrollerBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/ComptrollerBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/ConverterNetwork.json b/multisig/simulations/opbnbmainnet/vip-021/abi/ConverterNetwork.json new file mode 100644 index 000000000..396f12a91 --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/ConverterNetwork.json @@ -0,0 +1,205 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { "inputs": [], "name": "ConverterAlreadyExists", "type": "error" }, + { "inputs": [], "name": "ConverterDoesNotExist", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "InvalidMaxLoopsLimit", + "type": "error" + }, + { "inputs": [], "name": "InvalidTokenConverterAddress", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], + "name": "ConverterAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], + "name": "ConverterRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], + "name": "addTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allConverters", + "outputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } + ], + "name": "findTokenConverters", + "outputs": [ + { "internalType": "address[]", "name": "converters", "type": "address[]" }, + { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } + ], + "name": "findTokenConvertersForConverters", + "outputs": [ + { "internalType": "address[]", "name": "converters", "type": "address[]" }, + { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getAllConverters", + "outputs": [{ "internalType": "contract IAbstractTokenConverter[]", "name": "converters", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_tokenConverter", "type": "address" }], + "name": "isTokenConverter", + "outputs": [{ "internalType": "bool", "name": "isConverter", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], + "name": "removeTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/DefaultProxyAdmin.json b/multisig/simulations/opbnbmainnet/vip-021/abi/DefaultProxyAdmin.json new file mode 100644 index 000000000..9801cfcc7 --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/DefaultProxyAdmin.json @@ -0,0 +1,76 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "changeProxyAdmin", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" } + ], + "name": "upgrade", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" }, + { "internalType": "bytes", "name": "data", "type": "bytes" } + ], + "name": "upgradeAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/PoolRegistry.json b/multisig/simulations/opbnbmainnet/vip-021/abi/PoolRegistry.json new file mode 100644 index 000000000..31b1e2a17 --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/PoolRegistry.json @@ -0,0 +1,379 @@ +[ + { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, + { + "name": "Unauthorized", + "type": "error", + "inputs": [ + { "name": "sender", "type": "address", "internalType": "address" }, + { "name": "calledContract", "type": "address", "internalType": "address" }, + { "name": "methodSignature", "type": "string", "internalType": "string" } + ] + }, + { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, + { + "name": "Initialized", + "type": "event", + "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], + "anonymous": false, + "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" + }, + { + "name": "MarketAdded", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" + }, + { + "name": "NewAccessControlManager", + "type": "event", + "inputs": [ + { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, + { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" + }, + { + "name": "OwnershipTransferStarted", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" + }, + { + "name": "OwnershipTransferred", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" + }, + { + "name": "PoolMetadataUpdated", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "oldMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + }, + { + "name": "newMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "anonymous": false, + "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" + }, + { + "name": "PoolNameSet", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, + { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } + ], + "anonymous": false, + "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" + }, + { + "name": "PoolRegistered", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "pool", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "anonymous": false, + "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" + }, + { + "name": "acceptOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x79ba5097", + "stateMutability": "nonpayable" + }, + { + "name": "accessControlManager", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "contract IAccessControlManagerV8" + } + ], + "constant": true, + "signature": "0xb4a0bdf3", + "stateMutability": "view" + }, + { + "name": "addMarket", + "type": "function", + "inputs": [ + { + "name": "input", + "type": "tuple", + "components": [ + { "name": "vToken", "type": "address", "internalType": "contract VToken" }, + { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, + { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, + { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, + { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, + { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistry.AddMarketInput" + } + ], + "outputs": [], + "signature": "0x23dc8d64", + "stateMutability": "nonpayable" + }, + { + "name": "addPool", + "type": "function", + "inputs": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, + { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, + { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } + ], + "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], + "signature": "0xeed873c2", + "stateMutability": "nonpayable" + }, + { + "name": "getAllPools", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "tuple[]", + "value": [], + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool[]" + } + ], + "constant": true, + "signature": "0xd88ff1f4", + "stateMutability": "view" + }, + { + "name": "getPoolByComptroller", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "constant": true, + "signature": "0x7aee632d", + "stateMutability": "view" + }, + { + "name": "getPoolsSupportedByAsset", + "type": "function", + "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], + "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], + "constant": true, + "signature": "0xf36dba38", + "stateMutability": "view" + }, + { + "name": "getVTokenForAsset", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "asset", "type": "address", "internalType": "address" } + ], + "outputs": [{ "name": "", "type": "address", "internalType": "address" }], + "constant": true, + "signature": "0x266e0a7f", + "stateMutability": "view" + }, + { + "name": "getVenusPoolMetadata", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "constant": true, + "signature": "0xa3aefa2c", + "stateMutability": "view" + }, + { + "name": "initialize", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xc4d66de8", + "stateMutability": "nonpayable" + }, + { + "name": "metadata", + "type": "function", + "inputs": [{ "name": "", "type": "address", "internalType": "address" }], + "outputs": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "constant": true, + "signature": "0x2ba21572", + "stateMutability": "view" + }, + { + "name": "owner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x8da5cb5b", + "stateMutability": "view" + }, + { + "name": "pendingOwner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0xe30c3978", + "stateMutability": "view" + }, + { + "name": "renounceOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x715018a6", + "stateMutability": "nonpayable" + }, + { + "name": "setAccessControlManager", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0x0e32cb86", + "stateMutability": "nonpayable" + }, + { + "name": "setPoolName", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "name", "type": "string", "internalType": "string" } + ], + "outputs": [], + "signature": "0x1cb6bb7e", + "stateMutability": "nonpayable" + }, + { + "name": "transferOwnership", + "type": "function", + "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xf2fde38b", + "stateMutability": "nonpayable" + }, + { + "name": "updatePoolMetadata", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { + "name": "metadata_", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "outputs": [], + "signature": "0xff94d958", + "stateMutability": "nonpayable" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/Prime.json b/multisig/simulations/opbnbmainnet/vip-021/abi/Prime.json new file mode 100644 index 000000000..e8bfa99ff --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/Prime.json @@ -0,0 +1,763 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, + { "internalType": "address", "name": "_nativeMarket", "type": "address" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, + { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, + { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, + { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, + { "internalType": "bool", "name": "_timeBased", "type": "bool" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, + { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidComptroller", "type": "error" }, + { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "n", "type": "uint256" }, + { "internalType": "uint256", "name": "d", "type": "uint256" } + ], + "name": "InvalidFraction", + "type": "error" + }, + { "inputs": [], "name": "InvalidLength", "type": "error" }, + { "inputs": [], "name": "InvalidLimit", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, + { "inputs": [], "name": "InvalidVToken", "type": "error" }, + { + "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], + "name": "LnNonRealResult", + "type": "error" + }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, + { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, + { "inputs": [], "name": "MarketNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, + { "inputs": [], "name": "WaitMoreTime", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, + { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } + ], + "name": "AlphaUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "Burn", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "InterestClaimed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } + ], + "name": "MintLimitsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } + ], + "name": "MultiplierUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } + ], + "name": "StakedAtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "TokenUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "UserScoreUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "MAXIMUM_XVS_CAP", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MINIMUM_STAKED_XVS", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_MARKET", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "STAKING_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WRAPPED_NATIVE_TOKEN", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "accrueInterest", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" } + ], + "name": "accrueInterestAndUpdateScore", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "alphaDenominator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "alphaNumerator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "calculateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "claimTimeRemaining", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "uint256", "name": "borrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supply", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } + ], + "name": "estimateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "getInterestAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "getPendingRewards", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "internalType": "struct PrimeStorageV1.PendingReward[]", + "name": "pendingRewards", + "type": "tuple[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "incomeDistributionYearly", + "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "xvsVault_", "type": "address" }, + { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, + { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, + { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, + { "internalType": "address", "name": "comptroller_", "type": "address" }, + { "internalType": "address", "name": "oracle_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "name": "initializeV2", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "interests", + "outputs": [ + { "internalType": "uint256", "name": "accrued", "type": "uint256" }, + { "internalType": "uint256", "name": "score", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "irrevocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "isScoreUpdated", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "isUserPrimeHolder", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, + { "internalType": "address[]", "name": "users", "type": "address[]" } + ], + "name": "issue", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, + { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, + { "internalType": "bool", "name": "exists", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "nextScoreUpdateRoundId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingScoreUpdates", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "primeLiquidityProvider", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "revocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } + ], + "name": "setLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "users", "type": "address[]" }, + { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } + ], + "name": "setStakedAt", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "stakedAt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokens", + "outputs": [ + { "internalType": "bool", "name": "exists", "type": "bool" }, + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalIrrevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalRevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalScoreUpdatesRequired", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "unreleasedPLPIncome", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, + { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } + ], + "name": "updateAlpha", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "updateMultipliers", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], + "name": "updateScores", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "vTokenForAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "xvsUpdated", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVault", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultPoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/PrimeLiquidityProvider.json b/multisig/simulations/opbnbmainnet/vip-021/abi/PrimeLiquidityProvider.json new file mode 100644 index 000000000..02ca8e0bf --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/PrimeLiquidityProvider.json @@ -0,0 +1,385 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "_timeBased", "type": "bool" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, + { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "balance", "type": "uint256" } + ], + "name": "InsufficientBalance", + "type": "error" + }, + { "inputs": [], "name": "InvalidArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidCaller", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "speed", "type": "uint256" }, + { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } + ], + "name": "InvalidDistributionSpeed", + "type": "error" + }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenAlreadyInitialized", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "TokenNotInitialized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "MaxTokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } + ], + "name": "PrimeTokenUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenDistributionInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "TokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokenTransferredToPrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokensAccrued", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "accrueTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "getEffectiveDistributionSpeed", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], + "name": "initializeTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "lastAccruedBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastAccruedBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "maxTokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } + ], + "name": "setMaxTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } + ], + "name": "setTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "tokenAmountAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/ProtocolShareReserve.json b/multisig/simulations/opbnbmainnet/vip-021/abi/ProtocolShareReserve.json new file mode 100644 index 000000000..b33d7c495 --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/ProtocolShareReserve.json @@ -0,0 +1,356 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, + { "internalType": "address", "name": "_wbnb", "type": "address" }, + { "internalType": "address", "name": "_vbnb", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetReleased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IProtocolShareReserve.IncomeType", + "name": "incomeType", + "type": "uint8" + }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "AssetsReservesUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } + ], + "name": "PoolRegistryUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "ReservesUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "CORE_POOL_COMPTROLLER", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MAX_PERCENT", + "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "internalType": "struct ProtocolShareReserve.DistributionConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "addOrUpdateDistributionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } + ], + "name": "assetsReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "distributionTargets", + "outputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "getPercentageDistribution", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "getUnreleasedFunds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address[]", "name": "assets", "type": "address[]" } + ], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "name": "removeDistributionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], + "name": "setPoolRegistry", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAssetReserve", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalDistributions", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/RewardDistrbutor.json b/multisig/simulations/opbnbmainnet/vip-021/abi/RewardDistrbutor.json new file mode 100644 index 000000000..249fdd111 --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/RewardDistrbutor.json @@ -0,0 +1,532 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "BorrowLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "BorrowLastRewardingBlockUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "ContributorRewardTokenSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } + ], + "name": "ContributorRewardsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } + ], + "name": "DistributedBorrowerRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } + ], + "name": "DistributedSupplierRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "MarketInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "indexed": false, + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "RewardTokenBorrowIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenBorrowSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RewardTokenGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "RewardTokenSupplyIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenSupplySpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "SupplyLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "SupplyLastRewardingBlockUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "INITIAL_INDEX", + "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "holder", "type": "address" }, + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } + ], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "distributeBorrowerRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "supplier", "type": "address" } + ], + "name": "distributeSupplierRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "grantRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, + { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "initializeMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastContributorBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "rewardToken", + "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenBorrowerIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenContributorSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenSupplierIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplySpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contributor", "type": "address" }, + { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } + ], + "name": "setContributorRewardTokenSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } + ], + "name": "setLastRewardingBlockTimestamps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, + { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } + ], + "name": "setLastRewardingBlocks", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } + ], + "name": "setRewardTokenSpeeds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], + "name": "updateContributorRewards", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "updateRewardTokenBorrowIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "updateRewardTokenSupplyIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/SingleTokenConverter.json b/multisig/simulations/opbnbmainnet/vip-021/abi/SingleTokenConverter.json new file mode 100644 index 000000000..8ea10cc8d --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/SingleTokenConverter.json @@ -0,0 +1,587 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { "inputs": [], "name": "AmountInMismatched", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, + { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, + { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, + { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, + { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, + { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, + { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, + { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, + { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, + { "inputs": [], "name": "InvalidToAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, + { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetTransferredToDestination", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } + ], + "name": "BaseAssetUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, + { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "baseAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "conversionConfigurations", + "outputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, + { "internalType": "address", "name": "destinationAddress_", "type": "address" }, + { "internalType": "address", "name": "baseAsset_", "type": "address" }, + { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], + "name": "setBaseAsset", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/SingleTokenConverterBeacon.json b/multisig/simulations/opbnbmainnet/vip-021/abi/SingleTokenConverterBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/SingleTokenConverterBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/VToken.json b/multisig/simulations/opbnbmainnet/vip-021/abi/VToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/VToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/VTokenBeacon.json b/multisig/simulations/opbnbmainnet/vip-021/abi/VTokenBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/VTokenBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/XVSStore.json b/multisig/simulations/opbnbmainnet/vip-021/abi/XVSStore.json new file mode 100644 index 000000000..2d9ea2bb2 --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/XVSStore.json @@ -0,0 +1,130 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "AdminTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } + ], + "name": "NewPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnerTransferred", + "type": "event" + }, + { + "constant": false, + "inputs": [], + "name": "acceptAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "emergencyRewardWithdraw", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokens", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "token", "type": "address" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "safeRewardTransfer", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], + "name": "setNewOwner", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], + "name": "setPendingAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "bool", "name": "status", "type": "bool" } + ], + "name": "setRewardToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/XVSVault.json b/multisig/simulations/opbnbmainnet/vip-021/abi/XVSVault.json new file mode 100644 index 000000000..51d8d540c --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/XVSVault.json @@ -0,0 +1,787 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Claim", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } + ], + "name": "DelegateChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "DelegateVotesChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Deposit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ExecutedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "name": "PoolAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } + ], + "name": "PoolUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RequestedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } + ], + "name": "RewardAmountUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } + ], + "name": "StoreUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } + ], + "name": "VaultDebtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } + ], + "name": "WithdrawalLockingPeriodUpdated", + "type": "event" + }, + { + "constant": true, + "inputs": [], + "name": "DELEGATION_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "DOMAIN_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "MAX_LOCK_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "SECONDS_PER_YEAR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], + "name": "_become", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, + { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, + { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } + ], + "name": "add", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint32", "name": "", "type": "uint32" } + ], + "name": "checkpoints", + "outputs": [ + { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, + { "internalType": "uint96", "name": "votes", "type": "uint96" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_account", "type": "address" }, + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "claim", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], + "name": "delegate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "delegatee", "type": "address" }, + { "internalType": "uint256", "name": "nonce", "type": "uint256" }, + { "internalType": "uint256", "name": "expiry", "type": "uint256" }, + { "internalType": "uint8", "name": "v", "type": "uint8" }, + { "internalType": "bytes32", "name": "r", "type": "bytes32" }, + { "internalType": "bytes32", "name": "s", "type": "bytes32" } + ], + "name": "delegateBySig", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "delegates", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "deposit", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "executeWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getCurrentVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getEligibleWithdrawalAmount", + "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } + ], + "name": "getPriorVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getRequestedAmount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getUserInfo", + "outputs": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, + { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getWithdrawalRequests", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, + { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } + ], + "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", + "name": "", + "type": "tuple[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "name": "initializeTimeManager", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isStakedToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "nonces", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "numCheckpoints", + "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "pause", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingReward", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "pendingRewardTransfers", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingWithdrawalsBeforeUpgrade", + "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingXVSVaultImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "poolInfos", + "outputs": [ + { "internalType": "contract IBEP20", "name": "token", "type": "address" }, + { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, + { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], + "name": "poolLength", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primePoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeToken", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "requestWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "resume", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], + "name": "rewardTokenAmountsPerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAmountsPerBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } + ], + "name": "set", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], + "name": "setAccessControl", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, + { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } + ], + "name": "setPrimeToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } + ], + "name": "setRewardAmountPerBlockOrSecond", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } + ], + "name": "setWithdrawalLockingPeriod", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_xvs", "type": "address" }, + { "internalType": "address", "name": "_xvsStore", "type": "address" } + ], + "name": "setXvsStore", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAllocPoints", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "totalPendingWithdrawals", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "updatePool", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "vaultPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsStore", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/boundValidator.json b/multisig/simulations/opbnbmainnet/vip-021/abi/boundValidator.json new file mode 100644 index 000000000..d16c8fb08 --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/boundValidator.json @@ -0,0 +1,498 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "previousAdmin", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAdmin", + "type": "address" + } + ], + "name": "AdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "beacon", + "type": "address" + } + ], + "name": "BeaconUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "implementation", + "type": "address" + } + ], + "name": "Upgraded", + "type": "event" + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "inputs": [], + "name": "admin", + "outputs": [ + { + "internalType": "address", + "name": "admin_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [ + { + "internalType": "address", + "name": "implementation_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + } + ], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "upgradeToAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "stateMutability": "payable", + "type": "receive" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "upperBound", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "lowerBound", + "type": "uint256" + } + ], + "name": "ValidateConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig", + "name": "config", + "type": "tuple" + } + ], + "name": "setValidateConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "setValidateConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "validateConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "reportedPrice", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "anchorPrice", + "type": "uint256" + } + ], + "name": "validatePriceWithAnchorPrice", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_logic", + "type": "address" + }, + { + "internalType": "address", + "name": "admin_", + "type": "address" + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes" + } + ], + "stateMutability": "payable", + "type": "constructor" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/chainlinkOracle.json b/multisig/simulations/opbnbmainnet/vip-021/abi/chainlinkOracle.json new file mode 100644 index 000000000..cdd689acb --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/chainlinkOracle.json @@ -0,0 +1,459 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "vBnbAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "previousPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "requestedPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newPriceMantissa", + "type": "uint256" + } + ], + "name": "PricePosted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManager", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "prices", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + } + ], + "name": "setDirectPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VBep20Interface", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "underlyingPriceMantissa", + "type": "uint256" + } + ], + "name": "setUnderlyingPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "tokenConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/resilientOracle.json b/multisig/simulations/opbnbmainnet/vip-021/abi/resilientOracle.json new file mode 100644 index 000000000..35f52caa0 --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/resilientOracle.json @@ -0,0 +1,640 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "nativeMarketAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + }, + { + "internalType": "contract BoundValidatorInterface", + "name": "_boundValidator", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "mainOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "pivotOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "fallbackOracle", + "type": "address" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [ + { + "internalType": "contract BoundValidatorInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "getOracle", + "outputs": [ + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "bool", + "name": "enabled", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/sFrxETHOracle.json b/multisig/simulations/opbnbmainnet/vip-021/abi/sFrxETHOracle.json new file mode 100644 index 000000000..b461549ba --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/sFrxETHOracle.json @@ -0,0 +1,148 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_sfrxEthFraxOracle", "type": "address" }, + { "internalType": "address", "name": "_sfrxETH", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "BadPriceData", "type": "error" }, + { "inputs": [], "name": "InvalidTokenAddress", "type": "error" }, + { "inputs": [], "name": "PriceDifferenceExceeded", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxAllowedPriceDifference", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxAllowedPriceDifference", "type": "uint256" } + ], + "name": "MaxAllowedPriceDifferenceUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "SFRXETH", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "SFRXETH_FRAX_ORACLE", + "outputs": [{ "internalType": "contract ISfrxEthFraxOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxAllowedPriceDifference", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" }], + "name": "setMaxAllowedPriceDifference", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/treasury.json b/multisig/simulations/opbnbmainnet/vip-021/abi/treasury.json new file mode 100644 index 000000000..18aabb61a --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/treasury.json @@ -0,0 +1,86 @@ +[ + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryNative", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryToken", + "type": "event" + }, + { "stateMutability": "payable", "type": "fallback" }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryNative", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "stateMutability": "payable", "type": "receive" } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/xvs.json b/multisig/simulations/opbnbmainnet/vip-021/abi/xvs.json new file mode 100644 index 000000000..69092bb4a --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/xvs.json @@ -0,0 +1,716 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "AccountBlacklisted", + "type": "error" + }, + { + "inputs": [], + "name": "AddressesMustDiffer", + "type": "error" + }, + { + "inputs": [], + "name": "MintLimitExceed", + "type": "error" + }, + { + "inputs": [], + "name": "MintedAmountExceed", + "type": "error" + }, + { + "inputs": [], + "name": "NewCapNotGreaterThanMintedTokens", + "type": "error" + }, + { + "inputs": [], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "value", + "type": "bool" + } + ], + "name": "BlacklistUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "MintCapChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitDecreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "source", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "destination", + "type": "address" + } + ], + "name": "MintedTokensMigrated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "address", + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + } + ], + "name": "isBlackListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "source_", + "type": "address" + }, + { + "internalType": "address", + "name": "destination_", + "type": "address" + } + ], + "name": "migrateMinterTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToCap", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToMintedAmount", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newAccessControlAddress_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "minter_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "setMintCap", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + }, + { + "internalType": "bool", + "name": "value_", + "type": "bool" + } + ], + "name": "updateBlacklist", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/xvsBridgeAdmin.json b/multisig/simulations/opbnbmainnet/vip-021/abi/xvsBridgeAdmin.json new file mode 100644 index 000000000..024450a40 --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/abi/xvsBridgeAdmin.json @@ -0,0 +1,329 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "XVSBridge_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "string", + "name": "signature", + "type": "string" + }, + { + "indexed": false, + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "name": "FunctionRegistryChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "stateMutability": "nonpayable", + "type": "fallback" + }, + { + "inputs": [], + "name": "XVSBridge", + "outputs": [ + { + "internalType": "contract IXVSProxyOFT", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "", + "type": "bytes4" + } + ], + "name": "functionRegistry", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "isTrustedRemote", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner_", + "type": "address" + } + ], + "name": "transferBridgeOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "string[]", + "name": "signatures_", + "type": "string[]" + }, + { + "internalType": "bool[]", + "name": "active_", + "type": "bool[]" + } + ], + "name": "upsertSignature", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-021/index.ts b/multisig/simulations/opbnbmainnet/vip-021/index.ts new file mode 100644 index 000000000..1694093ab --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-021/index.ts @@ -0,0 +1,181 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip021, { + BOUND_VALIDATOR, + COMPTROLLERS, + COMPTROLLER_BEACON, + DEFAULT_PROXY_ADMIN, + PSR, + VTOKENS, + VTOKEN_BEACON, + XVS, + XVS_BRIDGE_ADMIN_PROXY, + XVS_STORE, +} from "../../../proposals/opbnbmainnet/vip-021"; +import COMPTROLLER_ABI from "./abi/Comptroller.json"; +import COMPTROLLER_BEACON_ABI from "./abi/ComptrollerBeacon.json"; +import DEFAULT_PROXY_ADMIN_ABI from "./abi/DefaultProxyAdmin.json"; +import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; +import PSR_ABI from "./abi/ProtocolShareReserve.json"; +import VTOKEN_ABI from "./abi/VToken.json"; +import VTOKEN_BEACON_ABI from "./abi/VTokenBeacon.json"; +import XVS_STORE_ABI from "./abi/XVSStore.json"; +import XVS_VAULT_ABI from "./abi/XVSVault.json"; +import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; +import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; +import TREASURY_ABI from "./abi/treasury.json"; +import XVS_ABI from "./abi/xvs.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; + +const { opbnbmainnet } = NETWORK_ADDRESSES; + +const RESILIENT_ORACLE = opbnbmainnet.RESILIENT_ORACLE; +const NORMAL_TIMELOCK = opbnbmainnet.NORMAL_TIMELOCK; + +forking(28761242, async () => { + const provider = ethers.provider; + let proxyAdmin: Contract; + let psr: Contract; + let comptrollerBeacon: Contract; + let vTokenBeacon: Contract; + let poolRegistry: Contract; + let xvsVault: Contract; + let xvsStore: Contract; + let xvs: Contract; + let xvsBridgeAdmin: Contract; + let resilientOracle: Contract; + let boundValidator: Contract; + let treasury: Contract; + + describe("Pre-VIP behavior", async () => { + before(async () => { + proxyAdmin = new ethers.Contract(DEFAULT_PROXY_ADMIN, DEFAULT_PROXY_ADMIN_ABI, provider); + psr = new ethers.Contract(PSR, PSR_ABI, provider); + comptrollerBeacon = new ethers.Contract(COMPTROLLER_BEACON, COMPTROLLER_BEACON_ABI, provider); + vTokenBeacon = new ethers.Contract(VTOKEN_BEACON, VTOKEN_BEACON_ABI, provider); + poolRegistry = new ethers.Contract(opbnbmainnet.POOL_REGISTRY, POOL_REGISTRY_ABI, provider); + xvsVault = new ethers.Contract(opbnbmainnet.XVS_VAULT_PROXY, XVS_VAULT_ABI, provider); + xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); + xvs = await ethers.getContractAt(XVS_ABI, XVS); + xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, XVS_BRIDGE_ADMIN_PROXY); + resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); + boundValidator = new ethers.Contract(BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); + treasury = await ethers.getContractAt(TREASURY_ABI, NETWORK_ADDRESSES.opbnbmainnet.VTREASURY); + }); + + it("owner of proxy admin is guardian", async () => { + expect(await proxyAdmin.owner()).to.equal(opbnbmainnet.GUARDIAN); + }); + + it("pending owner of psr", async () => { + expect(await psr.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`should have no pending owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`should have no pending owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + it("owner of ComptrollerBeacon is guardian", async () => { + expect(await comptrollerBeacon.owner()).to.equal(opbnbmainnet.GUARDIAN); + }); + + it("owner of VTokenBeacon is guardian", async () => { + expect(await vTokenBeacon.owner()).to.equal(opbnbmainnet.GUARDIAN); + }); + + it("pending owner of PoolRegistry", async () => { + expect(await poolRegistry.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + it("should have no pending owner", async () => { + expect(await xvsVault.pendingAdmin()).to.equal(ethers.constants.AddressZero); + }); + + it("should have no pending owner", async () => { + expect(await xvsStore.pendingAdmin()).to.equal(ethers.constants.AddressZero); + }); + + it("should have no pending owner", async () => { + expect(await resilientOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await boundValidator.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + }); + + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip021()); + }); + + it("owner of proxy admin is timelock", async () => { + expect(await proxyAdmin.owner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); + }); + + it("pending owner of psr", async () => { + expect(await psr.pendingOwner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`correct pending owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.pendingOwner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`correct pending owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.pendingOwner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); + }); + } + + it("owner of ComptrollerBeacon is NT", async () => { + expect(await comptrollerBeacon.owner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); + }); + + it("owner of VTokenBeacon is NT", async () => { + expect(await vTokenBeacon.owner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); + }); + + it("pending owner of PoolRegistry is NT", async () => { + expect(await poolRegistry.pendingOwner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); + }); + + it("correct pending owner", async () => { + expect(await xvsVault.pendingAdmin()).to.equal(NORMAL_TIMELOCK); + }); + + it("correct pending owner", async () => { + expect(await xvsStore.pendingAdmin()).to.equal(NORMAL_TIMELOCK); + }); + + it("Should set bridge pending owner to Normal Timelock", async () => { + const pendingOwner = await xvsBridgeAdmin.pendingOwner(); + expect(pendingOwner).equals(opbnbmainnet.NORMAL_TIMELOCK); + }); + it("Should set XVS owner to Normal Timelock", async () => { + const owner = await xvs.owner(); + expect(owner).equals(opbnbmainnet.NORMAL_TIMELOCK); + }); + it("correct pending owner", async () => { + expect(await resilientOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); + expect(await boundValidator.pendingOwner()).to.equal(NORMAL_TIMELOCK); + }); + it("Should set pendingOwner to Normal Timelock", async () => { + const pendingOwner = await treasury.pendingOwner(); + expect(pendingOwner).equals(NETWORK_ADDRESSES.opbnbmainnet.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/Comptroller.json b/multisig/simulations/opbnbtestnet/vip-021/abi/Comptroller.json new file mode 100644 index 000000000..f3b2445ac --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/Comptroller.json @@ -0,0 +1,929 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, + { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, + { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, + { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, + { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, + { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "TooMuchRepay", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "expectedSender", "type": "address" }, + { "internalType": "address", "name": "actualSender", "type": "address" } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, + { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "accountAssets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "actionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allMarkets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "approvedDelegates", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "borrowCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "contract VToken", "name": "vToken", "type": "address" } + ], + "name": "checkMembership", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], + "name": "enterMarkets", + "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], + "name": "exitMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAssetsIn", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getBorrowingPower", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "vTokenModify", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isForcedLiquidationEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "isMarketListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [ + { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "bool", "name": "isListed", "type": "bool" }, + { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "seizerContract", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, + { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, + { "internalType": "bool", "name": "paused", "type": "bool" } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "supplyCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "delegate", "type": "address" }, + { "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/ComptrollerBeacon.json b/multisig/simulations/opbnbtestnet/vip-021/abi/ComptrollerBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/ComptrollerBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/ConverterNetwork.json b/multisig/simulations/opbnbtestnet/vip-021/abi/ConverterNetwork.json new file mode 100644 index 000000000..396f12a91 --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/ConverterNetwork.json @@ -0,0 +1,205 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { "inputs": [], "name": "ConverterAlreadyExists", "type": "error" }, + { "inputs": [], "name": "ConverterDoesNotExist", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "InvalidMaxLoopsLimit", + "type": "error" + }, + { "inputs": [], "name": "InvalidTokenConverterAddress", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], + "name": "ConverterAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], + "name": "ConverterRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], + "name": "addTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allConverters", + "outputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } + ], + "name": "findTokenConverters", + "outputs": [ + { "internalType": "address[]", "name": "converters", "type": "address[]" }, + { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } + ], + "name": "findTokenConvertersForConverters", + "outputs": [ + { "internalType": "address[]", "name": "converters", "type": "address[]" }, + { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getAllConverters", + "outputs": [{ "internalType": "contract IAbstractTokenConverter[]", "name": "converters", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_tokenConverter", "type": "address" }], + "name": "isTokenConverter", + "outputs": [{ "internalType": "bool", "name": "isConverter", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], + "name": "removeTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/DefaultProxyAdmin.json b/multisig/simulations/opbnbtestnet/vip-021/abi/DefaultProxyAdmin.json new file mode 100644 index 000000000..9801cfcc7 --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/DefaultProxyAdmin.json @@ -0,0 +1,76 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "changeProxyAdmin", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" } + ], + "name": "upgrade", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" }, + { "internalType": "bytes", "name": "data", "type": "bytes" } + ], + "name": "upgradeAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/PoolRegistry.json b/multisig/simulations/opbnbtestnet/vip-021/abi/PoolRegistry.json new file mode 100644 index 000000000..31b1e2a17 --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/PoolRegistry.json @@ -0,0 +1,379 @@ +[ + { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, + { + "name": "Unauthorized", + "type": "error", + "inputs": [ + { "name": "sender", "type": "address", "internalType": "address" }, + { "name": "calledContract", "type": "address", "internalType": "address" }, + { "name": "methodSignature", "type": "string", "internalType": "string" } + ] + }, + { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, + { + "name": "Initialized", + "type": "event", + "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], + "anonymous": false, + "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" + }, + { + "name": "MarketAdded", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" + }, + { + "name": "NewAccessControlManager", + "type": "event", + "inputs": [ + { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, + { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" + }, + { + "name": "OwnershipTransferStarted", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" + }, + { + "name": "OwnershipTransferred", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" + }, + { + "name": "PoolMetadataUpdated", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "oldMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + }, + { + "name": "newMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "anonymous": false, + "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" + }, + { + "name": "PoolNameSet", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, + { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } + ], + "anonymous": false, + "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" + }, + { + "name": "PoolRegistered", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "pool", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "anonymous": false, + "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" + }, + { + "name": "acceptOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x79ba5097", + "stateMutability": "nonpayable" + }, + { + "name": "accessControlManager", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "contract IAccessControlManagerV8" + } + ], + "constant": true, + "signature": "0xb4a0bdf3", + "stateMutability": "view" + }, + { + "name": "addMarket", + "type": "function", + "inputs": [ + { + "name": "input", + "type": "tuple", + "components": [ + { "name": "vToken", "type": "address", "internalType": "contract VToken" }, + { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, + { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, + { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, + { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, + { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistry.AddMarketInput" + } + ], + "outputs": [], + "signature": "0x23dc8d64", + "stateMutability": "nonpayable" + }, + { + "name": "addPool", + "type": "function", + "inputs": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, + { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, + { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } + ], + "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], + "signature": "0xeed873c2", + "stateMutability": "nonpayable" + }, + { + "name": "getAllPools", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "tuple[]", + "value": [], + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool[]" + } + ], + "constant": true, + "signature": "0xd88ff1f4", + "stateMutability": "view" + }, + { + "name": "getPoolByComptroller", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "constant": true, + "signature": "0x7aee632d", + "stateMutability": "view" + }, + { + "name": "getPoolsSupportedByAsset", + "type": "function", + "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], + "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], + "constant": true, + "signature": "0xf36dba38", + "stateMutability": "view" + }, + { + "name": "getVTokenForAsset", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "asset", "type": "address", "internalType": "address" } + ], + "outputs": [{ "name": "", "type": "address", "internalType": "address" }], + "constant": true, + "signature": "0x266e0a7f", + "stateMutability": "view" + }, + { + "name": "getVenusPoolMetadata", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "constant": true, + "signature": "0xa3aefa2c", + "stateMutability": "view" + }, + { + "name": "initialize", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xc4d66de8", + "stateMutability": "nonpayable" + }, + { + "name": "metadata", + "type": "function", + "inputs": [{ "name": "", "type": "address", "internalType": "address" }], + "outputs": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "constant": true, + "signature": "0x2ba21572", + "stateMutability": "view" + }, + { + "name": "owner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x8da5cb5b", + "stateMutability": "view" + }, + { + "name": "pendingOwner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0xe30c3978", + "stateMutability": "view" + }, + { + "name": "renounceOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x715018a6", + "stateMutability": "nonpayable" + }, + { + "name": "setAccessControlManager", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0x0e32cb86", + "stateMutability": "nonpayable" + }, + { + "name": "setPoolName", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "name", "type": "string", "internalType": "string" } + ], + "outputs": [], + "signature": "0x1cb6bb7e", + "stateMutability": "nonpayable" + }, + { + "name": "transferOwnership", + "type": "function", + "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xf2fde38b", + "stateMutability": "nonpayable" + }, + { + "name": "updatePoolMetadata", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { + "name": "metadata_", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "outputs": [], + "signature": "0xff94d958", + "stateMutability": "nonpayable" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/Prime.json b/multisig/simulations/opbnbtestnet/vip-021/abi/Prime.json new file mode 100644 index 000000000..e8bfa99ff --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/Prime.json @@ -0,0 +1,763 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, + { "internalType": "address", "name": "_nativeMarket", "type": "address" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, + { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, + { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, + { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, + { "internalType": "bool", "name": "_timeBased", "type": "bool" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, + { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidComptroller", "type": "error" }, + { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "n", "type": "uint256" }, + { "internalType": "uint256", "name": "d", "type": "uint256" } + ], + "name": "InvalidFraction", + "type": "error" + }, + { "inputs": [], "name": "InvalidLength", "type": "error" }, + { "inputs": [], "name": "InvalidLimit", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, + { "inputs": [], "name": "InvalidVToken", "type": "error" }, + { + "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], + "name": "LnNonRealResult", + "type": "error" + }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, + { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, + { "inputs": [], "name": "MarketNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, + { "inputs": [], "name": "WaitMoreTime", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, + { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } + ], + "name": "AlphaUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "Burn", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "InterestClaimed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } + ], + "name": "MintLimitsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } + ], + "name": "MultiplierUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } + ], + "name": "StakedAtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "TokenUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "UserScoreUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "MAXIMUM_XVS_CAP", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MINIMUM_STAKED_XVS", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_MARKET", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "STAKING_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WRAPPED_NATIVE_TOKEN", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "accrueInterest", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" } + ], + "name": "accrueInterestAndUpdateScore", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "alphaDenominator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "alphaNumerator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "calculateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "claimTimeRemaining", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "uint256", "name": "borrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supply", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } + ], + "name": "estimateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "getInterestAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "getPendingRewards", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "internalType": "struct PrimeStorageV1.PendingReward[]", + "name": "pendingRewards", + "type": "tuple[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "incomeDistributionYearly", + "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "xvsVault_", "type": "address" }, + { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, + { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, + { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, + { "internalType": "address", "name": "comptroller_", "type": "address" }, + { "internalType": "address", "name": "oracle_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "name": "initializeV2", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "interests", + "outputs": [ + { "internalType": "uint256", "name": "accrued", "type": "uint256" }, + { "internalType": "uint256", "name": "score", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "irrevocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "isScoreUpdated", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "isUserPrimeHolder", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, + { "internalType": "address[]", "name": "users", "type": "address[]" } + ], + "name": "issue", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, + { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, + { "internalType": "bool", "name": "exists", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "nextScoreUpdateRoundId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingScoreUpdates", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "primeLiquidityProvider", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "revocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } + ], + "name": "setLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "users", "type": "address[]" }, + { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } + ], + "name": "setStakedAt", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "stakedAt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokens", + "outputs": [ + { "internalType": "bool", "name": "exists", "type": "bool" }, + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalIrrevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalRevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalScoreUpdatesRequired", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "unreleasedPLPIncome", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, + { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } + ], + "name": "updateAlpha", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "updateMultipliers", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], + "name": "updateScores", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "vTokenForAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "xvsUpdated", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVault", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultPoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/PrimeLiquidityProvider.json b/multisig/simulations/opbnbtestnet/vip-021/abi/PrimeLiquidityProvider.json new file mode 100644 index 000000000..02ca8e0bf --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/PrimeLiquidityProvider.json @@ -0,0 +1,385 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "_timeBased", "type": "bool" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, + { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "balance", "type": "uint256" } + ], + "name": "InsufficientBalance", + "type": "error" + }, + { "inputs": [], "name": "InvalidArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidCaller", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "speed", "type": "uint256" }, + { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } + ], + "name": "InvalidDistributionSpeed", + "type": "error" + }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenAlreadyInitialized", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "TokenNotInitialized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "MaxTokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } + ], + "name": "PrimeTokenUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenDistributionInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "TokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokenTransferredToPrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokensAccrued", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "accrueTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "getEffectiveDistributionSpeed", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], + "name": "initializeTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "lastAccruedBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastAccruedBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "maxTokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } + ], + "name": "setMaxTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } + ], + "name": "setTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "tokenAmountAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/ProtocolShareReserve.json b/multisig/simulations/opbnbtestnet/vip-021/abi/ProtocolShareReserve.json new file mode 100644 index 000000000..b33d7c495 --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/ProtocolShareReserve.json @@ -0,0 +1,356 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, + { "internalType": "address", "name": "_wbnb", "type": "address" }, + { "internalType": "address", "name": "_vbnb", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetReleased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IProtocolShareReserve.IncomeType", + "name": "incomeType", + "type": "uint8" + }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "AssetsReservesUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } + ], + "name": "PoolRegistryUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "ReservesUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "CORE_POOL_COMPTROLLER", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MAX_PERCENT", + "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "internalType": "struct ProtocolShareReserve.DistributionConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "addOrUpdateDistributionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } + ], + "name": "assetsReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "distributionTargets", + "outputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "getPercentageDistribution", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "getUnreleasedFunds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address[]", "name": "assets", "type": "address[]" } + ], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "name": "removeDistributionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], + "name": "setPoolRegistry", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAssetReserve", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalDistributions", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/RewardDistrbutor.json b/multisig/simulations/opbnbtestnet/vip-021/abi/RewardDistrbutor.json new file mode 100644 index 000000000..249fdd111 --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/RewardDistrbutor.json @@ -0,0 +1,532 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "BorrowLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "BorrowLastRewardingBlockUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "ContributorRewardTokenSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } + ], + "name": "ContributorRewardsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } + ], + "name": "DistributedBorrowerRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } + ], + "name": "DistributedSupplierRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "MarketInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "indexed": false, + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "RewardTokenBorrowIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenBorrowSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RewardTokenGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "RewardTokenSupplyIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenSupplySpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "SupplyLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "SupplyLastRewardingBlockUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "INITIAL_INDEX", + "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "holder", "type": "address" }, + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } + ], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "distributeBorrowerRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "supplier", "type": "address" } + ], + "name": "distributeSupplierRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "grantRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, + { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "initializeMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastContributorBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "rewardToken", + "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenBorrowerIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenContributorSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenSupplierIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplySpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contributor", "type": "address" }, + { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } + ], + "name": "setContributorRewardTokenSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } + ], + "name": "setLastRewardingBlockTimestamps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, + { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } + ], + "name": "setLastRewardingBlocks", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } + ], + "name": "setRewardTokenSpeeds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], + "name": "updateContributorRewards", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "updateRewardTokenBorrowIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "updateRewardTokenSupplyIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/SingleTokenConverter.json b/multisig/simulations/opbnbtestnet/vip-021/abi/SingleTokenConverter.json new file mode 100644 index 000000000..8ea10cc8d --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/SingleTokenConverter.json @@ -0,0 +1,587 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { "inputs": [], "name": "AmountInMismatched", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, + { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, + { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, + { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, + { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, + { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, + { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, + { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, + { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, + { "inputs": [], "name": "InvalidToAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, + { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetTransferredToDestination", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } + ], + "name": "BaseAssetUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, + { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "baseAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "conversionConfigurations", + "outputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, + { "internalType": "address", "name": "destinationAddress_", "type": "address" }, + { "internalType": "address", "name": "baseAsset_", "type": "address" }, + { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], + "name": "setBaseAsset", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/SingleTokenConverterBeacon.json b/multisig/simulations/opbnbtestnet/vip-021/abi/SingleTokenConverterBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/SingleTokenConverterBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/VToken.json b/multisig/simulations/opbnbtestnet/vip-021/abi/VToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/VToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/VTokenBeacon.json b/multisig/simulations/opbnbtestnet/vip-021/abi/VTokenBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/VTokenBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/XVSStore.json b/multisig/simulations/opbnbtestnet/vip-021/abi/XVSStore.json new file mode 100644 index 000000000..2d9ea2bb2 --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/XVSStore.json @@ -0,0 +1,130 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "AdminTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } + ], + "name": "NewPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnerTransferred", + "type": "event" + }, + { + "constant": false, + "inputs": [], + "name": "acceptAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "emergencyRewardWithdraw", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokens", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "token", "type": "address" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "safeRewardTransfer", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], + "name": "setNewOwner", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], + "name": "setPendingAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "bool", "name": "status", "type": "bool" } + ], + "name": "setRewardToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/XVSVault.json b/multisig/simulations/opbnbtestnet/vip-021/abi/XVSVault.json new file mode 100644 index 000000000..51d8d540c --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/XVSVault.json @@ -0,0 +1,787 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Claim", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } + ], + "name": "DelegateChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "DelegateVotesChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Deposit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ExecutedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "name": "PoolAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } + ], + "name": "PoolUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RequestedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } + ], + "name": "RewardAmountUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } + ], + "name": "StoreUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } + ], + "name": "VaultDebtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } + ], + "name": "WithdrawalLockingPeriodUpdated", + "type": "event" + }, + { + "constant": true, + "inputs": [], + "name": "DELEGATION_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "DOMAIN_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "MAX_LOCK_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "SECONDS_PER_YEAR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], + "name": "_become", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, + { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, + { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } + ], + "name": "add", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint32", "name": "", "type": "uint32" } + ], + "name": "checkpoints", + "outputs": [ + { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, + { "internalType": "uint96", "name": "votes", "type": "uint96" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_account", "type": "address" }, + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "claim", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], + "name": "delegate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "delegatee", "type": "address" }, + { "internalType": "uint256", "name": "nonce", "type": "uint256" }, + { "internalType": "uint256", "name": "expiry", "type": "uint256" }, + { "internalType": "uint8", "name": "v", "type": "uint8" }, + { "internalType": "bytes32", "name": "r", "type": "bytes32" }, + { "internalType": "bytes32", "name": "s", "type": "bytes32" } + ], + "name": "delegateBySig", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "delegates", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "deposit", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "executeWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getCurrentVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getEligibleWithdrawalAmount", + "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } + ], + "name": "getPriorVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getRequestedAmount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getUserInfo", + "outputs": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, + { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getWithdrawalRequests", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, + { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } + ], + "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", + "name": "", + "type": "tuple[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "name": "initializeTimeManager", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isStakedToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "nonces", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "numCheckpoints", + "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "pause", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingReward", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "pendingRewardTransfers", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingWithdrawalsBeforeUpgrade", + "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingXVSVaultImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "poolInfos", + "outputs": [ + { "internalType": "contract IBEP20", "name": "token", "type": "address" }, + { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, + { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], + "name": "poolLength", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primePoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeToken", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "requestWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "resume", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], + "name": "rewardTokenAmountsPerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAmountsPerBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } + ], + "name": "set", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], + "name": "setAccessControl", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, + { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } + ], + "name": "setPrimeToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } + ], + "name": "setRewardAmountPerBlockOrSecond", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } + ], + "name": "setWithdrawalLockingPeriod", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_xvs", "type": "address" }, + { "internalType": "address", "name": "_xvsStore", "type": "address" } + ], + "name": "setXvsStore", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAllocPoints", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "totalPendingWithdrawals", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "updatePool", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "vaultPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsStore", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/boundValidator.json b/multisig/simulations/opbnbtestnet/vip-021/abi/boundValidator.json new file mode 100644 index 000000000..d16c8fb08 --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/boundValidator.json @@ -0,0 +1,498 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "previousAdmin", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAdmin", + "type": "address" + } + ], + "name": "AdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "beacon", + "type": "address" + } + ], + "name": "BeaconUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "implementation", + "type": "address" + } + ], + "name": "Upgraded", + "type": "event" + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "inputs": [], + "name": "admin", + "outputs": [ + { + "internalType": "address", + "name": "admin_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [ + { + "internalType": "address", + "name": "implementation_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + } + ], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "upgradeToAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "stateMutability": "payable", + "type": "receive" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "upperBound", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "lowerBound", + "type": "uint256" + } + ], + "name": "ValidateConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig", + "name": "config", + "type": "tuple" + } + ], + "name": "setValidateConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "setValidateConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "validateConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "reportedPrice", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "anchorPrice", + "type": "uint256" + } + ], + "name": "validatePriceWithAnchorPrice", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_logic", + "type": "address" + }, + { + "internalType": "address", + "name": "admin_", + "type": "address" + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes" + } + ], + "stateMutability": "payable", + "type": "constructor" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/chainlinkOracle.json b/multisig/simulations/opbnbtestnet/vip-021/abi/chainlinkOracle.json new file mode 100644 index 000000000..cdd689acb --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/chainlinkOracle.json @@ -0,0 +1,459 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "vBnbAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "previousPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "requestedPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newPriceMantissa", + "type": "uint256" + } + ], + "name": "PricePosted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManager", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "prices", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + } + ], + "name": "setDirectPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VBep20Interface", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "underlyingPriceMantissa", + "type": "uint256" + } + ], + "name": "setUnderlyingPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "tokenConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/resilientOracle.json b/multisig/simulations/opbnbtestnet/vip-021/abi/resilientOracle.json new file mode 100644 index 000000000..35f52caa0 --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/resilientOracle.json @@ -0,0 +1,640 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "nativeMarketAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + }, + { + "internalType": "contract BoundValidatorInterface", + "name": "_boundValidator", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "mainOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "pivotOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "fallbackOracle", + "type": "address" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [ + { + "internalType": "contract BoundValidatorInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "getOracle", + "outputs": [ + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "bool", + "name": "enabled", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/sFrxETHOracle.json b/multisig/simulations/opbnbtestnet/vip-021/abi/sFrxETHOracle.json new file mode 100644 index 000000000..b461549ba --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/sFrxETHOracle.json @@ -0,0 +1,148 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_sfrxEthFraxOracle", "type": "address" }, + { "internalType": "address", "name": "_sfrxETH", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "BadPriceData", "type": "error" }, + { "inputs": [], "name": "InvalidTokenAddress", "type": "error" }, + { "inputs": [], "name": "PriceDifferenceExceeded", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxAllowedPriceDifference", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxAllowedPriceDifference", "type": "uint256" } + ], + "name": "MaxAllowedPriceDifferenceUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "SFRXETH", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "SFRXETH_FRAX_ORACLE", + "outputs": [{ "internalType": "contract ISfrxEthFraxOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxAllowedPriceDifference", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" }], + "name": "setMaxAllowedPriceDifference", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/treasury.json b/multisig/simulations/opbnbtestnet/vip-021/abi/treasury.json new file mode 100644 index 000000000..18aabb61a --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/treasury.json @@ -0,0 +1,86 @@ +[ + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryNative", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryToken", + "type": "event" + }, + { "stateMutability": "payable", "type": "fallback" }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryNative", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "stateMutability": "payable", "type": "receive" } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/xvs.json b/multisig/simulations/opbnbtestnet/vip-021/abi/xvs.json new file mode 100644 index 000000000..69092bb4a --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/xvs.json @@ -0,0 +1,716 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "AccountBlacklisted", + "type": "error" + }, + { + "inputs": [], + "name": "AddressesMustDiffer", + "type": "error" + }, + { + "inputs": [], + "name": "MintLimitExceed", + "type": "error" + }, + { + "inputs": [], + "name": "MintedAmountExceed", + "type": "error" + }, + { + "inputs": [], + "name": "NewCapNotGreaterThanMintedTokens", + "type": "error" + }, + { + "inputs": [], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "value", + "type": "bool" + } + ], + "name": "BlacklistUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "MintCapChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitDecreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "source", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "destination", + "type": "address" + } + ], + "name": "MintedTokensMigrated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "address", + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + } + ], + "name": "isBlackListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "source_", + "type": "address" + }, + { + "internalType": "address", + "name": "destination_", + "type": "address" + } + ], + "name": "migrateMinterTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToCap", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToMintedAmount", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newAccessControlAddress_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "minter_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "setMintCap", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + }, + { + "internalType": "bool", + "name": "value_", + "type": "bool" + } + ], + "name": "updateBlacklist", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/xvsBridgeAdmin.json b/multisig/simulations/opbnbtestnet/vip-021/abi/xvsBridgeAdmin.json new file mode 100644 index 000000000..024450a40 --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/abi/xvsBridgeAdmin.json @@ -0,0 +1,329 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "XVSBridge_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "string", + "name": "signature", + "type": "string" + }, + { + "indexed": false, + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "name": "FunctionRegistryChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "stateMutability": "nonpayable", + "type": "fallback" + }, + { + "inputs": [], + "name": "XVSBridge", + "outputs": [ + { + "internalType": "contract IXVSProxyOFT", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "", + "type": "bytes4" + } + ], + "name": "functionRegistry", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "isTrustedRemote", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner_", + "type": "address" + } + ], + "name": "transferBridgeOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "string[]", + "name": "signatures_", + "type": "string[]" + }, + { + "internalType": "bool[]", + "name": "active_", + "type": "bool[]" + } + ], + "name": "upsertSignature", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbtestnet/vip-021/index.ts b/multisig/simulations/opbnbtestnet/vip-021/index.ts new file mode 100644 index 000000000..d52ebb2fe --- /dev/null +++ b/multisig/simulations/opbnbtestnet/vip-021/index.ts @@ -0,0 +1,181 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip021, { + BOUND_VALIDATOR, + COMPTROLLERS, + COMPTROLLER_BEACON, + DEFAULT_PROXY_ADMIN, + PSR, + VTOKENS, + VTOKEN_BEACON, + XVS, + XVS_BRIDGE_ADMIN_PROXY, + XVS_STORE, +} from "../../../proposals/opbnbtestnet/vip-021"; +import COMPTROLLER_ABI from "./abi/Comptroller.json"; +import COMPTROLLER_BEACON_ABI from "./abi/ComptrollerBeacon.json"; +import DEFAULT_PROXY_ADMIN_ABI from "./abi/DefaultProxyAdmin.json"; +import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; +import PSR_ABI from "./abi/ProtocolShareReserve.json"; +import VTOKEN_ABI from "./abi/VToken.json"; +import VTOKEN_BEACON_ABI from "./abi/VTokenBeacon.json"; +import XVS_STORE_ABI from "./abi/XVSStore.json"; +import XVS_VAULT_ABI from "./abi/XVSVault.json"; +import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; +import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; +import TREASURY_ABI from "./abi/treasury.json"; +import XVS_ABI from "./abi/xvs.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; + +const { opbnbtestnet } = NETWORK_ADDRESSES; + +const RESILIENT_ORACLE = opbnbtestnet.RESILIENT_ORACLE; +const NORMAL_TIMELOCK = opbnbtestnet.NORMAL_TIMELOCK; + +forking(28761242, async () => { + const provider = ethers.provider; + let proxyAdmin: Contract; + let psr: Contract; + let comptrollerBeacon: Contract; + let vTokenBeacon: Contract; + let poolRegistry: Contract; + let xvsVault: Contract; + let xvsStore: Contract; + let xvs: Contract; + let xvsBridgeAdmin: Contract; + let resilientOracle: Contract; + let boundValidator: Contract; + let treasury: Contract; + + describe("Pre-VIP behavior", async () => { + before(async () => { + proxyAdmin = new ethers.Contract(DEFAULT_PROXY_ADMIN, DEFAULT_PROXY_ADMIN_ABI, provider); + psr = new ethers.Contract(PSR, PSR_ABI, provider); + comptrollerBeacon = new ethers.Contract(COMPTROLLER_BEACON, COMPTROLLER_BEACON_ABI, provider); + vTokenBeacon = new ethers.Contract(VTOKEN_BEACON, VTOKEN_BEACON_ABI, provider); + poolRegistry = new ethers.Contract(opbnbtestnet.POOL_REGISTRY, POOL_REGISTRY_ABI, provider); + xvsVault = new ethers.Contract(opbnbtestnet.XVS_VAULT_PROXY, XVS_VAULT_ABI, provider); + xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); + xvs = await ethers.getContractAt(XVS_ABI, XVS); + xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, XVS_BRIDGE_ADMIN_PROXY); + resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); + boundValidator = new ethers.Contract(BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); + treasury = await ethers.getContractAt(TREASURY_ABI, NETWORK_ADDRESSES.opbnbtestnet.VTREASURY); + }); + + it("owner of proxy admin is guardian", async () => { + expect(await proxyAdmin.owner()).to.equal(opbnbtestnet.GUARDIAN); + }); + + it("pending owner of psr", async () => { + expect(await psr.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`should have no pending owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`should have no pending owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + it("owner of ComptrollerBeacon is guardian", async () => { + expect(await comptrollerBeacon.owner()).to.equal(opbnbtestnet.GUARDIAN); + }); + + it("owner of VTokenBeacon is guardian", async () => { + expect(await vTokenBeacon.owner()).to.equal(opbnbtestnet.GUARDIAN); + }); + + it("pending owner of PoolRegistry", async () => { + expect(await poolRegistry.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + it("should have no pending owner", async () => { + expect(await xvsVault.pendingAdmin()).to.equal(ethers.constants.AddressZero); + }); + + it("should have no pending owner", async () => { + expect(await xvsStore.pendingAdmin()).to.equal(ethers.constants.AddressZero); + }); + + it("should have no pending owner", async () => { + expect(await resilientOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await boundValidator.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + }); + + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip021()); + }); + + it("owner of proxy admin is timelock", async () => { + expect(await proxyAdmin.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + }); + + it("pending owner of psr", async () => { + expect(await psr.pendingOwner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`correct pending owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.pendingOwner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`correct pending owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.pendingOwner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + }); + } + + it("owner of ComptrollerBeacon is NT", async () => { + expect(await comptrollerBeacon.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + }); + + it("owner of VTokenBeacon is NT", async () => { + expect(await vTokenBeacon.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + }); + + it("pending owner of PoolRegistry is NT", async () => { + expect(await poolRegistry.pendingOwner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + }); + + it("correct pending owner", async () => { + expect(await xvsVault.pendingAdmin()).to.equal(NORMAL_TIMELOCK); + }); + + it("correct pending owner", async () => { + expect(await xvsStore.pendingAdmin()).to.equal(NORMAL_TIMELOCK); + }); + + it("Should set bridge pending owner to Normal Timelock", async () => { + const pendingOwner = await xvsBridgeAdmin.pendingOwner(); + expect(pendingOwner).equals(opbnbtestnet.NORMAL_TIMELOCK); + }); + it("Should set XVS owner to Normal Timelock", async () => { + const owner = await xvs.owner(); + expect(owner).equals(opbnbtestnet.NORMAL_TIMELOCK); + }); + it("correct pending owner", async () => { + expect(await resilientOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); + expect(await boundValidator.pendingOwner()).to.equal(NORMAL_TIMELOCK); + }); + it("Should set pendingOwner to Normal Timelock", async () => { + const pendingOwner = await treasury.pendingOwner(); + expect(pendingOwner).equals(NETWORK_ADDRESSES.opbnbtestnet.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/multisig/simulations/sepolia/vip-060/abi/Comptroller.json b/multisig/simulations/sepolia/vip-060/abi/Comptroller.json new file mode 100644 index 000000000..f3b2445ac --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/Comptroller.json @@ -0,0 +1,929 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, + { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, + { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, + { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, + { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, + { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "TooMuchRepay", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "expectedSender", "type": "address" }, + { "internalType": "address", "name": "actualSender", "type": "address" } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, + { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "accountAssets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "actionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allMarkets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "approvedDelegates", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "borrowCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "contract VToken", "name": "vToken", "type": "address" } + ], + "name": "checkMembership", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], + "name": "enterMarkets", + "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], + "name": "exitMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAssetsIn", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getBorrowingPower", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "vTokenModify", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isForcedLiquidationEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "isMarketListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [ + { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "bool", "name": "isListed", "type": "bool" }, + { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "seizerContract", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, + { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, + { "internalType": "bool", "name": "paused", "type": "bool" } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "supplyCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "delegate", "type": "address" }, + { "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/ComptrollerBeacon.json b/multisig/simulations/sepolia/vip-060/abi/ComptrollerBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/ComptrollerBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/ConverterNetwork.json b/multisig/simulations/sepolia/vip-060/abi/ConverterNetwork.json new file mode 100644 index 000000000..396f12a91 --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/ConverterNetwork.json @@ -0,0 +1,205 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { "inputs": [], "name": "ConverterAlreadyExists", "type": "error" }, + { "inputs": [], "name": "ConverterDoesNotExist", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "InvalidMaxLoopsLimit", + "type": "error" + }, + { "inputs": [], "name": "InvalidTokenConverterAddress", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], + "name": "ConverterAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], + "name": "ConverterRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], + "name": "addTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allConverters", + "outputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } + ], + "name": "findTokenConverters", + "outputs": [ + { "internalType": "address[]", "name": "converters", "type": "address[]" }, + { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } + ], + "name": "findTokenConvertersForConverters", + "outputs": [ + { "internalType": "address[]", "name": "converters", "type": "address[]" }, + { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getAllConverters", + "outputs": [{ "internalType": "contract IAbstractTokenConverter[]", "name": "converters", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_tokenConverter", "type": "address" }], + "name": "isTokenConverter", + "outputs": [{ "internalType": "bool", "name": "isConverter", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], + "name": "removeTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/DefaultProxyAdmin.json b/multisig/simulations/sepolia/vip-060/abi/DefaultProxyAdmin.json new file mode 100644 index 000000000..9801cfcc7 --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/DefaultProxyAdmin.json @@ -0,0 +1,76 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "changeProxyAdmin", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" } + ], + "name": "upgrade", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" }, + { "internalType": "bytes", "name": "data", "type": "bytes" } + ], + "name": "upgradeAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/PoolRegistry.json b/multisig/simulations/sepolia/vip-060/abi/PoolRegistry.json new file mode 100644 index 000000000..31b1e2a17 --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/PoolRegistry.json @@ -0,0 +1,379 @@ +[ + { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, + { + "name": "Unauthorized", + "type": "error", + "inputs": [ + { "name": "sender", "type": "address", "internalType": "address" }, + { "name": "calledContract", "type": "address", "internalType": "address" }, + { "name": "methodSignature", "type": "string", "internalType": "string" } + ] + }, + { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, + { + "name": "Initialized", + "type": "event", + "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], + "anonymous": false, + "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" + }, + { + "name": "MarketAdded", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" + }, + { + "name": "NewAccessControlManager", + "type": "event", + "inputs": [ + { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, + { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" + }, + { + "name": "OwnershipTransferStarted", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" + }, + { + "name": "OwnershipTransferred", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" + }, + { + "name": "PoolMetadataUpdated", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "oldMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + }, + { + "name": "newMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "anonymous": false, + "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" + }, + { + "name": "PoolNameSet", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, + { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } + ], + "anonymous": false, + "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" + }, + { + "name": "PoolRegistered", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "pool", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "anonymous": false, + "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" + }, + { + "name": "acceptOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x79ba5097", + "stateMutability": "nonpayable" + }, + { + "name": "accessControlManager", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "contract IAccessControlManagerV8" + } + ], + "constant": true, + "signature": "0xb4a0bdf3", + "stateMutability": "view" + }, + { + "name": "addMarket", + "type": "function", + "inputs": [ + { + "name": "input", + "type": "tuple", + "components": [ + { "name": "vToken", "type": "address", "internalType": "contract VToken" }, + { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, + { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, + { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, + { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, + { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistry.AddMarketInput" + } + ], + "outputs": [], + "signature": "0x23dc8d64", + "stateMutability": "nonpayable" + }, + { + "name": "addPool", + "type": "function", + "inputs": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, + { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, + { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } + ], + "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], + "signature": "0xeed873c2", + "stateMutability": "nonpayable" + }, + { + "name": "getAllPools", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "tuple[]", + "value": [], + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool[]" + } + ], + "constant": true, + "signature": "0xd88ff1f4", + "stateMutability": "view" + }, + { + "name": "getPoolByComptroller", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "constant": true, + "signature": "0x7aee632d", + "stateMutability": "view" + }, + { + "name": "getPoolsSupportedByAsset", + "type": "function", + "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], + "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], + "constant": true, + "signature": "0xf36dba38", + "stateMutability": "view" + }, + { + "name": "getVTokenForAsset", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "asset", "type": "address", "internalType": "address" } + ], + "outputs": [{ "name": "", "type": "address", "internalType": "address" }], + "constant": true, + "signature": "0x266e0a7f", + "stateMutability": "view" + }, + { + "name": "getVenusPoolMetadata", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "constant": true, + "signature": "0xa3aefa2c", + "stateMutability": "view" + }, + { + "name": "initialize", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xc4d66de8", + "stateMutability": "nonpayable" + }, + { + "name": "metadata", + "type": "function", + "inputs": [{ "name": "", "type": "address", "internalType": "address" }], + "outputs": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "constant": true, + "signature": "0x2ba21572", + "stateMutability": "view" + }, + { + "name": "owner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x8da5cb5b", + "stateMutability": "view" + }, + { + "name": "pendingOwner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0xe30c3978", + "stateMutability": "view" + }, + { + "name": "renounceOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x715018a6", + "stateMutability": "nonpayable" + }, + { + "name": "setAccessControlManager", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0x0e32cb86", + "stateMutability": "nonpayable" + }, + { + "name": "setPoolName", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "name", "type": "string", "internalType": "string" } + ], + "outputs": [], + "signature": "0x1cb6bb7e", + "stateMutability": "nonpayable" + }, + { + "name": "transferOwnership", + "type": "function", + "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xf2fde38b", + "stateMutability": "nonpayable" + }, + { + "name": "updatePoolMetadata", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { + "name": "metadata_", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "outputs": [], + "signature": "0xff94d958", + "stateMutability": "nonpayable" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/Prime.json b/multisig/simulations/sepolia/vip-060/abi/Prime.json new file mode 100644 index 000000000..e8bfa99ff --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/Prime.json @@ -0,0 +1,763 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, + { "internalType": "address", "name": "_nativeMarket", "type": "address" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, + { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, + { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, + { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, + { "internalType": "bool", "name": "_timeBased", "type": "bool" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, + { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidComptroller", "type": "error" }, + { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "n", "type": "uint256" }, + { "internalType": "uint256", "name": "d", "type": "uint256" } + ], + "name": "InvalidFraction", + "type": "error" + }, + { "inputs": [], "name": "InvalidLength", "type": "error" }, + { "inputs": [], "name": "InvalidLimit", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, + { "inputs": [], "name": "InvalidVToken", "type": "error" }, + { + "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], + "name": "LnNonRealResult", + "type": "error" + }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, + { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, + { "inputs": [], "name": "MarketNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, + { "inputs": [], "name": "WaitMoreTime", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, + { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } + ], + "name": "AlphaUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "Burn", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "InterestClaimed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } + ], + "name": "MintLimitsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } + ], + "name": "MultiplierUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } + ], + "name": "StakedAtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "TokenUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "UserScoreUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "MAXIMUM_XVS_CAP", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MINIMUM_STAKED_XVS", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_MARKET", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "STAKING_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WRAPPED_NATIVE_TOKEN", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "accrueInterest", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" } + ], + "name": "accrueInterestAndUpdateScore", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "alphaDenominator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "alphaNumerator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "calculateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "claimTimeRemaining", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "uint256", "name": "borrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supply", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } + ], + "name": "estimateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "getInterestAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "getPendingRewards", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "internalType": "struct PrimeStorageV1.PendingReward[]", + "name": "pendingRewards", + "type": "tuple[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "incomeDistributionYearly", + "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "xvsVault_", "type": "address" }, + { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, + { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, + { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, + { "internalType": "address", "name": "comptroller_", "type": "address" }, + { "internalType": "address", "name": "oracle_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "name": "initializeV2", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "interests", + "outputs": [ + { "internalType": "uint256", "name": "accrued", "type": "uint256" }, + { "internalType": "uint256", "name": "score", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "irrevocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "isScoreUpdated", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "isUserPrimeHolder", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, + { "internalType": "address[]", "name": "users", "type": "address[]" } + ], + "name": "issue", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, + { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, + { "internalType": "bool", "name": "exists", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "nextScoreUpdateRoundId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingScoreUpdates", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "primeLiquidityProvider", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "revocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } + ], + "name": "setLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "users", "type": "address[]" }, + { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } + ], + "name": "setStakedAt", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "stakedAt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokens", + "outputs": [ + { "internalType": "bool", "name": "exists", "type": "bool" }, + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalIrrevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalRevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalScoreUpdatesRequired", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "unreleasedPLPIncome", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, + { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } + ], + "name": "updateAlpha", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "updateMultipliers", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], + "name": "updateScores", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "vTokenForAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "xvsUpdated", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVault", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultPoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/PrimeLiquidityProvider.json b/multisig/simulations/sepolia/vip-060/abi/PrimeLiquidityProvider.json new file mode 100644 index 000000000..02ca8e0bf --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/PrimeLiquidityProvider.json @@ -0,0 +1,385 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "_timeBased", "type": "bool" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, + { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "balance", "type": "uint256" } + ], + "name": "InsufficientBalance", + "type": "error" + }, + { "inputs": [], "name": "InvalidArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidCaller", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "speed", "type": "uint256" }, + { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } + ], + "name": "InvalidDistributionSpeed", + "type": "error" + }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenAlreadyInitialized", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "TokenNotInitialized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "MaxTokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } + ], + "name": "PrimeTokenUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenDistributionInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "TokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokenTransferredToPrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokensAccrued", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "accrueTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "getEffectiveDistributionSpeed", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], + "name": "initializeTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "lastAccruedBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastAccruedBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "maxTokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } + ], + "name": "setMaxTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } + ], + "name": "setTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "tokenAmountAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/ProtocolShareReserve.json b/multisig/simulations/sepolia/vip-060/abi/ProtocolShareReserve.json new file mode 100644 index 000000000..b33d7c495 --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/ProtocolShareReserve.json @@ -0,0 +1,356 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, + { "internalType": "address", "name": "_wbnb", "type": "address" }, + { "internalType": "address", "name": "_vbnb", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetReleased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IProtocolShareReserve.IncomeType", + "name": "incomeType", + "type": "uint8" + }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "AssetsReservesUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } + ], + "name": "PoolRegistryUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "ReservesUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "CORE_POOL_COMPTROLLER", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MAX_PERCENT", + "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "internalType": "struct ProtocolShareReserve.DistributionConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "addOrUpdateDistributionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } + ], + "name": "assetsReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "distributionTargets", + "outputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "getPercentageDistribution", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "getUnreleasedFunds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address[]", "name": "assets", "type": "address[]" } + ], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "name": "removeDistributionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], + "name": "setPoolRegistry", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAssetReserve", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalDistributions", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/RewardDistrbutor.json b/multisig/simulations/sepolia/vip-060/abi/RewardDistrbutor.json new file mode 100644 index 000000000..249fdd111 --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/RewardDistrbutor.json @@ -0,0 +1,532 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "BorrowLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "BorrowLastRewardingBlockUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "ContributorRewardTokenSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } + ], + "name": "ContributorRewardsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } + ], + "name": "DistributedBorrowerRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } + ], + "name": "DistributedSupplierRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "MarketInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "indexed": false, + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "RewardTokenBorrowIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenBorrowSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RewardTokenGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "RewardTokenSupplyIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenSupplySpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "SupplyLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "SupplyLastRewardingBlockUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "INITIAL_INDEX", + "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "holder", "type": "address" }, + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } + ], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "distributeBorrowerRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "supplier", "type": "address" } + ], + "name": "distributeSupplierRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "grantRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, + { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "initializeMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastContributorBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "rewardToken", + "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenBorrowerIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenContributorSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenSupplierIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplySpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contributor", "type": "address" }, + { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } + ], + "name": "setContributorRewardTokenSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } + ], + "name": "setLastRewardingBlockTimestamps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, + { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } + ], + "name": "setLastRewardingBlocks", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } + ], + "name": "setRewardTokenSpeeds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], + "name": "updateContributorRewards", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "updateRewardTokenBorrowIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "updateRewardTokenSupplyIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/SingleTokenConverter.json b/multisig/simulations/sepolia/vip-060/abi/SingleTokenConverter.json new file mode 100644 index 000000000..8ea10cc8d --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/SingleTokenConverter.json @@ -0,0 +1,587 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { "inputs": [], "name": "AmountInMismatched", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, + { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, + { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, + { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, + { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, + { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, + { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, + { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, + { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, + { "inputs": [], "name": "InvalidToAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, + { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetTransferredToDestination", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } + ], + "name": "BaseAssetUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, + { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "baseAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "conversionConfigurations", + "outputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, + { "internalType": "address", "name": "destinationAddress_", "type": "address" }, + { "internalType": "address", "name": "baseAsset_", "type": "address" }, + { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], + "name": "setBaseAsset", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/SingleTokenConverterBeacon.json b/multisig/simulations/sepolia/vip-060/abi/SingleTokenConverterBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/SingleTokenConverterBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/VToken.json b/multisig/simulations/sepolia/vip-060/abi/VToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/VToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/VTokenBeacon.json b/multisig/simulations/sepolia/vip-060/abi/VTokenBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/VTokenBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/XVSStore.json b/multisig/simulations/sepolia/vip-060/abi/XVSStore.json new file mode 100644 index 000000000..2d9ea2bb2 --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/XVSStore.json @@ -0,0 +1,130 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "AdminTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } + ], + "name": "NewPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnerTransferred", + "type": "event" + }, + { + "constant": false, + "inputs": [], + "name": "acceptAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "emergencyRewardWithdraw", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokens", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "token", "type": "address" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "safeRewardTransfer", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], + "name": "setNewOwner", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], + "name": "setPendingAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "bool", "name": "status", "type": "bool" } + ], + "name": "setRewardToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/XVSVault.json b/multisig/simulations/sepolia/vip-060/abi/XVSVault.json new file mode 100644 index 000000000..51d8d540c --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/XVSVault.json @@ -0,0 +1,787 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Claim", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } + ], + "name": "DelegateChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "DelegateVotesChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Deposit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ExecutedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "name": "PoolAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } + ], + "name": "PoolUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RequestedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } + ], + "name": "RewardAmountUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } + ], + "name": "StoreUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } + ], + "name": "VaultDebtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } + ], + "name": "WithdrawalLockingPeriodUpdated", + "type": "event" + }, + { + "constant": true, + "inputs": [], + "name": "DELEGATION_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "DOMAIN_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "MAX_LOCK_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "SECONDS_PER_YEAR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], + "name": "_become", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, + { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, + { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } + ], + "name": "add", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint32", "name": "", "type": "uint32" } + ], + "name": "checkpoints", + "outputs": [ + { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, + { "internalType": "uint96", "name": "votes", "type": "uint96" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_account", "type": "address" }, + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "claim", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], + "name": "delegate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "delegatee", "type": "address" }, + { "internalType": "uint256", "name": "nonce", "type": "uint256" }, + { "internalType": "uint256", "name": "expiry", "type": "uint256" }, + { "internalType": "uint8", "name": "v", "type": "uint8" }, + { "internalType": "bytes32", "name": "r", "type": "bytes32" }, + { "internalType": "bytes32", "name": "s", "type": "bytes32" } + ], + "name": "delegateBySig", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "delegates", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "deposit", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "executeWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getCurrentVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getEligibleWithdrawalAmount", + "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } + ], + "name": "getPriorVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getRequestedAmount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getUserInfo", + "outputs": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, + { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getWithdrawalRequests", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, + { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } + ], + "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", + "name": "", + "type": "tuple[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "name": "initializeTimeManager", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isStakedToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "nonces", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "numCheckpoints", + "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "pause", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingReward", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "pendingRewardTransfers", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingWithdrawalsBeforeUpgrade", + "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingXVSVaultImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "poolInfos", + "outputs": [ + { "internalType": "contract IBEP20", "name": "token", "type": "address" }, + { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, + { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], + "name": "poolLength", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primePoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeToken", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "requestWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "resume", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], + "name": "rewardTokenAmountsPerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAmountsPerBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } + ], + "name": "set", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], + "name": "setAccessControl", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, + { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } + ], + "name": "setPrimeToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } + ], + "name": "setRewardAmountPerBlockOrSecond", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } + ], + "name": "setWithdrawalLockingPeriod", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_xvs", "type": "address" }, + { "internalType": "address", "name": "_xvsStore", "type": "address" } + ], + "name": "setXvsStore", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAllocPoints", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "totalPendingWithdrawals", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "updatePool", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "vaultPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsStore", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/boundValidator.json b/multisig/simulations/sepolia/vip-060/abi/boundValidator.json new file mode 100644 index 000000000..d16c8fb08 --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/boundValidator.json @@ -0,0 +1,498 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "previousAdmin", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAdmin", + "type": "address" + } + ], + "name": "AdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "beacon", + "type": "address" + } + ], + "name": "BeaconUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "implementation", + "type": "address" + } + ], + "name": "Upgraded", + "type": "event" + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "inputs": [], + "name": "admin", + "outputs": [ + { + "internalType": "address", + "name": "admin_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [ + { + "internalType": "address", + "name": "implementation_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + } + ], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "upgradeToAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "stateMutability": "payable", + "type": "receive" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "upperBound", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "lowerBound", + "type": "uint256" + } + ], + "name": "ValidateConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig", + "name": "config", + "type": "tuple" + } + ], + "name": "setValidateConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "setValidateConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "validateConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "reportedPrice", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "anchorPrice", + "type": "uint256" + } + ], + "name": "validatePriceWithAnchorPrice", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_logic", + "type": "address" + }, + { + "internalType": "address", + "name": "admin_", + "type": "address" + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes" + } + ], + "stateMutability": "payable", + "type": "constructor" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/chainlinkOracle.json b/multisig/simulations/sepolia/vip-060/abi/chainlinkOracle.json new file mode 100644 index 000000000..cdd689acb --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/chainlinkOracle.json @@ -0,0 +1,459 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "vBnbAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "previousPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "requestedPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newPriceMantissa", + "type": "uint256" + } + ], + "name": "PricePosted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManager", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "prices", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + } + ], + "name": "setDirectPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VBep20Interface", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "underlyingPriceMantissa", + "type": "uint256" + } + ], + "name": "setUnderlyingPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "tokenConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/resilientOracle.json b/multisig/simulations/sepolia/vip-060/abi/resilientOracle.json new file mode 100644 index 000000000..35f52caa0 --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/resilientOracle.json @@ -0,0 +1,640 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "nativeMarketAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + }, + { + "internalType": "contract BoundValidatorInterface", + "name": "_boundValidator", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "mainOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "pivotOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "fallbackOracle", + "type": "address" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [ + { + "internalType": "contract BoundValidatorInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "getOracle", + "outputs": [ + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "bool", + "name": "enabled", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/sFrxETHOracle.json b/multisig/simulations/sepolia/vip-060/abi/sFrxETHOracle.json new file mode 100644 index 000000000..b461549ba --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/sFrxETHOracle.json @@ -0,0 +1,148 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_sfrxEthFraxOracle", "type": "address" }, + { "internalType": "address", "name": "_sfrxETH", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "BadPriceData", "type": "error" }, + { "inputs": [], "name": "InvalidTokenAddress", "type": "error" }, + { "inputs": [], "name": "PriceDifferenceExceeded", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxAllowedPriceDifference", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxAllowedPriceDifference", "type": "uint256" } + ], + "name": "MaxAllowedPriceDifferenceUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "SFRXETH", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "SFRXETH_FRAX_ORACLE", + "outputs": [{ "internalType": "contract ISfrxEthFraxOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxAllowedPriceDifference", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" }], + "name": "setMaxAllowedPriceDifference", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/treasury.json b/multisig/simulations/sepolia/vip-060/abi/treasury.json new file mode 100644 index 000000000..18aabb61a --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/treasury.json @@ -0,0 +1,86 @@ +[ + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryNative", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryToken", + "type": "event" + }, + { "stateMutability": "payable", "type": "fallback" }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryNative", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "stateMutability": "payable", "type": "receive" } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/xvs.json b/multisig/simulations/sepolia/vip-060/abi/xvs.json new file mode 100644 index 000000000..69092bb4a --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/xvs.json @@ -0,0 +1,716 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "AccountBlacklisted", + "type": "error" + }, + { + "inputs": [], + "name": "AddressesMustDiffer", + "type": "error" + }, + { + "inputs": [], + "name": "MintLimitExceed", + "type": "error" + }, + { + "inputs": [], + "name": "MintedAmountExceed", + "type": "error" + }, + { + "inputs": [], + "name": "NewCapNotGreaterThanMintedTokens", + "type": "error" + }, + { + "inputs": [], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "value", + "type": "bool" + } + ], + "name": "BlacklistUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "MintCapChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitDecreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "source", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "destination", + "type": "address" + } + ], + "name": "MintedTokensMigrated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "address", + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + } + ], + "name": "isBlackListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "source_", + "type": "address" + }, + { + "internalType": "address", + "name": "destination_", + "type": "address" + } + ], + "name": "migrateMinterTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToCap", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToMintedAmount", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newAccessControlAddress_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "minter_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "setMintCap", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + }, + { + "internalType": "bool", + "name": "value_", + "type": "bool" + } + ], + "name": "updateBlacklist", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/abi/xvsBridgeAdmin.json b/multisig/simulations/sepolia/vip-060/abi/xvsBridgeAdmin.json new file mode 100644 index 000000000..024450a40 --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/abi/xvsBridgeAdmin.json @@ -0,0 +1,329 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "XVSBridge_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "string", + "name": "signature", + "type": "string" + }, + { + "indexed": false, + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "name": "FunctionRegistryChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "stateMutability": "nonpayable", + "type": "fallback" + }, + { + "inputs": [], + "name": "XVSBridge", + "outputs": [ + { + "internalType": "contract IXVSProxyOFT", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "", + "type": "bytes4" + } + ], + "name": "functionRegistry", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "isTrustedRemote", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner_", + "type": "address" + } + ], + "name": "transferBridgeOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "string[]", + "name": "signatures_", + "type": "string[]" + }, + { + "internalType": "bool[]", + "name": "active_", + "type": "bool[]" + } + ], + "name": "upsertSignature", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-060/index.ts b/multisig/simulations/sepolia/vip-060/index.ts new file mode 100644 index 000000000..50cc312d6 --- /dev/null +++ b/multisig/simulations/sepolia/vip-060/index.ts @@ -0,0 +1,270 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip060, { + BOUND_VALIDATOR, + COMPTROLLERS, + COMPTROLLER_BEACON, + CONVERTERS, + CONVERTER_NETWORK, + DEFAULT_PROXY_ADMIN, + PLP, + PRIME, + PSR, + REWARD_DISTRIBUTORS, + SFrxETHOracle, + SINGLE_TOKEN_CONVERTER_BEACON, + VTOKENS, + VTOKEN_BEACON, + XVS, + XVS_BRIDGE_ADMIN_PROXY, + XVS_STORE, +} from "../../../proposals/sepolia/vip-060"; +import COMPTROLLER_ABI from "./abi/Comptroller.json"; +import COMPTROLLER_BEACON_ABI from "./abi/ComptrollerBeacon.json"; +import CONVERTER_NETWORK_ABI from "./abi/ConverterNetwork.json"; +import DEFAULT_PROXY_ADMIN_ABI from "./abi/DefaultProxyAdmin.json"; +import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; +import PRIME_ABI from "./abi/Prime.json"; +import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; +import PSR_ABI from "./abi/ProtocolShareReserve.json"; +import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistrbutor.json"; +import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; +import SINGLE_TOKEN_CONVERTER_BEACON_ABI from "./abi/SingleTokenConverterBeacon.json"; +import VTOKEN_ABI from "./abi/VToken.json"; +import VTOKEN_BEACON_ABI from "./abi/VTokenBeacon.json"; +import XVS_STORE_ABI from "./abi/XVSStore.json"; +import XVS_VAULT_ABI from "./abi/XVSVault.json"; +import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; +import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; +import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; +import SFRAXETH_ORACLE_ABI from "./abi/sFrxETHOracle.json"; +import XVS_ABI from "./abi/xvs.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; + +const { sepolia } = NETWORK_ADDRESSES; + +const RESILIENT_ORACLE = sepolia.RESILIENT_ORACLE; +const CHAINLINK_ORACLE = sepolia.CHAINLINK_ORACLE; +const REDSTONE_ORACLE = sepolia.REDSTONE_ORACLE; +const NORMAL_TIMELOCK = sepolia.NORMAL_TIMELOCK; + +forking(6466682, async () => { + const provider = ethers.provider; + let proxyAdmin: Contract; + let prime: Contract; + let plp: Contract; + let psr: Contract; + let comptrollerBeacon: Contract; + let vTokenBeacon: Contract; + let poolRegistry: Contract; + let xvsVault: Contract; + let xvsStore: Contract; + let xvs: Contract; + let xvsBridgeAdmin: Contract; + let resilientOracle: Contract; + let chainLinkOracle: Contract; + let redstoneOracle: Contract; + let boundValidator: Contract; + let sfrxETHOracle: Contract; + + describe("Pre-VIP behavior", async () => { + before(async () => { + proxyAdmin = new ethers.Contract(DEFAULT_PROXY_ADMIN, DEFAULT_PROXY_ADMIN_ABI, provider); + prime = new ethers.Contract(PRIME, PRIME_ABI, provider); + plp = new ethers.Contract(PLP, PLP_ABI, provider); + psr = new ethers.Contract(PSR, PSR_ABI, provider); + comptrollerBeacon = new ethers.Contract(COMPTROLLER_BEACON, COMPTROLLER_BEACON_ABI, provider); + vTokenBeacon = new ethers.Contract(VTOKEN_BEACON, VTOKEN_BEACON_ABI, provider); + poolRegistry = new ethers.Contract(sepolia.POOL_REGISTRY, POOL_REGISTRY_ABI, provider); + xvsVault = new ethers.Contract(sepolia.XVS_VAULT_PROXY, XVS_VAULT_ABI, provider); + xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); + xvs = await ethers.getContractAt(XVS_ABI, XVS); + xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, XVS_BRIDGE_ADMIN_PROXY); + resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); + chainLinkOracle = new ethers.Contract(CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); + redstoneOracle = new ethers.Contract(REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); + boundValidator = new ethers.Contract(BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); + sfrxETHOracle = new ethers.Contract(SFrxETHOracle, SFRAXETH_ORACLE_ABI, provider); + }); + + it("owner of proxy admin is guardian", async () => { + expect(await proxyAdmin.owner()).to.equal(sepolia.GUARDIAN); + }); + it("pending owner", async () => { + expect(await prime.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await plp.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + + for (const rewardDistributor of REWARD_DISTRIBUTORS) { + it(`should have no pending owner for ${rewardDistributor}`, async () => { + const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + it("pending owner of psr", async () => { + expect(await psr.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`should have no pending owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`should have no pending owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + it("owner of ComptrollerBeacon is guardian", async () => { + expect(await comptrollerBeacon.owner()).to.equal(sepolia.GUARDIAN); + }); + + it("owner of VTokenBeacon is guardian", async () => { + expect(await vTokenBeacon.owner()).to.equal(sepolia.GUARDIAN); + }); + + it("pending owner of PoolRegistry", async () => { + expect(await poolRegistry.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + it("should have no pending owner", async () => { + expect(await xvsVault.pendingAdmin()).to.equal(ethers.constants.AddressZero); + }); + + it("should have no pending owner", async () => { + expect(await xvsStore.pendingAdmin()).to.equal(ethers.constants.AddressZero); + }); + + it("should have no pending owner", async () => { + expect(await resilientOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await chainLinkOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await redstoneOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); + expect(await boundValidator.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + + for (const converter of CONVERTERS) { + it(`should have no pending owner for ${converter}`, async () => { + const c = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + } + + it(`should have no pending owner for converter network`, async () => { + const c = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); + expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + + it(`should have guardian as owner for converer beacon`, async () => { + const c = new ethers.Contract(SINGLE_TOKEN_CONVERTER_BEACON, SINGLE_TOKEN_CONVERTER_BEACON_ABI, provider); + expect(await c.owner()).to.equal(sepolia.GUARDIAN); + }); + + it("should have no pending owner", async () => { + expect(await sfrxETHOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); + }); + }); + + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip060()); + }); + + it("owner of proxy admin is timelock", async () => { + expect(await proxyAdmin.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + + it("pending owner", async () => { + expect(await prime.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); + expect(await plp.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + + for (const rewardDistributor of REWARD_DISTRIBUTORS) { + it(`should have Normal Timelock as pending owner for ${rewardDistributor}`, async () => { + const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); + expect(await c.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + } + + it("pending owner of psr", async () => { + expect(await psr.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`correct pending owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`correct pending owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + } + + it("owner of ComptrollerBeacon is NT", async () => { + expect(await comptrollerBeacon.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + + it("owner of VTokenBeacon is NT", async () => { + expect(await vTokenBeacon.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + + it("pending owner of PoolRegistry is NT", async () => { + expect(await poolRegistry.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + + it("correct pending owner", async () => { + expect(await xvsVault.pendingAdmin()).to.equal(NORMAL_TIMELOCK); + }); + + it("correct pending owner", async () => { + expect(await xvsStore.pendingAdmin()).to.equal(NORMAL_TIMELOCK); + }); + + it("Should set bridge pending owner to Normal Timelock", async () => { + const pendingOwner = await xvsBridgeAdmin.pendingOwner(); + expect(pendingOwner).equals(sepolia.NORMAL_TIMELOCK); + }); + it("Should set XVS owner to Normal Timelock", async () => { + const owner = await xvs.owner(); + expect(owner).equals(sepolia.NORMAL_TIMELOCK); + }); + it("correct pending owner", async () => { + expect(await resilientOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); + expect(await chainLinkOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); + expect(await redstoneOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); + expect(await boundValidator.pendingOwner()).to.equal(NORMAL_TIMELOCK); + }); + + for (const converter of CONVERTERS) { + it(`should have no pending owner for ${converter}`, async () => { + const c = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); + expect(await c.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + } + + it(`should have no pending owner for converter network`, async () => { + const c = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); + expect(await c.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + + it(`should have NT as owner for converer beacon`, async () => { + const c = new ethers.Contract(SINGLE_TOKEN_CONVERTER_BEACON, SINGLE_TOKEN_CONVERTER_BEACON_ABI, provider); + expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + + it("correct pending owner", async () => { + expect(await sfrxETHOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); + }); + }); +}); From 562dad47ec672c9896b4be7f4dd9a35f693668da Mon Sep 17 00:00:00 2001 From: Narayan Prusty Date: Wed, 25 Sep 2024 00:20:50 +0400 Subject: [PATCH 005/178] fix: added bscmainnet and bsctestnet simulations --- .../vip-371/abi/OmnichainProposalSender.json | 314 ++++++++++++++++++ simulations/vip-371/bscmainnet.ts | 17 + simulations/vip-371/bsctestnet.ts | 17 + .../vip-372/abi/OmnichainProposalSender.json | 314 ++++++++++++++++++ simulations/vip-372/bscmainnet.ts | 17 + simulations/vip-372/bsctestnet.ts | 17 + vips/vip-371/bscmainnet.ts | 205 ++++++++++++ vips/vip-371/bsctestnet.ts | 202 +++++++++++ vips/vip-372/bscmainnet.ts | 198 +++++++++++ vips/vip-372/bsctestnet.ts | 186 +++++++++++ 10 files changed, 1487 insertions(+) create mode 100644 simulations/vip-371/abi/OmnichainProposalSender.json create mode 100644 simulations/vip-371/bscmainnet.ts create mode 100644 simulations/vip-371/bsctestnet.ts create mode 100644 simulations/vip-372/abi/OmnichainProposalSender.json create mode 100644 simulations/vip-372/bscmainnet.ts create mode 100644 simulations/vip-372/bsctestnet.ts create mode 100644 vips/vip-371/bscmainnet.ts create mode 100644 vips/vip-371/bsctestnet.ts create mode 100644 vips/vip-372/bscmainnet.ts create mode 100644 vips/vip-372/bsctestnet.ts diff --git a/simulations/vip-371/abi/OmnichainProposalSender.json b/simulations/vip-371/abi/OmnichainProposalSender.json new file mode 100644 index 000000000..66fd4df02 --- /dev/null +++ b/simulations/vip-371/abi/OmnichainProposalSender.json @@ -0,0 +1,314 @@ +[ + { + "inputs": [ + { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } + ], + "name": "ClearPayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } + ], + "name": "ExecuteRemoteProposal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "FallbackWithdraw", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } + ], + "name": "StorePayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], + "name": "TrustedRemoteRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "LZ_ENDPOINT", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourCommandsSent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLastProposalSentTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bool", "name": "useZro_", "type": "bool" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } + ], + "name": "estimateFees", + "outputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } + ], + "name": "execute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "fallbackWithdraw", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "proposalCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], + "name": "removeTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "retryExecute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" }, + { "internalType": "bytes", "name": "config_", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "storedExecutionHashes", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } +] diff --git a/simulations/vip-371/bscmainnet.ts b/simulations/vip-371/bscmainnet.ts new file mode 100644 index 000000000..77ba30c92 --- /dev/null +++ b/simulations/vip-371/bscmainnet.ts @@ -0,0 +1,17 @@ +import { expectEvents } from "../../src/utils"; +import { forking, testVip } from "../../src/vip-framework"; +import vip371 from "../../vips/vip-371/bscmainnet"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +forking(40343666, async () => { + testVip("vip371 XVS vault permission proposal", await vip371(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [3, 0], + ); + }, + }); +}); diff --git a/simulations/vip-371/bsctestnet.ts b/simulations/vip-371/bsctestnet.ts new file mode 100644 index 000000000..6f8807668 --- /dev/null +++ b/simulations/vip-371/bsctestnet.ts @@ -0,0 +1,17 @@ +import { expectEvents } from "../../src/utils"; +import { forking, testVip } from "../../src/vip-framework"; +import vip371 from "../../vips/vip-371/bsctestnet"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +forking(41938696, async () => { + testVip("vip371 XVS vault permission proposal", await vip371(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [3, 0], + ); + }, + }); +}); diff --git a/simulations/vip-372/abi/OmnichainProposalSender.json b/simulations/vip-372/abi/OmnichainProposalSender.json new file mode 100644 index 000000000..66fd4df02 --- /dev/null +++ b/simulations/vip-372/abi/OmnichainProposalSender.json @@ -0,0 +1,314 @@ +[ + { + "inputs": [ + { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } + ], + "name": "ClearPayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } + ], + "name": "ExecuteRemoteProposal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "FallbackWithdraw", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } + ], + "name": "StorePayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], + "name": "TrustedRemoteRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "LZ_ENDPOINT", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourCommandsSent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLastProposalSentTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bool", "name": "useZro_", "type": "bool" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } + ], + "name": "estimateFees", + "outputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } + ], + "name": "execute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "fallbackWithdraw", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "proposalCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], + "name": "removeTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "retryExecute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" }, + { "internalType": "bytes", "name": "config_", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "storedExecutionHashes", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } +] diff --git a/simulations/vip-372/bscmainnet.ts b/simulations/vip-372/bscmainnet.ts new file mode 100644 index 000000000..cbe3143d0 --- /dev/null +++ b/simulations/vip-372/bscmainnet.ts @@ -0,0 +1,17 @@ +import { expectEvents } from "../../src/utils"; +import { forking, testVip } from "../../src/vip-framework"; +import vip372 from "../../vips/vip-372/bscmainnet"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +forking(40343666, async () => { + testVip("vip372 XVS vault permission proposal", await vip372(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [3, 0], + ); + }, + }); +}); diff --git a/simulations/vip-372/bsctestnet.ts b/simulations/vip-372/bsctestnet.ts new file mode 100644 index 000000000..3f190a00f --- /dev/null +++ b/simulations/vip-372/bsctestnet.ts @@ -0,0 +1,17 @@ +import { expectEvents } from "../../src/utils"; +import { forking, testVip } from "../../src/vip-framework"; +import vip372 from "../../vips/vip-372/bsctestnet"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +forking(41938696, async () => { + testVip("vip372 XVS vault permission proposal", await vip372(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [3, 0], + ); + }, + }); +}); diff --git a/vips/vip-371/bscmainnet.ts b/vips/vip-371/bscmainnet.ts new file mode 100644 index 000000000..568caad1b --- /dev/null +++ b/vips/vip-371/bscmainnet.ts @@ -0,0 +1,205 @@ +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +import { PLP as ARBITRUMONE_PLP, PRIME as ARBITRUMONE_PRIME } from "../../multisig/proposals/arbitrumone/vip-014"; +import { REWARD_DISTRIBUTORS as ARBITRUMONE_REWARD_DISTRIBUTORS } from "../../multisig/proposals/arbitrumone/vip-014"; +import { COMPTROLLERS as ARBITRUMONE_COMPTROLLERS } from "../../multisig/proposals/arbitrumone/vip-014"; +import { VTOKENS as ARBITRUMONE_VTOKENS } from "../../multisig/proposals/arbitrumone/vip-014"; +import { POOL_REGISTRY as ARBITRUMONE_POOL_REGISTRY } from "../../multisig/proposals/arbitrumone/vip-014"; +import { PSR as ARBITRUMONE_PSR } from "../../multisig/proposals/arbitrumone/vip-014"; +import { CONVERTERS as ETHEREUM_CONVERTERS } from "../../multisig/proposals/ethereum/vip-061"; +import { CONVERTER_NETWORK as ETHEREUM_CONVERTER_NETWORK } from "../../multisig/proposals/ethereum/vip-061"; +import { PLP as ETHEREUM_PLP, PRIME as ETHEREUM_PRIME } from "../../multisig/proposals/ethereum/vip-061"; +import { REWARD_DISTRIBUTORS as ETHEREUM_REWARD_DISTRIBUTORS } from "../../multisig/proposals/ethereum/vip-061"; +import { COMPTROLLERS as ETHEREUM_COMPTROLLERS } from "../../multisig/proposals/ethereum/vip-061"; +import { VTOKENS as ETHEREUM_VTOKENS } from "../../multisig/proposals/ethereum/vip-061"; +import { POOL_REGISTRY as ETHEREUM_POOL_REGISTRY } from "../../multisig/proposals/ethereum/vip-061"; +import { PSR as ETHEREUM_PSR } from "../../multisig/proposals/ethereum/vip-061"; +import { COMPTROLLERS as OPBNBMAINNET_COMPTROLLERS } from "../../multisig/proposals/opbnbmainnet/vip-021"; +import { VTOKENS as OPBNBMAINNET_VTOKENS } from "../../multisig/proposals/opbnbmainnet/vip-021"; +import { POOL_REGISTRY as OPBNBMAINNET_POOL_REGISTRY } from "../../multisig/proposals/opbnbmainnet/vip-021"; +import { PSR as OPBNBMAINNET_PSR } from "../../multisig/proposals/opbnbmainnet/vip-021"; + +export const ETHEREUM_ACM = "0x230058da2D23eb8836EC5DB7037ef7250c56E25E"; +export const ARBITRUMONE_ACM = "0xD9dD18EB0cf10CbA837677f28A8F9Bda4bc2b157"; +export const OPBNBMAINNET_ACM = "0xA60Deae5344F1152426cA440fb6552eA0e3005D6"; + +export const ARBITRUM_ONE_FASTTRACK_TIMELOCK = "0x2286a9B2a5246218f2fC1F380383f45BDfCE3E04"; +export const ETHEREUM_FASTTRACK_TIMELOCK = "0x8764F50616B62a99A997876C2DEAaa04554C5B2E"; +export const OPBNBMAINNET_FASTTRACK_TIMELOCK = "0xEdD04Ecef0850e834833789576A1d435e7207C0d"; + +export const ARBITRUM_ONE_CRITICAL_TIMELOCK = "0x181E4f8F21D087bF02Ea2F64D5e550849FBca674"; +export const ETHEREUM_CRITICAL_TIMELOCK = "0xeB9b85342c34F65af734C7bd4a149c86c472bC00"; +export const OPBNBMAINNET_CRITICAL_TIMELOCK = "0xA7DD2b15B24377296F11c702e758cd9141AB34AA"; + +export const ARBITRUM_ONE_XVS_STORE = "0x507D9923c954AAD8eC530ed8Dedb75bFc893Ec5e"; +export const ETHEREUM_XVS_STORE = "0x1Db646E1Ab05571AF99e47e8F909801e5C99d37B"; +export const OPBNBMAINNET_XVS_STORE = "0xc3279442a5aCaCF0A2EcB015d1cDDBb3E0f3F775"; + +export const ETHEREUM_XVS_BRIDGE_ADMIN = "0x9C6C95632A8FB3A74f2fB4B7FfC50B003c992b96"; +export const OPBNBMAINNET_XVS_BRIDGE_ADMIN = "0x52fcE05aDbf6103d71ed2BA8Be7A317282731831"; +export const ARBITRUM_XVS_BRIDGE_ADMIN = "0xf5d81C6F7DAA3F97A6265C8441f92eFda22Ad784"; + +export const ARBITRUM_ONE_BOUND_VALIDATOR = "0x2245FA2420925Cd3C2D889Ddc5bA1aefEF0E14CF"; +export const ETHEREUM_BOUND_VALIDATOR = "0x1Cd5f336A1d28Dff445619CC63d3A0329B4d8a58"; +export const OPBNBMAINNET_BOUND_VALIDATOR = "0xd1f80C371C6E2Fa395A5574DB3E3b4dAf43dadCE"; +export const ETHEREUM_sFrxETH_ORACLE = "0x5E06A5f48692E4Fff376fDfCA9E4C0183AAADCD1"; + +const vip371 = () => { + const meta = { + version: "v2", + title: "VIP-371", + description: `### Description`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: ETHEREUM_CONVERTER_NETWORK, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.ethereum, + }, + ...ETHEREUM_CONVERTERS.map(converter => { + return { + target: converter, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.ethereum, + }; + }), + { + target: ETHEREUM_PRIME, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.ethereum, + }, + { + target: ETHEREUM_PLP, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.ethereum, + }, + { + target: ARBITRUMONE_PRIME, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ARBITRUMONE_PLP, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumone, + }, + ...ETHEREUM_REWARD_DISTRIBUTORS.map(rewardDistirbutor => { + return { + target: rewardDistirbutor, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.ethereum, + }; + }), + + ...ARBITRUMONE_REWARD_DISTRIBUTORS.map(rewardDistirbutor => { + return { + target: rewardDistirbutor, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumone, + }; + }), + { + target: ETHEREUM_PSR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.ethereum, + }, + { + target: ARBITRUMONE_PSR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumone, + }, + { + target: OPBNBMAINNET_PSR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbmainnet, + }, + { + target: ETHEREUM_POOL_REGISTRY, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.ethereum, + }, + ...ETHEREUM_COMPTROLLERS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.ethereum, + }; + }), + ...ETHEREUM_VTOKENS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.ethereum, + }; + }), + + { + target: ARBITRUMONE_POOL_REGISTRY, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumone, + }, + ...ARBITRUMONE_COMPTROLLERS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumone, + }; + }), + ...ARBITRUMONE_VTOKENS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumone, + }; + }), + + { + target: OPBNBMAINNET_POOL_REGISTRY, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbmainnet, + }, + ...OPBNBMAINNET_COMPTROLLERS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbmainnet, + }; + }), + ...OPBNBMAINNET_VTOKENS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbmainnet, + }; + }), + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip371; diff --git a/vips/vip-371/bsctestnet.ts b/vips/vip-371/bsctestnet.ts new file mode 100644 index 000000000..2e1fae7fc --- /dev/null +++ b/vips/vip-371/bsctestnet.ts @@ -0,0 +1,202 @@ +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +import { + PLP as ARBITRUMSEPOLIA_PLP, + PRIME as ARBITRUMSEPOLIA_PRIME, +} from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import { REWARD_DISTRIBUTORS as ARBITRUMSEPOLIA_REWARD_DISTRIBUTORS } from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import { PSR as ARBITRUMSEPOLIA_PSR } from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import { COMPTROLLERS as ARBITRUMSEPOLIA_COMPTROLLERS } from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import { VTOKENS as ARBITRUMSEPOLIA_VTOKENS } from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import { POOL_REGISTRY as ARBITRUMSEPOLIA_POOL_REGISTRY } from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import { PSR as OPBNBTESTNET_PSR } from "../../multisig/proposals/opbnbtestnet/vip-021"; +import { COMPTROLLERS as OPBNBTESTNET_COMPTROLLERS } from "../../multisig/proposals/opbnbtestnet/vip-021"; +import { VTOKENS as OPBNBTESTNET_VTOKENS } from "../../multisig/proposals/opbnbtestnet/vip-021"; +import { POOL_REGISTRY as OPBNBTESTNET_POOL_REGISTRY } from "../../multisig/proposals/opbnbtestnet/vip-021"; +import { CONVERTERS as SEPOLIA_CONVERTERS } from "../../multisig/proposals/sepolia/vip-060"; +import { CONVERTER_NETWORK as SEPOLIA_CONVERTER_NETWORK } from "../../multisig/proposals/sepolia/vip-060"; +import { PLP as SEPOLIA_PLP, PRIME as SEPOLIA_PRIME } from "../../multisig/proposals/sepolia/vip-060"; +import { REWARD_DISTRIBUTORS as SEPOLIA_REWARD_DISTRIBUTORS } from "../../multisig/proposals/sepolia/vip-060"; +import { PSR as SEPOLIA_PSR } from "../../multisig/proposals/sepolia/vip-060"; +import { COMPTROLLERS as SEPOLIA_COMPTROLLERS } from "../../multisig/proposals/sepolia/vip-060"; +import { VTOKENS as SEPOLIA_VTOKENS } from "../../multisig/proposals/sepolia/vip-060"; +import { POOL_REGISTRY as SEPOLIA_POOL_REGISTRY } from "../../multisig/proposals/sepolia/vip-060"; + +export const SEPOLIA_ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; +export const SEPOLIA_FASTTRACK_TIMELOCK = "0x7F043F43Adb392072a3Ba0cC9c96e894C6f7e182"; +export const SEPOLIA_CRITICAL_TIMELOCK = "0xA24A7A65b8968a749841988Bd7d05F6a94329fDe"; +export const ARBITRUM_SEPOLIA_ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; +export const OPBNBTESTNET_ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; + +export const ARBITRUM_SEPOLIA_XVS_STORE = "0x4e909DA6693215dC630104715c035B159dDb67Dd"; +export const SEPOLIA_XVS_STORE = "0x03B868C7858F50900fecE4eBc851199e957b5d3D"; +export const OPBNBTESTNET_XVS_STORE = "0x06473fB3f7bF11e2E8EfEcC95aC55ABEFCb2e0A0"; + +export const SEPOLIA_XVS_BRIDGE_ADMIN = "0xd3c6bdeeadB2359F726aD4cF42EAa8B7102DAd9B"; +export const OPBNBTESTNET_XVS_BRIDGE_ADMIN = "0x19252AFD0B2F539C400aEab7d460CBFbf74c17ff"; +export const ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN = "0xc94578caCC89a29B044a0a1D54d20d48A645E5C8"; + +export const ARBITRUM_SEPOLIA_BOUND_VALIDATOR = "0xfe6bc1545Cc14C131bacA97476D6035ffcC0b889"; +export const SEPOLIA_BOUND_VALIDATOR = "0x60c4Aa92eEb6884a76b309Dd8B3731ad514d6f9B"; +export const OPBNBTESTNET_BOUND_VALIDATOR = "0x049537Bb065e6253e9D8D08B45Bf6b753657A746"; +export const SEPOLIA_sFrxETH_ORACLE = "0x61EB836afA467677e6b403D504fe69D6940e7996"; + +const vip352 = () => { + const meta = { + version: "v2", + title: "VIP-332 accept ownership & give permissions to Normal Timelock", + description: `### Description`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: SEPOLIA_CONVERTER_NETWORK, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }, + ...SEPOLIA_CONVERTERS.map(converter => { + return { + target: converter, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }; + }), + { + target: SEPOLIA_PRIME, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }, + { + target: SEPOLIA_PLP, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }, + { + target: ARBITRUMSEPOLIA_PRIME, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ARBITRUMSEPOLIA_PLP, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + ...SEPOLIA_REWARD_DISTRIBUTORS.map(rewardDistirbutor => { + return { + target: rewardDistirbutor, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }; + }), + + ...ARBITRUMSEPOLIA_REWARD_DISTRIBUTORS.map(rewardDistirbutor => { + return { + target: rewardDistirbutor, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }; + }), + { + target: SEPOLIA_PSR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }, + { + target: ARBITRUMSEPOLIA_PSR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: OPBNBTESTNET_PSR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: SEPOLIA_POOL_REGISTRY, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }, + ...SEPOLIA_COMPTROLLERS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }; + }), + ...SEPOLIA_VTOKENS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }; + }), + + { + target: ARBITRUMSEPOLIA_POOL_REGISTRY, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + ...ARBITRUMSEPOLIA_COMPTROLLERS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }; + }), + ...ARBITRUMSEPOLIA_VTOKENS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }; + }), + + { + target: OPBNBTESTNET_POOL_REGISTRY, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }, + ...OPBNBTESTNET_COMPTROLLERS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }; + }), + ...OPBNBTESTNET_VTOKENS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }; + }), + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip352; diff --git a/vips/vip-372/bscmainnet.ts b/vips/vip-372/bscmainnet.ts new file mode 100644 index 000000000..fa912457d --- /dev/null +++ b/vips/vip-372/bscmainnet.ts @@ -0,0 +1,198 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const ETHEREUM_ACM = "0x230058da2D23eb8836EC5DB7037ef7250c56E25E"; +export const ARBITRUMONE_ACM = "0xD9dD18EB0cf10CbA837677f28A8F9Bda4bc2b157"; +export const OPBNBMAINNET_ACM = "0xA60Deae5344F1152426cA440fb6552eA0e3005D6"; + +export const ARBITRUM_ONE_FASTTRACK_TIMELOCK = "0x2286a9B2a5246218f2fC1F380383f45BDfCE3E04"; +export const ETHEREUM_FASTTRACK_TIMELOCK = "0x8764F50616B62a99A997876C2DEAaa04554C5B2E"; +export const OPBNBMAINNET_FASTTRACK_TIMELOCK = "0xEdD04Ecef0850e834833789576A1d435e7207C0d"; + +export const ARBITRUM_ONE_CRITICAL_TIMELOCK = "0x181E4f8F21D087bF02Ea2F64D5e550849FBca674"; +export const ETHEREUM_CRITICAL_TIMELOCK = "0xeB9b85342c34F65af734C7bd4a149c86c472bC00"; +export const OPBNBMAINNET_CRITICAL_TIMELOCK = "0xA7DD2b15B24377296F11c702e758cd9141AB34AA"; + +export const ARBITRUM_ONE_XVS_STORE = "0x507D9923c954AAD8eC530ed8Dedb75bFc893Ec5e"; +export const ETHEREUM_XVS_STORE = "0x1Db646E1Ab05571AF99e47e8F909801e5C99d37B"; +export const OPBNBMAINNET_XVS_STORE = "0xc3279442a5aCaCF0A2EcB015d1cDDBb3E0f3F775"; + +export const ETHEREUM_XVS_BRIDGE_ADMIN = "0x9C6C95632A8FB3A74f2fB4B7FfC50B003c992b96"; +export const OPBNBMAINNET_XVS_BRIDGE_ADMIN = "0x52fcE05aDbf6103d71ed2BA8Be7A317282731831"; +export const ARBITRUM_XVS_BRIDGE_ADMIN = "0xf5d81C6F7DAA3F97A6265C8441f92eFda22Ad784"; + +const ETHEREUM_CHAIN_ID = LzChainId.ethereum; +const OPBNBMAINNET_CHAIN_ID = LzChainId.opbnbmainnet; +const ARBITRUM_CHAIN_ID = LzChainId.arbitrumone; + +export const ARBITRUM_ONE_BOUND_VALIDATOR = "0x2245FA2420925Cd3C2D889Ddc5bA1aefEF0E14CF"; +export const ETHEREUM_BOUND_VALIDATOR = "0x1Cd5f336A1d28Dff445619CC63d3A0329B4d8a58"; +export const OPBNBMAINNET_BOUND_VALIDATOR = "0xD1f80C372C6e2FA395A5574Db3e3B4DaF43dAdCE"; +export const ETHEREUM_sFrxETH_ORACLE = "0x5E06A5f48692E4Fff376fDfCA9E4C0183AAADCD1"; + +const { arbitrumone, ethereum, opbnbmainnet } = NETWORK_ADDRESSES; + +const vip372 = () => { + const meta = { + version: "v2", + title: "VIP-372", + description: `### Description`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: arbitrumone.XVS_VAULT_PROXY, + signature: "_acceptAdmin()", + params: [], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ethereum.XVS_VAULT_PROXY, + signature: "_acceptAdmin()", + params: [], + dstChainId: LzChainId.ethereum, + }, + { + target: opbnbmainnet.XVS_VAULT_PROXY, + signature: "_acceptAdmin()", + params: [], + dstChainId: LzChainId.opbnbmainnet, + }, + { + target: ARBITRUM_ONE_XVS_STORE, + signature: "acceptAdmin()", + params: [], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ETHEREUM_XVS_STORE, + signature: "acceptAdmin()", + params: [], + dstChainId: LzChainId.ethereum, + }, + { + target: OPBNBMAINNET_XVS_STORE, + signature: "acceptAdmin()", + params: [], + dstChainId: LzChainId.opbnbmainnet, + }, + { + target: ARBITRUM_XVS_BRIDGE_ADMIN, + signature: "acceptOwnership()", + params: [], + dstChainId: ARBITRUM_CHAIN_ID, + }, + { + target: OPBNBMAINNET_XVS_BRIDGE_ADMIN, + signature: "acceptOwnership()", + params: [], + dstChainId: OPBNBMAINNET_CHAIN_ID, + }, + { + target: ETHEREUM_XVS_BRIDGE_ADMIN, + signature: "acceptOwnership()", + params: [], + dstChainId: ETHEREUM_CHAIN_ID, + }, + { + target: arbitrumone.CHAINLINK_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ARBITRUM_ONE_BOUND_VALIDATOR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumone, + }, + { + target: arbitrumone.REDSTONE_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumone, + }, + { + target: arbitrumone.RESILIENT_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumone, + }, + { + target: opbnbmainnet.BINANCE_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbmainnet, + }, + { + target: opbnbmainnet.RESILIENT_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbmainnet, + }, + { + target: OPBNBMAINNET_BOUND_VALIDATOR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbmainnet, + }, + + { + target: ethereum.CHAINLINK_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.ethereum, + }, + + { + target: ethereum.REDSTONE_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.ethereum, + }, + { + target: ethereum.RESILIENT_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.ethereum, + }, + { + target: ETHEREUM_BOUND_VALIDATOR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.ethereum, + }, + { + target: ETHEREUM_sFrxETH_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.ethereum, + }, + { + target: arbitrumone.VTREASURY, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumone, + }, + { + target: opbnbmainnet.VTREASURY, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbmainnet, + }, + { + target: ethereum.VTREASURY, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.ethereum, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip372; diff --git a/vips/vip-372/bsctestnet.ts b/vips/vip-372/bsctestnet.ts new file mode 100644 index 000000000..88cee4bd9 --- /dev/null +++ b/vips/vip-372/bsctestnet.ts @@ -0,0 +1,186 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const SEPOLIA_ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; +export const SEPOLIA_FASTTRACK_TIMELOCK = "0x7F043F43Adb392072a3Ba0cC9c96e894C6f7e182"; +export const SEPOLIA_CRITICAL_TIMELOCK = "0xA24A7A65b8968a749841988Bd7d05F6a94329fDe"; +export const ARBITRUM_SEPOLIA_ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; +export const OPBNBTESTNET_ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; + +export const ARBITRUM_SEPOLIA_XVS_STORE = "0x4e909DA6693215dC630104715c035B159dDb67Dd"; +export const SEPOLIA_XVS_STORE = "0x03B868C7858F50900fecE4eBc851199e957b5d3D"; +export const OPBNBTESTNET_XVS_STORE = "0x06473fB3f7bF11e2E8EfEcC95aC55ABEFCb2e0A0"; + +export const SEPOLIA_XVS_BRIDGE_ADMIN = "0xd3c6bdeeadB2359F726aD4cF42EAa8B7102DAd9B"; +export const OPBNBTESTNET_XVS_BRIDGE_ADMIN = "0x19252AFD0B2F539C400aEab7d460CBFbf74c17ff"; +export const ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN = "0xc94578caCC89a29B044a0a1D54d20d48A645E5C8"; + +const SEPOLIA_CHAIN_ID = LzChainId.sepolia; +const OPBNBTESTNET_CHAIN_ID = LzChainId.opbnbtestnet; +const ARBITRUM_SEPOLIA_CHAIN_ID = LzChainId.arbitrumsepolia; + +export const ARBITRUM_SEPOLIA_BOUND_VALIDATOR = "0xfe6bc1545Cc14C131bacA97476D6035ffcC0b889"; +export const SEPOLIA_BOUND_VALIDATOR = "0x60c4Aa92eEb6884a76b309Dd8B3731ad514d6f9B"; +export const OPBNBTESTNET_BOUND_VALIDATOR = "0x049537Bb065e6253e9D8D08B45Bf6b753657A746"; +export const SEPOLIA_sFrxETH_ORACLE = "0x61EB836afA467677e6b403D504fe69D6940e7996"; + +const { arbitrumsepolia, sepolia, opbnbtestnet } = NETWORK_ADDRESSES; + +const vip372 = () => { + const meta = { + version: "v2", + title: "VIP-332 accept ownership & give permissions to Normal Timelock", + description: `### Description`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: arbitrumsepolia.XVS_VAULT_PROXY, + signature: "_acceptAdmin()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: sepolia.XVS_VAULT_PROXY, + signature: "_acceptAdmin()", + params: [], + dstChainId: LzChainId.sepolia, + }, + { + target: opbnbtestnet.XVS_VAULT_PROXY, + signature: "_acceptAdmin()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: ARBITRUM_SEPOLIA_XVS_STORE, + signature: "acceptAdmin()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: SEPOLIA_XVS_STORE, + signature: "acceptAdmin()", + params: [], + dstChainId: LzChainId.sepolia, + }, + { + target: OPBNBTESTNET_XVS_STORE, + signature: "acceptAdmin()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN, + signature: "acceptOwnership()", + params: [], + dstChainId: ARBITRUM_SEPOLIA_CHAIN_ID, + }, + { + target: OPBNBTESTNET_XVS_BRIDGE_ADMIN, + signature: "acceptOwnership()", + params: [], + dstChainId: OPBNBTESTNET_CHAIN_ID, + }, + { + target: SEPOLIA_XVS_BRIDGE_ADMIN, + signature: "acceptOwnership()", + params: [], + dstChainId: SEPOLIA_CHAIN_ID, + }, + { + target: arbitrumsepolia.CHAINLINK_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ARBITRUM_SEPOLIA_BOUND_VALIDATOR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: arbitrumsepolia.REDSTONE_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: arbitrumsepolia.RESILIENT_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: opbnbtestnet.BINANCE_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: opbnbtestnet.RESILIENT_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: OPBNBTESTNET_BOUND_VALIDATOR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }, + + { + target: sepolia.CHAINLINK_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }, + + { + target: sepolia.REDSTONE_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }, + { + target: sepolia.RESILIENT_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }, + { + target: SEPOLIA_BOUND_VALIDATOR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }, + { + target: SEPOLIA_sFrxETH_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }, + { + target: arbitrumsepolia.VTREASURY, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: opbnbtestnet.VTREASURY, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip372; From 9dd4be6a8eedbeeac2c01c572b5bfbc54e2cd845 Mon Sep 17 00:00:00 2001 From: Narayan Prusty Date: Sun, 29 Sep 2024 18:33:33 +0400 Subject: [PATCH 006/178] fix: added simulations for multichain vips --- simulations/vip-371/abi/Comptroller.json | 929 ++++++++++++++++++ .../vip-371/abi/ComptrollerBeacon.json | 51 + simulations/vip-371/abi/ConverterNetwork.json | 205 ++++ .../vip-371/abi/DefaultProxyAdmin.json | 76 ++ simulations/vip-371/abi/PoolRegistry.json | 379 +++++++ simulations/vip-371/abi/Prime.json | 763 ++++++++++++++ .../vip-371/abi/PrimeLiquidityProvider.json | 385 ++++++++ .../vip-371/abi/ProtocolShareReserve.json | 356 +++++++ .../vip-371/abi/RewardDistributor.json | 532 ++++++++++ .../vip-371/abi/SingleTokenConverter.json | 587 +++++++++++ .../abi/SingleTokenConverterBeacon.json | 51 + simulations/vip-371/abi/VToken.json | 861 ++++++++++++++++ simulations/vip-371/abi/VTokenBeacon.json | 51 + simulations/vip-371/abi/XVSStore.json | 130 +++ simulations/vip-371/abi/XVSVault.json | 787 +++++++++++++++ simulations/vip-371/abi/XVSVaultProxy.json | 122 +++ simulations/vip-371/abi/boundValidator.json | 498 ++++++++++ simulations/vip-371/abi/chainlinkOracle.json | 459 +++++++++ simulations/vip-371/abi/resilientOracle.json | 640 ++++++++++++ simulations/vip-371/abi/sFrxETHOracle.json | 148 +++ simulations/vip-371/abi/treasury.json | 86 ++ simulations/vip-371/abi/xvs.json | 716 ++++++++++++++ simulations/vip-371/abi/xvsBridgeAdmin.json | 329 +++++++ simulations/vip-371/arbitrumone.ts | 82 ++ simulations/vip-371/arbitrumsepolia.ts | 81 ++ simulations/vip-371/ethereum.ts | 97 ++ simulations/vip-371/opbnbmainnet.ts | 53 + simulations/vip-371/opbnbtestnet.ts | 52 + simulations/vip-371/sepolia.ts | 97 ++ simulations/vip-372/abi/Comptroller.json | 929 ++++++++++++++++++ .../vip-372/abi/ComptrollerBeacon.json | 51 + simulations/vip-372/abi/ConverterNetwork.json | 205 ++++ .../vip-372/abi/DefaultProxyAdmin.json | 76 ++ simulations/vip-372/abi/PoolRegistry.json | 379 +++++++ simulations/vip-372/abi/Prime.json | 763 ++++++++++++++ .../vip-372/abi/PrimeLiquidityProvider.json | 385 ++++++++ .../vip-372/abi/ProtocolShareReserve.json | 356 +++++++ .../vip-372/abi/RewardDistributor.json | 532 ++++++++++ .../vip-372/abi/SingleTokenConverter.json | 587 +++++++++++ .../abi/SingleTokenConverterBeacon.json | 51 + simulations/vip-372/abi/VToken.json | 861 ++++++++++++++++ simulations/vip-372/abi/VTokenBeacon.json | 51 + simulations/vip-372/abi/XVSStore.json | 130 +++ simulations/vip-372/abi/XVSVault.json | 787 +++++++++++++++ simulations/vip-372/abi/XVSVaultProxy.json | 122 +++ simulations/vip-372/abi/binanceOracle.json | 284 ++++++ simulations/vip-372/abi/boundValidator.json | 498 ++++++++++ simulations/vip-372/abi/chainlinkOracle.json | 459 +++++++++ simulations/vip-372/abi/resilientOracle.json | 640 ++++++++++++ simulations/vip-372/abi/sFrxETHOracle.json | 148 +++ simulations/vip-372/abi/treasury.json | 86 ++ simulations/vip-372/abi/xvs.json | 716 ++++++++++++++ simulations/vip-372/abi/xvsBridge.json | 807 +++++++++++++++ simulations/vip-372/abi/xvsBridgeAdmin.json | 329 +++++++ simulations/vip-372/arbitrumone.ts | 58 ++ simulations/vip-372/arbitrumsepolia.ts | 62 ++ simulations/vip-372/ethereum.ts | 66 ++ simulations/vip-372/opbnbmainnet.ts | 58 ++ simulations/vip-372/opbnbtestnet.ts | 55 ++ simulations/vip-372/sepolia.ts | 65 ++ vips/vip-371/bscmainnet.ts | 25 - vips/vip-371/bsctestnet.ts | 19 - vips/vip-372/bscmainnet.ts | 12 - 63 files changed, 20199 insertions(+), 56 deletions(-) create mode 100644 simulations/vip-371/abi/Comptroller.json create mode 100644 simulations/vip-371/abi/ComptrollerBeacon.json create mode 100644 simulations/vip-371/abi/ConverterNetwork.json create mode 100644 simulations/vip-371/abi/DefaultProxyAdmin.json create mode 100644 simulations/vip-371/abi/PoolRegistry.json create mode 100644 simulations/vip-371/abi/Prime.json create mode 100644 simulations/vip-371/abi/PrimeLiquidityProvider.json create mode 100644 simulations/vip-371/abi/ProtocolShareReserve.json create mode 100644 simulations/vip-371/abi/RewardDistributor.json create mode 100644 simulations/vip-371/abi/SingleTokenConverter.json create mode 100644 simulations/vip-371/abi/SingleTokenConverterBeacon.json create mode 100644 simulations/vip-371/abi/VToken.json create mode 100644 simulations/vip-371/abi/VTokenBeacon.json create mode 100644 simulations/vip-371/abi/XVSStore.json create mode 100644 simulations/vip-371/abi/XVSVault.json create mode 100644 simulations/vip-371/abi/XVSVaultProxy.json create mode 100644 simulations/vip-371/abi/boundValidator.json create mode 100644 simulations/vip-371/abi/chainlinkOracle.json create mode 100644 simulations/vip-371/abi/resilientOracle.json create mode 100644 simulations/vip-371/abi/sFrxETHOracle.json create mode 100644 simulations/vip-371/abi/treasury.json create mode 100644 simulations/vip-371/abi/xvs.json create mode 100644 simulations/vip-371/abi/xvsBridgeAdmin.json create mode 100644 simulations/vip-371/arbitrumone.ts create mode 100644 simulations/vip-371/arbitrumsepolia.ts create mode 100644 simulations/vip-371/ethereum.ts create mode 100644 simulations/vip-371/opbnbmainnet.ts create mode 100644 simulations/vip-371/opbnbtestnet.ts create mode 100644 simulations/vip-371/sepolia.ts create mode 100644 simulations/vip-372/abi/Comptroller.json create mode 100644 simulations/vip-372/abi/ComptrollerBeacon.json create mode 100644 simulations/vip-372/abi/ConverterNetwork.json create mode 100644 simulations/vip-372/abi/DefaultProxyAdmin.json create mode 100644 simulations/vip-372/abi/PoolRegistry.json create mode 100644 simulations/vip-372/abi/Prime.json create mode 100644 simulations/vip-372/abi/PrimeLiquidityProvider.json create mode 100644 simulations/vip-372/abi/ProtocolShareReserve.json create mode 100644 simulations/vip-372/abi/RewardDistributor.json create mode 100644 simulations/vip-372/abi/SingleTokenConverter.json create mode 100644 simulations/vip-372/abi/SingleTokenConverterBeacon.json create mode 100644 simulations/vip-372/abi/VToken.json create mode 100644 simulations/vip-372/abi/VTokenBeacon.json create mode 100644 simulations/vip-372/abi/XVSStore.json create mode 100644 simulations/vip-372/abi/XVSVault.json create mode 100644 simulations/vip-372/abi/XVSVaultProxy.json create mode 100644 simulations/vip-372/abi/binanceOracle.json create mode 100644 simulations/vip-372/abi/boundValidator.json create mode 100644 simulations/vip-372/abi/chainlinkOracle.json create mode 100644 simulations/vip-372/abi/resilientOracle.json create mode 100644 simulations/vip-372/abi/sFrxETHOracle.json create mode 100644 simulations/vip-372/abi/treasury.json create mode 100644 simulations/vip-372/abi/xvs.json create mode 100644 simulations/vip-372/abi/xvsBridge.json create mode 100644 simulations/vip-372/abi/xvsBridgeAdmin.json create mode 100644 simulations/vip-372/arbitrumone.ts create mode 100644 simulations/vip-372/arbitrumsepolia.ts create mode 100644 simulations/vip-372/ethereum.ts create mode 100644 simulations/vip-372/opbnbmainnet.ts create mode 100644 simulations/vip-372/opbnbtestnet.ts create mode 100644 simulations/vip-372/sepolia.ts diff --git a/simulations/vip-371/abi/Comptroller.json b/simulations/vip-371/abi/Comptroller.json new file mode 100644 index 000000000..f3b2445ac --- /dev/null +++ b/simulations/vip-371/abi/Comptroller.json @@ -0,0 +1,929 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, + { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, + { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, + { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, + { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, + { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "TooMuchRepay", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "expectedSender", "type": "address" }, + { "internalType": "address", "name": "actualSender", "type": "address" } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, + { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "accountAssets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "actionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allMarkets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "approvedDelegates", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "borrowCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "contract VToken", "name": "vToken", "type": "address" } + ], + "name": "checkMembership", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], + "name": "enterMarkets", + "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], + "name": "exitMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAssetsIn", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getBorrowingPower", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "vTokenModify", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isForcedLiquidationEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "isMarketListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [ + { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "bool", "name": "isListed", "type": "bool" }, + { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "seizerContract", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, + { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, + { "internalType": "bool", "name": "paused", "type": "bool" } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "supplyCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "delegate", "type": "address" }, + { "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/ComptrollerBeacon.json b/simulations/vip-371/abi/ComptrollerBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/simulations/vip-371/abi/ComptrollerBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/ConverterNetwork.json b/simulations/vip-371/abi/ConverterNetwork.json new file mode 100644 index 000000000..396f12a91 --- /dev/null +++ b/simulations/vip-371/abi/ConverterNetwork.json @@ -0,0 +1,205 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { "inputs": [], "name": "ConverterAlreadyExists", "type": "error" }, + { "inputs": [], "name": "ConverterDoesNotExist", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "InvalidMaxLoopsLimit", + "type": "error" + }, + { "inputs": [], "name": "InvalidTokenConverterAddress", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], + "name": "ConverterAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], + "name": "ConverterRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], + "name": "addTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allConverters", + "outputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } + ], + "name": "findTokenConverters", + "outputs": [ + { "internalType": "address[]", "name": "converters", "type": "address[]" }, + { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } + ], + "name": "findTokenConvertersForConverters", + "outputs": [ + { "internalType": "address[]", "name": "converters", "type": "address[]" }, + { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getAllConverters", + "outputs": [{ "internalType": "contract IAbstractTokenConverter[]", "name": "converters", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_tokenConverter", "type": "address" }], + "name": "isTokenConverter", + "outputs": [{ "internalType": "bool", "name": "isConverter", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], + "name": "removeTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/DefaultProxyAdmin.json b/simulations/vip-371/abi/DefaultProxyAdmin.json new file mode 100644 index 000000000..9801cfcc7 --- /dev/null +++ b/simulations/vip-371/abi/DefaultProxyAdmin.json @@ -0,0 +1,76 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "changeProxyAdmin", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" } + ], + "name": "upgrade", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" }, + { "internalType": "bytes", "name": "data", "type": "bytes" } + ], + "name": "upgradeAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/PoolRegistry.json b/simulations/vip-371/abi/PoolRegistry.json new file mode 100644 index 000000000..31b1e2a17 --- /dev/null +++ b/simulations/vip-371/abi/PoolRegistry.json @@ -0,0 +1,379 @@ +[ + { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, + { + "name": "Unauthorized", + "type": "error", + "inputs": [ + { "name": "sender", "type": "address", "internalType": "address" }, + { "name": "calledContract", "type": "address", "internalType": "address" }, + { "name": "methodSignature", "type": "string", "internalType": "string" } + ] + }, + { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, + { + "name": "Initialized", + "type": "event", + "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], + "anonymous": false, + "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" + }, + { + "name": "MarketAdded", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" + }, + { + "name": "NewAccessControlManager", + "type": "event", + "inputs": [ + { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, + { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" + }, + { + "name": "OwnershipTransferStarted", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" + }, + { + "name": "OwnershipTransferred", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" + }, + { + "name": "PoolMetadataUpdated", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "oldMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + }, + { + "name": "newMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "anonymous": false, + "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" + }, + { + "name": "PoolNameSet", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, + { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } + ], + "anonymous": false, + "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" + }, + { + "name": "PoolRegistered", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "pool", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "anonymous": false, + "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" + }, + { + "name": "acceptOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x79ba5097", + "stateMutability": "nonpayable" + }, + { + "name": "accessControlManager", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "contract IAccessControlManagerV8" + } + ], + "constant": true, + "signature": "0xb4a0bdf3", + "stateMutability": "view" + }, + { + "name": "addMarket", + "type": "function", + "inputs": [ + { + "name": "input", + "type": "tuple", + "components": [ + { "name": "vToken", "type": "address", "internalType": "contract VToken" }, + { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, + { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, + { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, + { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, + { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistry.AddMarketInput" + } + ], + "outputs": [], + "signature": "0x23dc8d64", + "stateMutability": "nonpayable" + }, + { + "name": "addPool", + "type": "function", + "inputs": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, + { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, + { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } + ], + "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], + "signature": "0xeed873c2", + "stateMutability": "nonpayable" + }, + { + "name": "getAllPools", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "tuple[]", + "value": [], + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool[]" + } + ], + "constant": true, + "signature": "0xd88ff1f4", + "stateMutability": "view" + }, + { + "name": "getPoolByComptroller", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "constant": true, + "signature": "0x7aee632d", + "stateMutability": "view" + }, + { + "name": "getPoolsSupportedByAsset", + "type": "function", + "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], + "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], + "constant": true, + "signature": "0xf36dba38", + "stateMutability": "view" + }, + { + "name": "getVTokenForAsset", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "asset", "type": "address", "internalType": "address" } + ], + "outputs": [{ "name": "", "type": "address", "internalType": "address" }], + "constant": true, + "signature": "0x266e0a7f", + "stateMutability": "view" + }, + { + "name": "getVenusPoolMetadata", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "constant": true, + "signature": "0xa3aefa2c", + "stateMutability": "view" + }, + { + "name": "initialize", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xc4d66de8", + "stateMutability": "nonpayable" + }, + { + "name": "metadata", + "type": "function", + "inputs": [{ "name": "", "type": "address", "internalType": "address" }], + "outputs": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "constant": true, + "signature": "0x2ba21572", + "stateMutability": "view" + }, + { + "name": "owner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x8da5cb5b", + "stateMutability": "view" + }, + { + "name": "pendingOwner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0xe30c3978", + "stateMutability": "view" + }, + { + "name": "renounceOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x715018a6", + "stateMutability": "nonpayable" + }, + { + "name": "setAccessControlManager", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0x0e32cb86", + "stateMutability": "nonpayable" + }, + { + "name": "setPoolName", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "name", "type": "string", "internalType": "string" } + ], + "outputs": [], + "signature": "0x1cb6bb7e", + "stateMutability": "nonpayable" + }, + { + "name": "transferOwnership", + "type": "function", + "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xf2fde38b", + "stateMutability": "nonpayable" + }, + { + "name": "updatePoolMetadata", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { + "name": "metadata_", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "outputs": [], + "signature": "0xff94d958", + "stateMutability": "nonpayable" + } +] diff --git a/simulations/vip-371/abi/Prime.json b/simulations/vip-371/abi/Prime.json new file mode 100644 index 000000000..e8bfa99ff --- /dev/null +++ b/simulations/vip-371/abi/Prime.json @@ -0,0 +1,763 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, + { "internalType": "address", "name": "_nativeMarket", "type": "address" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, + { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, + { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, + { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, + { "internalType": "bool", "name": "_timeBased", "type": "bool" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, + { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidComptroller", "type": "error" }, + { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "n", "type": "uint256" }, + { "internalType": "uint256", "name": "d", "type": "uint256" } + ], + "name": "InvalidFraction", + "type": "error" + }, + { "inputs": [], "name": "InvalidLength", "type": "error" }, + { "inputs": [], "name": "InvalidLimit", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, + { "inputs": [], "name": "InvalidVToken", "type": "error" }, + { + "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], + "name": "LnNonRealResult", + "type": "error" + }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, + { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, + { "inputs": [], "name": "MarketNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, + { "inputs": [], "name": "WaitMoreTime", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, + { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } + ], + "name": "AlphaUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "Burn", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "InterestClaimed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } + ], + "name": "MintLimitsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } + ], + "name": "MultiplierUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } + ], + "name": "StakedAtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "TokenUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "UserScoreUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "MAXIMUM_XVS_CAP", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MINIMUM_STAKED_XVS", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_MARKET", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "STAKING_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WRAPPED_NATIVE_TOKEN", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "accrueInterest", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" } + ], + "name": "accrueInterestAndUpdateScore", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "alphaDenominator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "alphaNumerator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "calculateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "claimTimeRemaining", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "uint256", "name": "borrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supply", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } + ], + "name": "estimateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "getInterestAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "getPendingRewards", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "internalType": "struct PrimeStorageV1.PendingReward[]", + "name": "pendingRewards", + "type": "tuple[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "incomeDistributionYearly", + "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "xvsVault_", "type": "address" }, + { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, + { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, + { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, + { "internalType": "address", "name": "comptroller_", "type": "address" }, + { "internalType": "address", "name": "oracle_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "name": "initializeV2", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "interests", + "outputs": [ + { "internalType": "uint256", "name": "accrued", "type": "uint256" }, + { "internalType": "uint256", "name": "score", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "irrevocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "isScoreUpdated", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "isUserPrimeHolder", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, + { "internalType": "address[]", "name": "users", "type": "address[]" } + ], + "name": "issue", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, + { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, + { "internalType": "bool", "name": "exists", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "nextScoreUpdateRoundId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingScoreUpdates", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "primeLiquidityProvider", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "revocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } + ], + "name": "setLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "users", "type": "address[]" }, + { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } + ], + "name": "setStakedAt", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "stakedAt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokens", + "outputs": [ + { "internalType": "bool", "name": "exists", "type": "bool" }, + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalIrrevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalRevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalScoreUpdatesRequired", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "unreleasedPLPIncome", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, + { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } + ], + "name": "updateAlpha", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "updateMultipliers", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], + "name": "updateScores", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "vTokenForAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "xvsUpdated", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVault", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultPoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/PrimeLiquidityProvider.json b/simulations/vip-371/abi/PrimeLiquidityProvider.json new file mode 100644 index 000000000..02ca8e0bf --- /dev/null +++ b/simulations/vip-371/abi/PrimeLiquidityProvider.json @@ -0,0 +1,385 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "_timeBased", "type": "bool" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, + { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "balance", "type": "uint256" } + ], + "name": "InsufficientBalance", + "type": "error" + }, + { "inputs": [], "name": "InvalidArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidCaller", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "speed", "type": "uint256" }, + { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } + ], + "name": "InvalidDistributionSpeed", + "type": "error" + }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenAlreadyInitialized", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "TokenNotInitialized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "MaxTokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } + ], + "name": "PrimeTokenUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenDistributionInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "TokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokenTransferredToPrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokensAccrued", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "accrueTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "getEffectiveDistributionSpeed", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], + "name": "initializeTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "lastAccruedBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastAccruedBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "maxTokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } + ], + "name": "setMaxTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } + ], + "name": "setTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "tokenAmountAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/ProtocolShareReserve.json b/simulations/vip-371/abi/ProtocolShareReserve.json new file mode 100644 index 000000000..b33d7c495 --- /dev/null +++ b/simulations/vip-371/abi/ProtocolShareReserve.json @@ -0,0 +1,356 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, + { "internalType": "address", "name": "_wbnb", "type": "address" }, + { "internalType": "address", "name": "_vbnb", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetReleased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IProtocolShareReserve.IncomeType", + "name": "incomeType", + "type": "uint8" + }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "AssetsReservesUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } + ], + "name": "PoolRegistryUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "ReservesUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "CORE_POOL_COMPTROLLER", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MAX_PERCENT", + "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "internalType": "struct ProtocolShareReserve.DistributionConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "addOrUpdateDistributionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } + ], + "name": "assetsReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "distributionTargets", + "outputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "getPercentageDistribution", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "getUnreleasedFunds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address[]", "name": "assets", "type": "address[]" } + ], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "name": "removeDistributionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], + "name": "setPoolRegistry", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAssetReserve", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalDistributions", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/RewardDistributor.json b/simulations/vip-371/abi/RewardDistributor.json new file mode 100644 index 000000000..249fdd111 --- /dev/null +++ b/simulations/vip-371/abi/RewardDistributor.json @@ -0,0 +1,532 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "BorrowLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "BorrowLastRewardingBlockUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "ContributorRewardTokenSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } + ], + "name": "ContributorRewardsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } + ], + "name": "DistributedBorrowerRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } + ], + "name": "DistributedSupplierRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "MarketInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "indexed": false, + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "RewardTokenBorrowIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenBorrowSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RewardTokenGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "RewardTokenSupplyIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenSupplySpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "SupplyLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "SupplyLastRewardingBlockUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "INITIAL_INDEX", + "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "holder", "type": "address" }, + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } + ], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "distributeBorrowerRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "supplier", "type": "address" } + ], + "name": "distributeSupplierRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "grantRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, + { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "initializeMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastContributorBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "rewardToken", + "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenBorrowerIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenContributorSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenSupplierIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplySpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contributor", "type": "address" }, + { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } + ], + "name": "setContributorRewardTokenSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } + ], + "name": "setLastRewardingBlockTimestamps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, + { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } + ], + "name": "setLastRewardingBlocks", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } + ], + "name": "setRewardTokenSpeeds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], + "name": "updateContributorRewards", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "updateRewardTokenBorrowIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "updateRewardTokenSupplyIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/SingleTokenConverter.json b/simulations/vip-371/abi/SingleTokenConverter.json new file mode 100644 index 000000000..8ea10cc8d --- /dev/null +++ b/simulations/vip-371/abi/SingleTokenConverter.json @@ -0,0 +1,587 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { "inputs": [], "name": "AmountInMismatched", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, + { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, + { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, + { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, + { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, + { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, + { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, + { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, + { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, + { "inputs": [], "name": "InvalidToAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, + { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetTransferredToDestination", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } + ], + "name": "BaseAssetUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, + { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "baseAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "conversionConfigurations", + "outputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, + { "internalType": "address", "name": "destinationAddress_", "type": "address" }, + { "internalType": "address", "name": "baseAsset_", "type": "address" }, + { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], + "name": "setBaseAsset", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/SingleTokenConverterBeacon.json b/simulations/vip-371/abi/SingleTokenConverterBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/simulations/vip-371/abi/SingleTokenConverterBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/VToken.json b/simulations/vip-371/abi/VToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/simulations/vip-371/abi/VToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/VTokenBeacon.json b/simulations/vip-371/abi/VTokenBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/simulations/vip-371/abi/VTokenBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/XVSStore.json b/simulations/vip-371/abi/XVSStore.json new file mode 100644 index 000000000..2d9ea2bb2 --- /dev/null +++ b/simulations/vip-371/abi/XVSStore.json @@ -0,0 +1,130 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "AdminTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } + ], + "name": "NewPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnerTransferred", + "type": "event" + }, + { + "constant": false, + "inputs": [], + "name": "acceptAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "emergencyRewardWithdraw", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokens", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "token", "type": "address" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "safeRewardTransfer", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], + "name": "setNewOwner", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], + "name": "setPendingAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "bool", "name": "status", "type": "bool" } + ], + "name": "setRewardToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/XVSVault.json b/simulations/vip-371/abi/XVSVault.json new file mode 100644 index 000000000..51d8d540c --- /dev/null +++ b/simulations/vip-371/abi/XVSVault.json @@ -0,0 +1,787 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Claim", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } + ], + "name": "DelegateChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "DelegateVotesChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Deposit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ExecutedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "name": "PoolAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } + ], + "name": "PoolUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RequestedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } + ], + "name": "RewardAmountUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } + ], + "name": "StoreUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } + ], + "name": "VaultDebtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } + ], + "name": "WithdrawalLockingPeriodUpdated", + "type": "event" + }, + { + "constant": true, + "inputs": [], + "name": "DELEGATION_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "DOMAIN_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "MAX_LOCK_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "SECONDS_PER_YEAR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], + "name": "_become", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, + { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, + { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } + ], + "name": "add", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint32", "name": "", "type": "uint32" } + ], + "name": "checkpoints", + "outputs": [ + { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, + { "internalType": "uint96", "name": "votes", "type": "uint96" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_account", "type": "address" }, + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "claim", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], + "name": "delegate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "delegatee", "type": "address" }, + { "internalType": "uint256", "name": "nonce", "type": "uint256" }, + { "internalType": "uint256", "name": "expiry", "type": "uint256" }, + { "internalType": "uint8", "name": "v", "type": "uint8" }, + { "internalType": "bytes32", "name": "r", "type": "bytes32" }, + { "internalType": "bytes32", "name": "s", "type": "bytes32" } + ], + "name": "delegateBySig", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "delegates", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "deposit", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "executeWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getCurrentVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getEligibleWithdrawalAmount", + "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } + ], + "name": "getPriorVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getRequestedAmount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getUserInfo", + "outputs": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, + { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getWithdrawalRequests", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, + { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } + ], + "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", + "name": "", + "type": "tuple[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "name": "initializeTimeManager", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isStakedToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "nonces", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "numCheckpoints", + "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "pause", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingReward", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "pendingRewardTransfers", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingWithdrawalsBeforeUpgrade", + "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingXVSVaultImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "poolInfos", + "outputs": [ + { "internalType": "contract IBEP20", "name": "token", "type": "address" }, + { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, + { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], + "name": "poolLength", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primePoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeToken", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "requestWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "resume", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], + "name": "rewardTokenAmountsPerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAmountsPerBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } + ], + "name": "set", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], + "name": "setAccessControl", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, + { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } + ], + "name": "setPrimeToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } + ], + "name": "setRewardAmountPerBlockOrSecond", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } + ], + "name": "setWithdrawalLockingPeriod", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_xvs", "type": "address" }, + { "internalType": "address", "name": "_xvsStore", "type": "address" } + ], + "name": "setXvsStore", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAllocPoints", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "totalPendingWithdrawals", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "updatePool", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "vaultPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsStore", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/XVSVaultProxy.json b/simulations/vip-371/abi/XVSVaultProxy.json new file mode 100644 index 000000000..070a7fa56 --- /dev/null +++ b/simulations/vip-371/abi/XVSVaultProxy.json @@ -0,0 +1,122 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "error", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "info", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "detail", "type": "uint256" } + ], + "name": "Failure", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "NewAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldImplementation", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newImplementation", "type": "address" } + ], + "name": "NewImplementation", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } + ], + "name": "NewPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingImplementation", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingImplementation", "type": "address" } + ], + "name": "NewPendingImplementation", + "type": "event" + }, + { "payable": true, "stateMutability": "payable", "type": "fallback" }, + { + "constant": false, + "inputs": [], + "name": "_acceptAdmin", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "_acceptImplementation", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newPendingAdmin", "type": "address" }], + "name": "_setPendingAdmin", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newPendingImplementation", "type": "address" }], + "name": "_setPendingImplementation", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingXVSVaultImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/boundValidator.json b/simulations/vip-371/abi/boundValidator.json new file mode 100644 index 000000000..d16c8fb08 --- /dev/null +++ b/simulations/vip-371/abi/boundValidator.json @@ -0,0 +1,498 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "previousAdmin", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAdmin", + "type": "address" + } + ], + "name": "AdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "beacon", + "type": "address" + } + ], + "name": "BeaconUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "implementation", + "type": "address" + } + ], + "name": "Upgraded", + "type": "event" + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "inputs": [], + "name": "admin", + "outputs": [ + { + "internalType": "address", + "name": "admin_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [ + { + "internalType": "address", + "name": "implementation_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + } + ], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "upgradeToAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "stateMutability": "payable", + "type": "receive" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "upperBound", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "lowerBound", + "type": "uint256" + } + ], + "name": "ValidateConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig", + "name": "config", + "type": "tuple" + } + ], + "name": "setValidateConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "setValidateConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "validateConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "reportedPrice", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "anchorPrice", + "type": "uint256" + } + ], + "name": "validatePriceWithAnchorPrice", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_logic", + "type": "address" + }, + { + "internalType": "address", + "name": "admin_", + "type": "address" + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes" + } + ], + "stateMutability": "payable", + "type": "constructor" + } +] diff --git a/simulations/vip-371/abi/chainlinkOracle.json b/simulations/vip-371/abi/chainlinkOracle.json new file mode 100644 index 000000000..cdd689acb --- /dev/null +++ b/simulations/vip-371/abi/chainlinkOracle.json @@ -0,0 +1,459 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "vBnbAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "previousPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "requestedPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newPriceMantissa", + "type": "uint256" + } + ], + "name": "PricePosted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManager", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "prices", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + } + ], + "name": "setDirectPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VBep20Interface", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "underlyingPriceMantissa", + "type": "uint256" + } + ], + "name": "setUnderlyingPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "tokenConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/resilientOracle.json b/simulations/vip-371/abi/resilientOracle.json new file mode 100644 index 000000000..35f52caa0 --- /dev/null +++ b/simulations/vip-371/abi/resilientOracle.json @@ -0,0 +1,640 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "nativeMarketAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + }, + { + "internalType": "contract BoundValidatorInterface", + "name": "_boundValidator", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "mainOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "pivotOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "fallbackOracle", + "type": "address" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [ + { + "internalType": "contract BoundValidatorInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "getOracle", + "outputs": [ + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "bool", + "name": "enabled", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/sFrxETHOracle.json b/simulations/vip-371/abi/sFrxETHOracle.json new file mode 100644 index 000000000..b461549ba --- /dev/null +++ b/simulations/vip-371/abi/sFrxETHOracle.json @@ -0,0 +1,148 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_sfrxEthFraxOracle", "type": "address" }, + { "internalType": "address", "name": "_sfrxETH", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "BadPriceData", "type": "error" }, + { "inputs": [], "name": "InvalidTokenAddress", "type": "error" }, + { "inputs": [], "name": "PriceDifferenceExceeded", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxAllowedPriceDifference", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxAllowedPriceDifference", "type": "uint256" } + ], + "name": "MaxAllowedPriceDifferenceUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "SFRXETH", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "SFRXETH_FRAX_ORACLE", + "outputs": [{ "internalType": "contract ISfrxEthFraxOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxAllowedPriceDifference", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" }], + "name": "setMaxAllowedPriceDifference", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/treasury.json b/simulations/vip-371/abi/treasury.json new file mode 100644 index 000000000..18aabb61a --- /dev/null +++ b/simulations/vip-371/abi/treasury.json @@ -0,0 +1,86 @@ +[ + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryNative", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryToken", + "type": "event" + }, + { "stateMutability": "payable", "type": "fallback" }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryNative", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "stateMutability": "payable", "type": "receive" } +] diff --git a/simulations/vip-371/abi/xvs.json b/simulations/vip-371/abi/xvs.json new file mode 100644 index 000000000..69092bb4a --- /dev/null +++ b/simulations/vip-371/abi/xvs.json @@ -0,0 +1,716 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "AccountBlacklisted", + "type": "error" + }, + { + "inputs": [], + "name": "AddressesMustDiffer", + "type": "error" + }, + { + "inputs": [], + "name": "MintLimitExceed", + "type": "error" + }, + { + "inputs": [], + "name": "MintedAmountExceed", + "type": "error" + }, + { + "inputs": [], + "name": "NewCapNotGreaterThanMintedTokens", + "type": "error" + }, + { + "inputs": [], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "value", + "type": "bool" + } + ], + "name": "BlacklistUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "MintCapChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitDecreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "source", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "destination", + "type": "address" + } + ], + "name": "MintedTokensMigrated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "address", + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + } + ], + "name": "isBlackListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "source_", + "type": "address" + }, + { + "internalType": "address", + "name": "destination_", + "type": "address" + } + ], + "name": "migrateMinterTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToCap", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToMintedAmount", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newAccessControlAddress_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "minter_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "setMintCap", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + }, + { + "internalType": "bool", + "name": "value_", + "type": "bool" + } + ], + "name": "updateBlacklist", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/xvsBridgeAdmin.json b/simulations/vip-371/abi/xvsBridgeAdmin.json new file mode 100644 index 000000000..024450a40 --- /dev/null +++ b/simulations/vip-371/abi/xvsBridgeAdmin.json @@ -0,0 +1,329 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "XVSBridge_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "string", + "name": "signature", + "type": "string" + }, + { + "indexed": false, + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "name": "FunctionRegistryChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "stateMutability": "nonpayable", + "type": "fallback" + }, + { + "inputs": [], + "name": "XVSBridge", + "outputs": [ + { + "internalType": "contract IXVSProxyOFT", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "", + "type": "bytes4" + } + ], + "name": "functionRegistry", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "isTrustedRemote", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner_", + "type": "address" + } + ], + "name": "transferBridgeOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "string[]", + "name": "signatures_", + "type": "string[]" + }, + { + "internalType": "bool[]", + "name": "active_", + "type": "bool[]" + } + ], + "name": "upsertSignature", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-371/arbitrumone.ts b/simulations/vip-371/arbitrumone.ts new file mode 100644 index 000000000..7cef985d2 --- /dev/null +++ b/simulations/vip-371/arbitrumone.ts @@ -0,0 +1,82 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip014 from "../../multisig/proposals/arbitrumone/vip-014"; +import { + COMPTROLLERS, + PLP, + PRIME, + PSR, + REWARD_DISTRIBUTORS, + VTOKENS, + XVS_STORE, +} from "../../multisig/proposals/arbitrumone/vip-014"; +import vip371 from "../../vips/vip-371/bscmainnet"; +import COMPTROLLER_ABI from "./abi/Comptroller.json"; +import PRIME_ABI from "./abi/Prime.json"; +import PRIME_LIQUIDITY_PROVIDER_ABI from "./abi/PrimeLiquidityProvider.json"; +import PSR_ABI from "./abi/ProtocolShareReserve.json"; +import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistributor.json"; +import VTOKEN_ABI from "./abi/VToken.json"; +import XVS_STORE_ABI from "./abi/XVSStore.json"; +import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; + +const { arbitrumone } = NETWORK_ADDRESSES; + +forking(241112064, async () => { + const provider = ethers.provider; + let prime: Contract; + let plp: Contract; + const xvsVaultProxy = new ethers.Contract(arbitrumone.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); + const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); + + before(async () => { + prime = new ethers.Contract(PRIME, PRIME_ABI, provider); + plp = new ethers.Contract(PLP, PRIME_LIQUIDITY_PROVIDER_ABI, provider); + + await pretendExecutingVip(await vip014()); + }); + + testForkedNetworkVipCommands("vip350", await vip371()); + + describe("Post-VIP behavior", async () => { + it(`correct owner `, async () => { + expect(await prime.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); + expect(await plp.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); + }); + + for (const rewardDistributor of REWARD_DISTRIBUTORS) { + it(`correct owner for ${rewardDistributor}`, async () => { + const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); + expect(await c.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); + }); + } + + it(`correct owner for psr`, async () => { + const psr = new ethers.Contract(PSR, PSR_ABI, provider); + expect(await psr.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`correct owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`correct owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); + }); + } + + it("should have the correct pending owner", async () => { + expect(await xvsVaultProxy.admin()).to.equal(arbitrumone.NORMAL_TIMELOCK); + expect(await xvsStore.admin()).to.equal(arbitrumone.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/simulations/vip-371/arbitrumsepolia.ts b/simulations/vip-371/arbitrumsepolia.ts new file mode 100644 index 000000000..394b300ca --- /dev/null +++ b/simulations/vip-371/arbitrumsepolia.ts @@ -0,0 +1,81 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip014 from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import { + COMPTROLLERS, + PLP, + PRIME, + PSR, + REWARD_DISTRIBUTORS, + VTOKENS, + XVS_STORE, +} from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import vip371 from "../../vips/vip-371/bsctestnet"; +import COMPTROLLER_ABI from "./abi/Comptroller.json"; +import PRIME_ABI from "./abi/Prime.json"; +import PRIME_LIQUIDITY_PROVIDER_ABI from "./abi/PrimeLiquidityProvider.json"; +import PSR_ABI from "./abi/ProtocolShareReserve.json"; +import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistributor.json"; +import VTOKEN_ABI from "./abi/VToken.json"; +import XVS_STORE_ABI from "./abi/XVSStore.json"; +import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; + +const { arbitrumsepolia } = NETWORK_ADDRESSES; + +forking(70004884, async () => { + const provider = ethers.provider; + let prime: Contract; + let plp: Contract; + const xvsVaultProxy = new ethers.Contract(arbitrumsepolia.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); + const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); + + before(async () => { + prime = new ethers.Contract(PRIME, PRIME_ABI, provider); + plp = new ethers.Contract(PLP, PRIME_LIQUIDITY_PROVIDER_ABI, provider); + await pretendExecutingVip(await vip014()); + }); + + testForkedNetworkVipCommands("vip371", await vip371()); + + describe("Post-VIP behavior", async () => { + it(`correct owner `, async () => { + expect(await prime.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + expect(await plp.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + + for (const rewardDistributor of REWARD_DISTRIBUTORS) { + it(`correct owner for ${rewardDistributor}`, async () => { + const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); + expect(await c.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + } + + it(`correct owner for psr`, async () => { + const psr = new ethers.Contract(PSR, PSR_ABI, provider); + expect(await psr.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`correct owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`correct owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + } + + it("should have the correct pending owner", async () => { + expect(await xvsVaultProxy.admin()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + expect(await xvsStore.admin()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/simulations/vip-371/ethereum.ts b/simulations/vip-371/ethereum.ts new file mode 100644 index 000000000..455463f58 --- /dev/null +++ b/simulations/vip-371/ethereum.ts @@ -0,0 +1,97 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip061 from "../../multisig/proposals/ethereum/vip-061"; +import { + COMPTROLLERS, + CONVERTERS, + CONVERTER_NETWORK, + PLP, + PRIME, + PSR, + REWARD_DISTRIBUTORS, + VTOKENS, + XVS_STORE, +} from "../../multisig/proposals/ethereum/vip-061"; +import vip371 from "../../vips/vip-371/bscmainnet"; +import COMPTROLLER_ABI from "./abi/Comptroller.json"; +import CONVERTER_NETWORK_ABI from "./abi/ConverterNetwork.json"; +import PRIME_ABI from "./abi/Prime.json"; +import PRIME_LIQUIDITY_PROVIDER_ABI from "./abi/PrimeLiquidityProvider.json"; +import PSR_ABI from "./abi/ProtocolShareReserve.json"; +import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistributor.json"; +import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; +import VTOKEN_ABI from "./abi/VToken.json"; +import XVS_STORE_ABI from "./abi/XVSStore.json"; +import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; + +const { ethereum } = NETWORK_ADDRESSES; + +forking(20482317, async () => { + const provider = ethers.provider; + let prime: Contract; + let plp: Contract; + const xvsVaultProxy = new ethers.Contract(ethereum.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); + const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); + + before(async () => { + prime = new ethers.Contract(PRIME, PRIME_ABI, provider); + plp = new ethers.Contract(PLP, PRIME_LIQUIDITY_PROVIDER_ABI, provider); + await pretendExecutingVip(await vip061()); + }); + + testForkedNetworkVipCommands("vip350", await vip371()); + + describe("Post-VIP behavior", async () => { + for (const converter of CONVERTERS) { + it(`owner for ${converter}`, async () => { + const c = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); + expect(await c.owner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + } + + it(`owner for converter network`, async () => { + const c = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); + expect(await c.owner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + + it(`correct owner `, async () => { + expect(await prime.owner()).to.equal(ethereum.NORMAL_TIMELOCK); + expect(await plp.owner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + + for (const rewardDistributor of REWARD_DISTRIBUTORS) { + it(`correct owner for ${rewardDistributor}`, async () => { + const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); + expect(await c.owner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + } + + it(`correct owner for psr`, async () => { + const psr = new ethers.Contract(PSR, PSR_ABI, provider); + expect(await psr.owner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`correct owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.owner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`correct owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.owner()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + } + + it("should have the correct pending owner", async () => { + expect(await xvsVaultProxy.admin()).to.equal(ethereum.NORMAL_TIMELOCK); + expect(await xvsStore.admin()).to.equal(ethereum.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/simulations/vip-371/opbnbmainnet.ts b/simulations/vip-371/opbnbmainnet.ts new file mode 100644 index 000000000..15745f5c7 --- /dev/null +++ b/simulations/vip-371/opbnbmainnet.ts @@ -0,0 +1,53 @@ +import { expect } from "chai"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip021 from "../../multisig/proposals/opbnbmainnet/vip-021"; +import { COMPTROLLERS, PSR, VTOKENS, XVS_STORE } from "../../multisig/proposals/opbnbmainnet/vip-021"; +import vip371 from "../../vips/vip-371/bscmainnet"; +import COMPTROLLER_ABI from "./abi/Comptroller.json"; +import PSR_ABI from "./abi/ProtocolShareReserve.json"; +import VTOKEN_ABI from "./abi/VToken.json"; +import XVS_STORE_ABI from "./abi/XVSStore.json"; +import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; + +const { opbnbmainnet } = NETWORK_ADDRESSES; + +forking(31449867, async () => { + const provider = ethers.provider; + const xvsVaultProxy = new ethers.Contract(opbnbmainnet.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); + const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); + + before(async () => { + await pretendExecutingVip(await vip021()); + }); + + testForkedNetworkVipCommands("vip371", await vip371()); + + describe("Post-VIP behavior", async () => { + it(`correct owner for psr`, async () => { + const psr = new ethers.Contract(PSR, PSR_ABI, provider); + expect(await psr.owner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`correct owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.owner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`correct owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.owner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); + }); + } + + it("should have the correct pending owner", async () => { + expect(await xvsVaultProxy.admin()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); + expect(await xvsStore.admin()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/simulations/vip-371/opbnbtestnet.ts b/simulations/vip-371/opbnbtestnet.ts new file mode 100644 index 000000000..7e3ecebca --- /dev/null +++ b/simulations/vip-371/opbnbtestnet.ts @@ -0,0 +1,52 @@ +import { expect } from "chai"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip021, { COMPTROLLERS, PSR, VTOKENS, XVS_STORE } from "../../multisig/proposals/opbnbtestnet/vip-021"; +import vip371 from "../../vips/vip-350/bsctestnet"; +import COMPTROLLER_ABI from "./abi/Comptroller.json"; +import PSR_ABI from "./abi/ProtocolShareReserve.json"; +import VTOKEN_ABI from "./abi/VToken.json"; +import XVS_STORE_ABI from "./abi/XVSStore.json"; +import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; + +const { opbnbtestnet } = NETWORK_ADDRESSES; + +forking(36325286, async () => { + const provider = ethers.provider; + const xvsVaultProxy = new ethers.Contract(opbnbtestnet.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); + const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); + + before(async () => { + await pretendExecutingVip(await vip021()); + }); + + testForkedNetworkVipCommands("vip371", await vip371()); + + describe("Post-VIP behavior", async () => { + it(`correct owner for psr`, async () => { + const psr = new ethers.Contract(PSR, PSR_ABI, provider); + expect(await psr.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`correct owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`correct owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + }); + } + + it("should have the correct pending owner", async () => { + expect(await xvsVaultProxy.admin()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + expect(await xvsStore.admin()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/simulations/vip-371/sepolia.ts b/simulations/vip-371/sepolia.ts new file mode 100644 index 000000000..3e08eba5f --- /dev/null +++ b/simulations/vip-371/sepolia.ts @@ -0,0 +1,97 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip060 from "../../multisig/proposals/sepolia/vip-060"; +import { + COMPTROLLERS, + CONVERTERS, + CONVERTER_NETWORK, + PLP, + PRIME, + PSR, + REWARD_DISTRIBUTORS, + VTOKENS, + XVS_STORE, +} from "../../multisig/proposals/sepolia/vip-060"; +import vip371 from "../../vips/vip-371/bsctestnet"; +import COMPTROLLER_ABI from "./abi/Comptroller.json"; +import CONVERTER_NETWORK_ABI from "./abi/ConverterNetwork.json"; +import PRIME_ABI from "./abi/Prime.json"; +import PRIME_LIQUIDITY_PROVIDER_ABI from "./abi/PrimeLiquidityProvider.json"; +import PSR_ABI from "./abi/ProtocolShareReserve.json"; +import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistributor.json"; +import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; +import VTOKEN_ABI from "./abi/VToken.json"; +import XVS_STORE_ABI from "./abi/XVSStore.json"; +import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; + +const { sepolia } = NETWORK_ADDRESSES; + +forking(6460097, async () => { + const provider = ethers.provider; + let prime: Contract; + let plp: Contract; + const xvsVaultProxy = new ethers.Contract(sepolia.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); + const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); + + before(async () => { + prime = new ethers.Contract(PRIME, PRIME_ABI, provider); + plp = new ethers.Contract(PLP, PRIME_LIQUIDITY_PROVIDER_ABI, provider); + await pretendExecutingVip(await vip060()); + }); + + testForkedNetworkVipCommands("vip350", await vip371()); + + describe("Post-VIP behavior", async () => { + for (const converter of CONVERTERS) { + it(`owner for ${converter}`, async () => { + const c = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); + expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + } + + it(`owner for converter network`, async () => { + const c = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); + expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + + it(`correct owner `, async () => { + expect(await prime.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + expect(await plp.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + + for (const rewardDistributor of REWARD_DISTRIBUTORS) { + it(`correct owner for ${rewardDistributor}`, async () => { + const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); + expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + } + + it(`correct owner for psr`, async () => { + const psr = new ethers.Contract(PSR, PSR_ABI, provider); + expect(await psr.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + + for (const comptrollerAddress of COMPTROLLERS) { + it(`correct owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`correct owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + } + + it("should have the correct pending owner", async () => { + expect(await xvsVaultProxy.admin()).to.equal(sepolia.NORMAL_TIMELOCK); + expect(await xvsStore.admin()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/simulations/vip-372/abi/Comptroller.json b/simulations/vip-372/abi/Comptroller.json new file mode 100644 index 000000000..f3b2445ac --- /dev/null +++ b/simulations/vip-372/abi/Comptroller.json @@ -0,0 +1,929 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, + { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, + { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, + { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, + { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, + { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "TooMuchRepay", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "expectedSender", "type": "address" }, + { "internalType": "address", "name": "actualSender", "type": "address" } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, + { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "accountAssets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "actionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allMarkets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "approvedDelegates", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "borrowCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "contract VToken", "name": "vToken", "type": "address" } + ], + "name": "checkMembership", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], + "name": "enterMarkets", + "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], + "name": "exitMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAssetsIn", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getBorrowingPower", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "vTokenModify", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isForcedLiquidationEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "isMarketListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [ + { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "bool", "name": "isListed", "type": "bool" }, + { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "seizerContract", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, + { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, + { "internalType": "bool", "name": "paused", "type": "bool" } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "supplyCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "delegate", "type": "address" }, + { "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/ComptrollerBeacon.json b/simulations/vip-372/abi/ComptrollerBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/simulations/vip-372/abi/ComptrollerBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/ConverterNetwork.json b/simulations/vip-372/abi/ConverterNetwork.json new file mode 100644 index 000000000..396f12a91 --- /dev/null +++ b/simulations/vip-372/abi/ConverterNetwork.json @@ -0,0 +1,205 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { "inputs": [], "name": "ConverterAlreadyExists", "type": "error" }, + { "inputs": [], "name": "ConverterDoesNotExist", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "InvalidMaxLoopsLimit", + "type": "error" + }, + { "inputs": [], "name": "InvalidTokenConverterAddress", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], + "name": "ConverterAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], + "name": "ConverterRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], + "name": "addTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allConverters", + "outputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } + ], + "name": "findTokenConverters", + "outputs": [ + { "internalType": "address[]", "name": "converters", "type": "address[]" }, + { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } + ], + "name": "findTokenConvertersForConverters", + "outputs": [ + { "internalType": "address[]", "name": "converters", "type": "address[]" }, + { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getAllConverters", + "outputs": [{ "internalType": "contract IAbstractTokenConverter[]", "name": "converters", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_tokenConverter", "type": "address" }], + "name": "isTokenConverter", + "outputs": [{ "internalType": "bool", "name": "isConverter", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], + "name": "removeTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/DefaultProxyAdmin.json b/simulations/vip-372/abi/DefaultProxyAdmin.json new file mode 100644 index 000000000..9801cfcc7 --- /dev/null +++ b/simulations/vip-372/abi/DefaultProxyAdmin.json @@ -0,0 +1,76 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "changeProxyAdmin", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" } + ], + "name": "upgrade", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" }, + { "internalType": "bytes", "name": "data", "type": "bytes" } + ], + "name": "upgradeAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/PoolRegistry.json b/simulations/vip-372/abi/PoolRegistry.json new file mode 100644 index 000000000..31b1e2a17 --- /dev/null +++ b/simulations/vip-372/abi/PoolRegistry.json @@ -0,0 +1,379 @@ +[ + { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, + { + "name": "Unauthorized", + "type": "error", + "inputs": [ + { "name": "sender", "type": "address", "internalType": "address" }, + { "name": "calledContract", "type": "address", "internalType": "address" }, + { "name": "methodSignature", "type": "string", "internalType": "string" } + ] + }, + { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, + { + "name": "Initialized", + "type": "event", + "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], + "anonymous": false, + "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" + }, + { + "name": "MarketAdded", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" + }, + { + "name": "NewAccessControlManager", + "type": "event", + "inputs": [ + { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, + { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" + }, + { + "name": "OwnershipTransferStarted", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" + }, + { + "name": "OwnershipTransferred", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" + }, + { + "name": "PoolMetadataUpdated", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "oldMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + }, + { + "name": "newMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "anonymous": false, + "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" + }, + { + "name": "PoolNameSet", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, + { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } + ], + "anonymous": false, + "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" + }, + { + "name": "PoolRegistered", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "pool", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "anonymous": false, + "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" + }, + { + "name": "acceptOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x79ba5097", + "stateMutability": "nonpayable" + }, + { + "name": "accessControlManager", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "contract IAccessControlManagerV8" + } + ], + "constant": true, + "signature": "0xb4a0bdf3", + "stateMutability": "view" + }, + { + "name": "addMarket", + "type": "function", + "inputs": [ + { + "name": "input", + "type": "tuple", + "components": [ + { "name": "vToken", "type": "address", "internalType": "contract VToken" }, + { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, + { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, + { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, + { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, + { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistry.AddMarketInput" + } + ], + "outputs": [], + "signature": "0x23dc8d64", + "stateMutability": "nonpayable" + }, + { + "name": "addPool", + "type": "function", + "inputs": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, + { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, + { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } + ], + "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], + "signature": "0xeed873c2", + "stateMutability": "nonpayable" + }, + { + "name": "getAllPools", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "tuple[]", + "value": [], + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool[]" + } + ], + "constant": true, + "signature": "0xd88ff1f4", + "stateMutability": "view" + }, + { + "name": "getPoolByComptroller", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "constant": true, + "signature": "0x7aee632d", + "stateMutability": "view" + }, + { + "name": "getPoolsSupportedByAsset", + "type": "function", + "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], + "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], + "constant": true, + "signature": "0xf36dba38", + "stateMutability": "view" + }, + { + "name": "getVTokenForAsset", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "asset", "type": "address", "internalType": "address" } + ], + "outputs": [{ "name": "", "type": "address", "internalType": "address" }], + "constant": true, + "signature": "0x266e0a7f", + "stateMutability": "view" + }, + { + "name": "getVenusPoolMetadata", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "constant": true, + "signature": "0xa3aefa2c", + "stateMutability": "view" + }, + { + "name": "initialize", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xc4d66de8", + "stateMutability": "nonpayable" + }, + { + "name": "metadata", + "type": "function", + "inputs": [{ "name": "", "type": "address", "internalType": "address" }], + "outputs": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "constant": true, + "signature": "0x2ba21572", + "stateMutability": "view" + }, + { + "name": "owner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x8da5cb5b", + "stateMutability": "view" + }, + { + "name": "pendingOwner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0xe30c3978", + "stateMutability": "view" + }, + { + "name": "renounceOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x715018a6", + "stateMutability": "nonpayable" + }, + { + "name": "setAccessControlManager", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0x0e32cb86", + "stateMutability": "nonpayable" + }, + { + "name": "setPoolName", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "name", "type": "string", "internalType": "string" } + ], + "outputs": [], + "signature": "0x1cb6bb7e", + "stateMutability": "nonpayable" + }, + { + "name": "transferOwnership", + "type": "function", + "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xf2fde38b", + "stateMutability": "nonpayable" + }, + { + "name": "updatePoolMetadata", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { + "name": "metadata_", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "outputs": [], + "signature": "0xff94d958", + "stateMutability": "nonpayable" + } +] diff --git a/simulations/vip-372/abi/Prime.json b/simulations/vip-372/abi/Prime.json new file mode 100644 index 000000000..e8bfa99ff --- /dev/null +++ b/simulations/vip-372/abi/Prime.json @@ -0,0 +1,763 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, + { "internalType": "address", "name": "_nativeMarket", "type": "address" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, + { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, + { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, + { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, + { "internalType": "bool", "name": "_timeBased", "type": "bool" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, + { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidComptroller", "type": "error" }, + { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "n", "type": "uint256" }, + { "internalType": "uint256", "name": "d", "type": "uint256" } + ], + "name": "InvalidFraction", + "type": "error" + }, + { "inputs": [], "name": "InvalidLength", "type": "error" }, + { "inputs": [], "name": "InvalidLimit", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, + { "inputs": [], "name": "InvalidVToken", "type": "error" }, + { + "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], + "name": "LnNonRealResult", + "type": "error" + }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, + { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, + { "inputs": [], "name": "MarketNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, + { "inputs": [], "name": "WaitMoreTime", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, + { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } + ], + "name": "AlphaUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "Burn", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "InterestClaimed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } + ], + "name": "MintLimitsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } + ], + "name": "MultiplierUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } + ], + "name": "StakedAtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "TokenUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "UserScoreUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "MAXIMUM_XVS_CAP", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MINIMUM_STAKED_XVS", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_MARKET", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "STAKING_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WRAPPED_NATIVE_TOKEN", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "accrueInterest", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" } + ], + "name": "accrueInterestAndUpdateScore", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "alphaDenominator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "alphaNumerator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "calculateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "claimTimeRemaining", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "uint256", "name": "borrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supply", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } + ], + "name": "estimateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "getInterestAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "getPendingRewards", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "internalType": "struct PrimeStorageV1.PendingReward[]", + "name": "pendingRewards", + "type": "tuple[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "incomeDistributionYearly", + "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "xvsVault_", "type": "address" }, + { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, + { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, + { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, + { "internalType": "address", "name": "comptroller_", "type": "address" }, + { "internalType": "address", "name": "oracle_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "name": "initializeV2", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "interests", + "outputs": [ + { "internalType": "uint256", "name": "accrued", "type": "uint256" }, + { "internalType": "uint256", "name": "score", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "irrevocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "isScoreUpdated", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "isUserPrimeHolder", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, + { "internalType": "address[]", "name": "users", "type": "address[]" } + ], + "name": "issue", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, + { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, + { "internalType": "bool", "name": "exists", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "nextScoreUpdateRoundId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingScoreUpdates", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "primeLiquidityProvider", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "revocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } + ], + "name": "setLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "users", "type": "address[]" }, + { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } + ], + "name": "setStakedAt", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "stakedAt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokens", + "outputs": [ + { "internalType": "bool", "name": "exists", "type": "bool" }, + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalIrrevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalRevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalScoreUpdatesRequired", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "unreleasedPLPIncome", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, + { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } + ], + "name": "updateAlpha", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "updateMultipliers", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], + "name": "updateScores", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "vTokenForAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "xvsUpdated", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVault", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultPoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/PrimeLiquidityProvider.json b/simulations/vip-372/abi/PrimeLiquidityProvider.json new file mode 100644 index 000000000..02ca8e0bf --- /dev/null +++ b/simulations/vip-372/abi/PrimeLiquidityProvider.json @@ -0,0 +1,385 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "_timeBased", "type": "bool" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, + { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "balance", "type": "uint256" } + ], + "name": "InsufficientBalance", + "type": "error" + }, + { "inputs": [], "name": "InvalidArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidCaller", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "speed", "type": "uint256" }, + { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } + ], + "name": "InvalidDistributionSpeed", + "type": "error" + }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenAlreadyInitialized", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "TokenNotInitialized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "MaxTokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } + ], + "name": "PrimeTokenUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenDistributionInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "TokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokenTransferredToPrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokensAccrued", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "accrueTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "getEffectiveDistributionSpeed", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], + "name": "initializeTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "lastAccruedBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastAccruedBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "maxTokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } + ], + "name": "setMaxTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } + ], + "name": "setTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "tokenAmountAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/ProtocolShareReserve.json b/simulations/vip-372/abi/ProtocolShareReserve.json new file mode 100644 index 000000000..b33d7c495 --- /dev/null +++ b/simulations/vip-372/abi/ProtocolShareReserve.json @@ -0,0 +1,356 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, + { "internalType": "address", "name": "_wbnb", "type": "address" }, + { "internalType": "address", "name": "_vbnb", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetReleased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IProtocolShareReserve.IncomeType", + "name": "incomeType", + "type": "uint8" + }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "AssetsReservesUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } + ], + "name": "PoolRegistryUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "ReservesUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "CORE_POOL_COMPTROLLER", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MAX_PERCENT", + "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "internalType": "struct ProtocolShareReserve.DistributionConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "addOrUpdateDistributionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } + ], + "name": "assetsReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "distributionTargets", + "outputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "getPercentageDistribution", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "getUnreleasedFunds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address[]", "name": "assets", "type": "address[]" } + ], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "name": "removeDistributionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], + "name": "setPoolRegistry", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAssetReserve", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalDistributions", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/RewardDistributor.json b/simulations/vip-372/abi/RewardDistributor.json new file mode 100644 index 000000000..249fdd111 --- /dev/null +++ b/simulations/vip-372/abi/RewardDistributor.json @@ -0,0 +1,532 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "BorrowLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "BorrowLastRewardingBlockUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "ContributorRewardTokenSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } + ], + "name": "ContributorRewardsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } + ], + "name": "DistributedBorrowerRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } + ], + "name": "DistributedSupplierRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "MarketInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "indexed": false, + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "RewardTokenBorrowIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenBorrowSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RewardTokenGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "RewardTokenSupplyIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenSupplySpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "SupplyLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "SupplyLastRewardingBlockUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "INITIAL_INDEX", + "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "holder", "type": "address" }, + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } + ], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "distributeBorrowerRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "supplier", "type": "address" } + ], + "name": "distributeSupplierRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "grantRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, + { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "initializeMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastContributorBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "rewardToken", + "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenBorrowerIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenContributorSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenSupplierIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplySpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contributor", "type": "address" }, + { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } + ], + "name": "setContributorRewardTokenSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } + ], + "name": "setLastRewardingBlockTimestamps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, + { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } + ], + "name": "setLastRewardingBlocks", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } + ], + "name": "setRewardTokenSpeeds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], + "name": "updateContributorRewards", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "updateRewardTokenBorrowIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "updateRewardTokenSupplyIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/SingleTokenConverter.json b/simulations/vip-372/abi/SingleTokenConverter.json new file mode 100644 index 000000000..8ea10cc8d --- /dev/null +++ b/simulations/vip-372/abi/SingleTokenConverter.json @@ -0,0 +1,587 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { "inputs": [], "name": "AmountInMismatched", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, + { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, + { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, + { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, + { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, + { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, + { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, + { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, + { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, + { "inputs": [], "name": "InvalidToAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, + { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetTransferredToDestination", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } + ], + "name": "BaseAssetUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, + { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "baseAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "conversionConfigurations", + "outputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, + { "internalType": "address", "name": "destinationAddress_", "type": "address" }, + { "internalType": "address", "name": "baseAsset_", "type": "address" }, + { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], + "name": "setBaseAsset", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/SingleTokenConverterBeacon.json b/simulations/vip-372/abi/SingleTokenConverterBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/simulations/vip-372/abi/SingleTokenConverterBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/VToken.json b/simulations/vip-372/abi/VToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/simulations/vip-372/abi/VToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/VTokenBeacon.json b/simulations/vip-372/abi/VTokenBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/simulations/vip-372/abi/VTokenBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/XVSStore.json b/simulations/vip-372/abi/XVSStore.json new file mode 100644 index 000000000..2d9ea2bb2 --- /dev/null +++ b/simulations/vip-372/abi/XVSStore.json @@ -0,0 +1,130 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "AdminTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } + ], + "name": "NewPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnerTransferred", + "type": "event" + }, + { + "constant": false, + "inputs": [], + "name": "acceptAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "emergencyRewardWithdraw", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokens", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "token", "type": "address" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "safeRewardTransfer", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], + "name": "setNewOwner", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], + "name": "setPendingAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "bool", "name": "status", "type": "bool" } + ], + "name": "setRewardToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/XVSVault.json b/simulations/vip-372/abi/XVSVault.json new file mode 100644 index 000000000..51d8d540c --- /dev/null +++ b/simulations/vip-372/abi/XVSVault.json @@ -0,0 +1,787 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Claim", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } + ], + "name": "DelegateChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "DelegateVotesChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Deposit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ExecutedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "name": "PoolAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } + ], + "name": "PoolUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RequestedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } + ], + "name": "RewardAmountUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } + ], + "name": "StoreUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } + ], + "name": "VaultDebtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } + ], + "name": "WithdrawalLockingPeriodUpdated", + "type": "event" + }, + { + "constant": true, + "inputs": [], + "name": "DELEGATION_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "DOMAIN_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "MAX_LOCK_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "SECONDS_PER_YEAR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], + "name": "_become", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, + { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, + { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } + ], + "name": "add", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint32", "name": "", "type": "uint32" } + ], + "name": "checkpoints", + "outputs": [ + { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, + { "internalType": "uint96", "name": "votes", "type": "uint96" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_account", "type": "address" }, + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "claim", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], + "name": "delegate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "delegatee", "type": "address" }, + { "internalType": "uint256", "name": "nonce", "type": "uint256" }, + { "internalType": "uint256", "name": "expiry", "type": "uint256" }, + { "internalType": "uint8", "name": "v", "type": "uint8" }, + { "internalType": "bytes32", "name": "r", "type": "bytes32" }, + { "internalType": "bytes32", "name": "s", "type": "bytes32" } + ], + "name": "delegateBySig", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "delegates", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "deposit", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "executeWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getCurrentVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getEligibleWithdrawalAmount", + "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } + ], + "name": "getPriorVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getRequestedAmount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getUserInfo", + "outputs": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, + { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getWithdrawalRequests", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, + { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } + ], + "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", + "name": "", + "type": "tuple[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "name": "initializeTimeManager", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isStakedToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "nonces", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "numCheckpoints", + "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "pause", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingReward", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "pendingRewardTransfers", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingWithdrawalsBeforeUpgrade", + "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingXVSVaultImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "poolInfos", + "outputs": [ + { "internalType": "contract IBEP20", "name": "token", "type": "address" }, + { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, + { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], + "name": "poolLength", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primePoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeToken", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "requestWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "resume", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], + "name": "rewardTokenAmountsPerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAmountsPerBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } + ], + "name": "set", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], + "name": "setAccessControl", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, + { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } + ], + "name": "setPrimeToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } + ], + "name": "setRewardAmountPerBlockOrSecond", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } + ], + "name": "setWithdrawalLockingPeriod", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_xvs", "type": "address" }, + { "internalType": "address", "name": "_xvsStore", "type": "address" } + ], + "name": "setXvsStore", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAllocPoints", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "totalPendingWithdrawals", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "updatePool", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "vaultPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsStore", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/XVSVaultProxy.json b/simulations/vip-372/abi/XVSVaultProxy.json new file mode 100644 index 000000000..070a7fa56 --- /dev/null +++ b/simulations/vip-372/abi/XVSVaultProxy.json @@ -0,0 +1,122 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "error", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "info", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "detail", "type": "uint256" } + ], + "name": "Failure", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "NewAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldImplementation", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newImplementation", "type": "address" } + ], + "name": "NewImplementation", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } + ], + "name": "NewPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingImplementation", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingImplementation", "type": "address" } + ], + "name": "NewPendingImplementation", + "type": "event" + }, + { "payable": true, "stateMutability": "payable", "type": "fallback" }, + { + "constant": false, + "inputs": [], + "name": "_acceptAdmin", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "_acceptImplementation", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newPendingAdmin", "type": "address" }], + "name": "_setPendingAdmin", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newPendingImplementation", "type": "address" }], + "name": "_setPendingImplementation", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingXVSVaultImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/binanceOracle.json b/simulations/vip-372/abi/binanceOracle.json new file mode 100644 index 000000000..513793a74 --- /dev/null +++ b/simulations/vip-372/abi/binanceOracle.json @@ -0,0 +1,284 @@ +[ + { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, + { + "name": "Unauthorized", + "type": "error", + "inputs": [ + { "name": "sender", "type": "address", "internalType": "address" }, + { "name": "calledContract", "type": "address", "internalType": "address" }, + { "name": "methodSignature", "type": "string", "internalType": "string" } + ] + }, + { + "name": "FeedRegistryUpdated", + "type": "event", + "inputs": [ + { "name": "oldFeedRegistry", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newFeedRegistry", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x6d1006252b3dd171af76c28c184327bfddc39f439a50e0ac7f418c660b8894b5" + }, + { + "name": "Initialized", + "type": "event", + "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], + "anonymous": false, + "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" + }, + { + "name": "MaxStalePeriodAdded", + "type": "event", + "inputs": [ + { "name": "asset", "type": "string", "indexed": true, "internalType": "string" }, + { "name": "maxStalePeriod", "type": "uint256", "indexed": false, "internalType": "uint256" } + ], + "anonymous": false, + "signature": "0x37839d4a80c5e3f2578f59515c911ee8cce42383d7ebaa1c92afcde9871c4b58" + }, + { + "name": "NewAccessControlManager", + "type": "event", + "inputs": [ + { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, + { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" + }, + { + "name": "OwnershipTransferStarted", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" + }, + { + "name": "OwnershipTransferred", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" + }, + { + "name": "SymbolOverridden", + "type": "event", + "inputs": [ + { "name": "symbol", "type": "string", "indexed": true, "internalType": "string" }, + { "name": "overriddenSymbol", "type": "string", "indexed": false, "internalType": "string" } + ], + "anonymous": false, + "signature": "0xceb1f47aa91b96f02ea70e1deed25fe154ad1885aea509bd7222f9eec0a0bda5" + }, + { + "name": "BNB_ADDR", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x3e83b6b8", + "stateMutability": "view" + }, + { + "name": "acceptOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x79ba5097", + "stateMutability": "nonpayable" + }, + { + "name": "accessControlManager", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "contract IAccessControlManagerV8" + } + ], + "constant": true, + "signature": "0xb4a0bdf3", + "stateMutability": "view" + }, + { + "name": "feedRegistryAddress", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x011d3962", + "stateMutability": "view" + }, + { + "name": "getFeedRegistryAddress", + "type": "function", + "inputs": [], + "outputs": [{ "name": "", "type": "address", "internalType": "address" }], + "constant": true, + "signature": "0x99fe040e", + "stateMutability": "view" + }, + { + "name": "getPrice", + "type": "function", + "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], + "outputs": [{ "name": "", "type": "uint256", "internalType": "uint256" }], + "constant": true, + "signature": "0x41976e09", + "stateMutability": "view" + }, + { + "name": "initialize", + "type": "function", + "inputs": [ + { "name": "_sidRegistryAddress", "type": "address", "internalType": "address" }, + { "name": "_accessControlManager", "type": "address", "internalType": "address" } + ], + "outputs": [], + "signature": "0x485cc955", + "stateMutability": "nonpayable" + }, + { + "name": "maxStalePeriod", + "type": "function", + "inputs": [{ "name": "", "type": "string", "internalType": "string" }], + "outputs": [{ "name": "", "type": "uint256", "internalType": "uint256" }], + "constant": true, + "signature": "0xfdfbc277", + "stateMutability": "view" + }, + { + "name": "owner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x8da5cb5b", + "stateMutability": "view" + }, + { + "name": "pendingOwner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0xe30c3978", + "stateMutability": "view" + }, + { + "name": "renounceOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x715018a6", + "stateMutability": "nonpayable" + }, + { + "name": "setAccessControlManager", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0x0e32cb86", + "stateMutability": "nonpayable" + }, + { + "name": "setFeedRegistryAddress", + "type": "function", + "inputs": [{ "name": "newfeedRegistryAddress", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0x255ce37a", + "stateMutability": "nonpayable" + }, + { + "name": "setMaxStalePeriod", + "type": "function", + "inputs": [ + { "name": "symbol", "type": "string", "internalType": "string" }, + { "name": "_maxStalePeriod", "type": "uint256", "internalType": "uint256" } + ], + "outputs": [], + "signature": "0x636b999a", + "stateMutability": "nonpayable" + }, + { + "name": "setSymbolOverride", + "type": "function", + "inputs": [ + { "name": "symbol", "type": "string", "internalType": "string" }, + { "name": "overrideSymbol", "type": "string", "internalType": "string" } + ], + "outputs": [], + "signature": "0x9eab1ad6", + "stateMutability": "nonpayable" + }, + { + "name": "sidRegistryAddress", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x475e7de5", + "stateMutability": "view" + }, + { + "name": "symbols", + "type": "function", + "inputs": [{ "name": "", "type": "string", "internalType": "string" }], + "outputs": [{ "name": "", "type": "string", "internalType": "string" }], + "constant": true, + "signature": "0x047a74b2", + "stateMutability": "view" + }, + { + "name": "transferOwnership", + "type": "function", + "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xf2fde38b", + "stateMutability": "nonpayable" + } +] diff --git a/simulations/vip-372/abi/boundValidator.json b/simulations/vip-372/abi/boundValidator.json new file mode 100644 index 000000000..d16c8fb08 --- /dev/null +++ b/simulations/vip-372/abi/boundValidator.json @@ -0,0 +1,498 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "previousAdmin", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAdmin", + "type": "address" + } + ], + "name": "AdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "beacon", + "type": "address" + } + ], + "name": "BeaconUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "implementation", + "type": "address" + } + ], + "name": "Upgraded", + "type": "event" + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "inputs": [], + "name": "admin", + "outputs": [ + { + "internalType": "address", + "name": "admin_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [ + { + "internalType": "address", + "name": "implementation_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + } + ], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "upgradeToAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "stateMutability": "payable", + "type": "receive" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "upperBound", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "lowerBound", + "type": "uint256" + } + ], + "name": "ValidateConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig", + "name": "config", + "type": "tuple" + } + ], + "name": "setValidateConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "setValidateConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "validateConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "reportedPrice", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "anchorPrice", + "type": "uint256" + } + ], + "name": "validatePriceWithAnchorPrice", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_logic", + "type": "address" + }, + { + "internalType": "address", + "name": "admin_", + "type": "address" + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes" + } + ], + "stateMutability": "payable", + "type": "constructor" + } +] diff --git a/simulations/vip-372/abi/chainlinkOracle.json b/simulations/vip-372/abi/chainlinkOracle.json new file mode 100644 index 000000000..cdd689acb --- /dev/null +++ b/simulations/vip-372/abi/chainlinkOracle.json @@ -0,0 +1,459 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "vBnbAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "previousPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "requestedPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newPriceMantissa", + "type": "uint256" + } + ], + "name": "PricePosted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManager", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "prices", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + } + ], + "name": "setDirectPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VBep20Interface", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "underlyingPriceMantissa", + "type": "uint256" + } + ], + "name": "setUnderlyingPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "tokenConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/resilientOracle.json b/simulations/vip-372/abi/resilientOracle.json new file mode 100644 index 000000000..35f52caa0 --- /dev/null +++ b/simulations/vip-372/abi/resilientOracle.json @@ -0,0 +1,640 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "nativeMarketAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + }, + { + "internalType": "contract BoundValidatorInterface", + "name": "_boundValidator", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "mainOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "pivotOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "fallbackOracle", + "type": "address" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [ + { + "internalType": "contract BoundValidatorInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "getOracle", + "outputs": [ + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "bool", + "name": "enabled", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/sFrxETHOracle.json b/simulations/vip-372/abi/sFrxETHOracle.json new file mode 100644 index 000000000..b461549ba --- /dev/null +++ b/simulations/vip-372/abi/sFrxETHOracle.json @@ -0,0 +1,148 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_sfrxEthFraxOracle", "type": "address" }, + { "internalType": "address", "name": "_sfrxETH", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "BadPriceData", "type": "error" }, + { "inputs": [], "name": "InvalidTokenAddress", "type": "error" }, + { "inputs": [], "name": "PriceDifferenceExceeded", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxAllowedPriceDifference", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxAllowedPriceDifference", "type": "uint256" } + ], + "name": "MaxAllowedPriceDifferenceUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "SFRXETH", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "SFRXETH_FRAX_ORACLE", + "outputs": [{ "internalType": "contract ISfrxEthFraxOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxAllowedPriceDifference", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" }], + "name": "setMaxAllowedPriceDifference", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/treasury.json b/simulations/vip-372/abi/treasury.json new file mode 100644 index 000000000..18aabb61a --- /dev/null +++ b/simulations/vip-372/abi/treasury.json @@ -0,0 +1,86 @@ +[ + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryNative", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryToken", + "type": "event" + }, + { "stateMutability": "payable", "type": "fallback" }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryNative", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "stateMutability": "payable", "type": "receive" } +] diff --git a/simulations/vip-372/abi/xvs.json b/simulations/vip-372/abi/xvs.json new file mode 100644 index 000000000..69092bb4a --- /dev/null +++ b/simulations/vip-372/abi/xvs.json @@ -0,0 +1,716 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "AccountBlacklisted", + "type": "error" + }, + { + "inputs": [], + "name": "AddressesMustDiffer", + "type": "error" + }, + { + "inputs": [], + "name": "MintLimitExceed", + "type": "error" + }, + { + "inputs": [], + "name": "MintedAmountExceed", + "type": "error" + }, + { + "inputs": [], + "name": "NewCapNotGreaterThanMintedTokens", + "type": "error" + }, + { + "inputs": [], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "value", + "type": "bool" + } + ], + "name": "BlacklistUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "MintCapChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitDecreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "source", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "destination", + "type": "address" + } + ], + "name": "MintedTokensMigrated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "address", + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + } + ], + "name": "isBlackListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "source_", + "type": "address" + }, + { + "internalType": "address", + "name": "destination_", + "type": "address" + } + ], + "name": "migrateMinterTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToCap", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToMintedAmount", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newAccessControlAddress_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "minter_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "setMintCap", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + }, + { + "internalType": "bool", + "name": "value_", + "type": "bool" + } + ], + "name": "updateBlacklist", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/xvsBridge.json b/simulations/vip-372/abi/xvsBridge.json new file mode 100644 index 000000000..4e4dc5152 --- /dev/null +++ b/simulations/vip-372/abi/xvsBridge.json @@ -0,0 +1,807 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress_", "type": "address" }, + { "internalType": "uint8", "name": "sharedDecimals_", "type": "uint8" }, + { "internalType": "address", "name": "lzEndpoint_", "type": "address" }, + { "internalType": "address", "name": "oracle_", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "balance", "type": "uint256" } + ], + "name": "InsufficientBalance", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "indexed": false, "internalType": "bytes32", "name": "_hash", "type": "bytes32" } + ], + "name": "CallOFTReceivedSuccess", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "srcChainId", "type": "uint16" }, + { "indexed": true, "internalType": "bytes", "name": "srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "nonce", "type": "uint64" } + ], + "name": "DropFailedMessage", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "innerToken", "type": "address" }], + "name": "InnerTokenAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "indexed": false, "internalType": "bytes", "name": "_payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "_reason", "type": "bytes" } + ], + "name": "MessageFailed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "_address", "type": "address" }], + "name": "NonContractAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldOracle", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOracle", "type": "address" } + ], + "name": "OracleChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "indexed": true, "internalType": "address", "name": "_to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "ReceiveFromChain", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "indexed": false, "internalType": "bytes32", "name": "_payloadHash", "type": "bytes32" } + ], + "name": "RetryMessageSuccess", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "indexed": true, "internalType": "address", "name": "_from", "type": "address" }, + { "indexed": true, "internalType": "bytes32", "name": "_toAddress", "type": "bytes32" }, + { "indexed": false, "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "SendToChain", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyReceiveLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxSingleReceiveTransactionLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxSingleTransactionLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint16", "name": "_type", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "_minDstGas", "type": "uint256" } + ], + "name": "SetMinDstGas", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "precrime", "type": "address" }], + "name": "SetPrecrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_path", "type": "bytes" } + ], + "name": "SetTrustedRemote", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "addr", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "isWhitelist", "type": "bool" } + ], + "name": "SetWhitelist", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }], + "name": "TrustedRemoteRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "bool", "name": "enabled", "type": "bool" }], + "name": "UpdateSendAndCallEnabled", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_PAYLOAD_SIZE_LIMIT", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NO_EXTRA_GAS", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "PT_SEND", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "PT_SEND_AND_CALL", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "internalType": "bytes32", "name": "_from", "type": "bytes32" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" }, + { "internalType": "bytes", "name": "_payload", "type": "bytes" }, + { "internalType": "uint256", "name": "_gasForCall", "type": "uint256" } + ], + "name": "callOnOFTReceived", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourReceiveWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourReceived", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourTransferred", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyReceiveLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxSingleReceiveTransactionLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxSingleTransactionLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "circulatingSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "", "type": "uint16" }, + { "internalType": "bytes", "name": "", "type": "bytes" }, + { "internalType": "uint64", "name": "", "type": "uint64" } + ], + "name": "creditedPackets", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "srcAddress_", "type": "bytes" }, + { "internalType": "uint64", "name": "nonce_", "type": "uint64" } + ], + "name": "dropFailedMessage", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "internalType": "bytes32", "name": "_toAddress", "type": "bytes32" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" }, + { "internalType": "bytes", "name": "_payload", "type": "bytes" }, + { "internalType": "uint64", "name": "_dstGasForCall", "type": "uint64" }, + { "internalType": "bool", "name": "_useZro", "type": "bool" }, + { "internalType": "bytes", "name": "_adapterParams", "type": "bytes" } + ], + "name": "estimateSendAndCallFee", + "outputs": [ + { "internalType": "uint256", "name": "nativeFee", "type": "uint256" }, + { "internalType": "uint256", "name": "zroFee", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "internalType": "bytes32", "name": "_toAddress", "type": "bytes32" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" }, + { "internalType": "bool", "name": "_useZro", "type": "bool" }, + { "internalType": "bytes", "name": "_adapterParams", "type": "bytes" } + ], + "name": "estimateSendFee", + "outputs": [ + { "internalType": "uint256", "name": "nativeFee", "type": "uint256" }, + { "internalType": "uint256", "name": "zroFee", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "", "type": "uint16" }, + { "internalType": "bytes", "name": "", "type": "bytes" }, + { "internalType": "uint64", "name": "", "type": "uint64" } + ], + "name": "failedMessages", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } + ], + "name": "forceResumeReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_version", "type": "uint16" }, + { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "_configType", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }], + "name": "getTrustedRemoteAddress", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "from_", "type": "address" }, + { "internalType": "uint16", "name": "dstChainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "isEligibleToSend", + "outputs": [ + { "internalType": "bool", "name": "eligibleToSend", "type": "bool" }, + { "internalType": "uint256", "name": "maxSingleTransactionLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "maxDailyLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInUsd", "type": "uint256" }, + { "internalType": "uint256", "name": "transferredInWindow", "type": "uint256" }, + { "internalType": "uint256", "name": "last24HourWindowStart", "type": "uint256" }, + { "internalType": "bool", "name": "isWhiteListedUser", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } + ], + "name": "isTrustedRemote", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "lzEndpoint", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "internalType": "bytes", "name": "_payload", "type": "bytes" } + ], + "name": "lzReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "", "type": "uint16" }, + { "internalType": "uint16", "name": "", "type": "uint16" } + ], + "name": "minDstGasLookup", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "internalType": "bytes", "name": "_payload", "type": "bytes" } + ], + "name": "nonblockingLzReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "payloadSizeLimitLookup", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "precrime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], + "name": "removeTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "internalType": "bytes", "name": "_payload", "type": "bytes" } + ], + "name": "retryMessage", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "from_", "type": "address" }, + { "internalType": "uint16", "name": "dstChainId_", "type": "uint16" }, + { "internalType": "bytes32", "name": "toAddress_", "type": "bytes32" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "uint64", "name": "dstGasForCall_", "type": "uint64" }, + { + "components": [ + { "internalType": "address payable", "name": "refundAddress", "type": "address" }, + { "internalType": "address", "name": "zroPaymentAddress", "type": "address" }, + { "internalType": "bytes", "name": "adapterParams", "type": "bytes" } + ], + "internalType": "struct ICommonOFT.LzCallParams", + "name": "callparams_", + "type": "tuple" + } + ], + "name": "sendAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [], + "name": "sendAndCallEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_from", "type": "address" }, + { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "internalType": "bytes32", "name": "_toAddress", "type": "bytes32" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" }, + { + "components": [ + { "internalType": "address payable", "name": "refundAddress", "type": "address" }, + { "internalType": "address", "name": "zroPaymentAddress", "type": "address" }, + { "internalType": "bytes", "name": "adapterParams", "type": "bytes" } + ], + "internalType": "struct ICommonOFT.LzCallParams", + "name": "_callParams", + "type": "tuple" + } + ], + "name": "sendFrom", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_version", "type": "uint16" }, + { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, + { "internalType": "uint256", "name": "_configType", "type": "uint256" }, + { "internalType": "bytes", "name": "_config", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyReceiveLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxSingleReceiveTransactionLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxSingleTransactionLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "internalType": "uint16", "name": "_packetType", "type": "uint16" }, + { "internalType": "uint256", "name": "_minGas", "type": "uint256" } + ], + "name": "setMinDstGas", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "oracleAddress_", "type": "address" }], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "internalType": "uint256", "name": "_size", "type": "uint256" } + ], + "name": "setPayloadSizeLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_precrime", "type": "address" }], + "name": "setPrecrime", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], + "name": "setReceiveVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_path", "type": "bytes" } + ], + "name": "setTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "user_", "type": "address" }, + { "internalType": "bool", "name": "val_", "type": "bool" } + ], + "name": "setWhitelist", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "sharedDecimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], + "name": "supportsInterface", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract IERC20", "name": "token_", "type": "address" }, + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "token", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "bool", "name": "enabled_", "type": "bool" }], + "name": "updateSendAndCallEnabled", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "whitelist", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/xvsBridgeAdmin.json b/simulations/vip-372/abi/xvsBridgeAdmin.json new file mode 100644 index 000000000..024450a40 --- /dev/null +++ b/simulations/vip-372/abi/xvsBridgeAdmin.json @@ -0,0 +1,329 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "XVSBridge_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "string", + "name": "signature", + "type": "string" + }, + { + "indexed": false, + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "name": "FunctionRegistryChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "stateMutability": "nonpayable", + "type": "fallback" + }, + { + "inputs": [], + "name": "XVSBridge", + "outputs": [ + { + "internalType": "contract IXVSProxyOFT", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "", + "type": "bytes4" + } + ], + "name": "functionRegistry", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "isTrustedRemote", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner_", + "type": "address" + } + ], + "name": "transferBridgeOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "string[]", + "name": "signatures_", + "type": "string[]" + }, + { + "internalType": "bool[]", + "name": "active_", + "type": "bool[]" + } + ], + "name": "upsertSignature", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-372/arbitrumone.ts b/simulations/vip-372/arbitrumone.ts new file mode 100644 index 000000000..449da53fe --- /dev/null +++ b/simulations/vip-372/arbitrumone.ts @@ -0,0 +1,58 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip014 from "../../multisig/proposals/arbitrumone/vip-014"; +import vip372, { ARBITRUM_ONE_BOUND_VALIDATOR, ARBITRUM_XVS_BRIDGE_ADMIN } from "../../vips/vip-372/bscmainnet"; +import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; +import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; +import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; +import TREASURY_ABI from "./abi/treasury.json"; +import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; + +const XVS_BRIDGE = "0x20cEa49B5F7a6DBD78cAE772CA5973eF360AA1e6"; +const { arbitrumone } = NETWORK_ADDRESSES; + +forking(230362555, async () => { + const provider = ethers.provider; + let chainLinkOracle: Contract; + let redstoneOracle: Contract; + let resilientOracle: Contract; + let boundValidator: Contract; + let treasury: Contract; + let xvsBridgeAdmin: Contract; + let xvsBridge: Contract; + before(async () => { + chainLinkOracle = new ethers.Contract(arbitrumone.CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); + redstoneOracle = new ethers.Contract(arbitrumone.REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); + resilientOracle = new ethers.Contract(arbitrumone.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); + boundValidator = new ethers.Contract(ARBITRUM_ONE_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); + treasury = await ethers.getContractAt(TREASURY_ABI, arbitrumone.VTREASURY); + xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, ARBITRUM_XVS_BRIDGE_ADMIN); + xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); + await pretendExecutingVip(await vip014()); + }); + + testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip372()); + + describe("Post-VIP behaviour", async () => { + it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { + expect(await xvsBridgeAdmin.owner()).to.be.equals(arbitrumone.NORMAL_TIMELOCK); + }); + it("Normal Timelock should be whitelisted", async () => { + expect(await xvsBridge.whitelist(arbitrumone.NORMAL_TIMELOCK)).to.be.true; + }); + it("oracles should have correct owner", async () => { + expect(await resilientOracle.owner()).equals(arbitrumone.NORMAL_TIMELOCK); + expect(await chainLinkOracle.owner()).equals(arbitrumone.NORMAL_TIMELOCK); + expect(await redstoneOracle.owner()).equals(arbitrumone.NORMAL_TIMELOCK); + expect(await boundValidator.owner()).equals(arbitrumone.NORMAL_TIMELOCK); + }); + it("Normal Timelock should be the owner of the Vtreasury", async () => { + expect(await treasury.owner()).equals(arbitrumone.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/simulations/vip-372/arbitrumsepolia.ts b/simulations/vip-372/arbitrumsepolia.ts new file mode 100644 index 000000000..50bc99e79 --- /dev/null +++ b/simulations/vip-372/arbitrumsepolia.ts @@ -0,0 +1,62 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip014 from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import vip372, { + ARBITRUM_SEPOLIA_BOUND_VALIDATOR, + ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN, +} from "../../vips/vip-372/bsctestnet"; +import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; +import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; +import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; +import TREASURY_ABI from "./abi/treasury.json"; +import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; + +const XVS_BRIDGE = "0xFdC5cEC63FD167DA46cF006585b30D03B104eFD4"; +const { arbitrumsepolia } = NETWORK_ADDRESSES; + +forking(62418214, async () => { + const provider = ethers.provider; + let chainLinkOracle: Contract; + let redstoneOracle: Contract; + let resilientOracle: Contract; + let boundValidator: Contract; + let xvsBridgeAdmin: Contract; + let xvsBridge: Contract; + let treasury: Contract; + before(async () => { + chainLinkOracle = new ethers.Contract(arbitrumsepolia.CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); + redstoneOracle = new ethers.Contract(arbitrumsepolia.REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); + resilientOracle = new ethers.Contract(arbitrumsepolia.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); + boundValidator = new ethers.Contract(ARBITRUM_SEPOLIA_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); + xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN); + xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); + treasury = await ethers.getContractAt(TREASURY_ABI, arbitrumsepolia.VTREASURY); + + await pretendExecutingVip(await vip014()); + }); + + testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip372()); + + describe("Post-VIP behaviour", async () => { + it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { + expect(await xvsBridgeAdmin.owner()).to.be.equals(arbitrumsepolia.NORMAL_TIMELOCK); + }); + it("Normal Timelock should be whitelisted", async () => { + expect(await xvsBridge.whitelist(arbitrumsepolia.NORMAL_TIMELOCK)).to.be.true; + }); + it("oracles should have correct owner", async () => { + expect(await resilientOracle.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); + expect(await chainLinkOracle.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); + expect(await redstoneOracle.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); + expect(await boundValidator.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); + }); + it("Normal Timelock should be the owner of the Vtreasury", async () => { + expect(await treasury.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/simulations/vip-372/ethereum.ts b/simulations/vip-372/ethereum.ts new file mode 100644 index 000000000..449ea8ec3 --- /dev/null +++ b/simulations/vip-372/ethereum.ts @@ -0,0 +1,66 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip061 from "../../multisig/proposals/ethereum/vip-061"; +import vip372, { + ETHEREUM_BOUND_VALIDATOR, + ETHEREUM_XVS_BRIDGE_ADMIN, + ETHEREUM_sFrxETH_ORACLE, +} from "../../vips/vip-372/bscmainnet"; +import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; +import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; +import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; +import SFRAXETH_ORACLE_ABI from "./abi/sFrxETHOracle.json"; +import TREASURY_ABI from "./abi/treasury.json"; +import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; + +const XVS_BRIDGE = "0x888E317606b4c590BBAD88653863e8B345702633"; +const { ethereum } = NETWORK_ADDRESSES; + +forking(20274111, async () => { + const provider = ethers.provider; + let xvsBridgeAdmin: Contract; + let xvsBridge: Contract; + let chainLinkOracle: Contract; + let redstoneOracle: Contract; + let resilientOracle: Contract; + let boundValidator: Contract; + let sfraxETH: Contract; + let treasury: Contract; + before(async () => { + xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, ETHEREUM_XVS_BRIDGE_ADMIN); + xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); + chainLinkOracle = new ethers.Contract(ethereum.CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); + redstoneOracle = new ethers.Contract(ethereum.REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); + resilientOracle = new ethers.Contract(ethereum.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); + boundValidator = new ethers.Contract(ETHEREUM_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); + sfraxETH = new ethers.Contract(ETHEREUM_sFrxETH_ORACLE, SFRAXETH_ORACLE_ABI, provider); + treasury = await ethers.getContractAt(TREASURY_ABI, ethereum.VTREASURY); + await pretendExecutingVip(await vip061()); + }); + + testForkedNetworkVipCommands("vip372", await vip372()); + + describe("Post-VIP behaviour", async () => { + it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { + expect(await xvsBridgeAdmin.owner()).to.be.equals(ethereum.NORMAL_TIMELOCK); + }); + it("Normal Timelock should be whitelisted", async () => { + expect(await xvsBridge.whitelist(ethereum.NORMAL_TIMELOCK)).to.be.true; + }); + it("oracles should have correct owner", async () => { + expect(await resilientOracle.owner()).equals(ethereum.NORMAL_TIMELOCK); + expect(await chainLinkOracle.owner()).equals(ethereum.NORMAL_TIMELOCK); + expect(await redstoneOracle.owner()).equals(ethereum.NORMAL_TIMELOCK); + expect(await boundValidator.owner()).equals(ethereum.NORMAL_TIMELOCK); + expect(await sfraxETH.owner()).equals(ethereum.NORMAL_TIMELOCK); + }); + it("Normal Timelock should be the owner of the Vtreasury", async () => { + expect(await treasury.owner()).equals(ethereum.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/simulations/vip-372/opbnbmainnet.ts b/simulations/vip-372/opbnbmainnet.ts new file mode 100644 index 000000000..399028fa7 --- /dev/null +++ b/simulations/vip-372/opbnbmainnet.ts @@ -0,0 +1,58 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip021 from "../../multisig/proposals/opbnbmainnet/vip-021"; +import vip372, { OPBNBMAINNET_BOUND_VALIDATOR, OPBNBMAINNET_XVS_BRIDGE_ADMIN } from "../../vips/vip-372/bscmainnet"; +import BINANCE_ORACLE_API from "./abi/binanceOracle.json"; +import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; +import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; +import TREASURY_ABI from "./abi/treasury.json"; +import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; + +const XVS_BRIDGE = "0x100D331C1B5Dcd41eACB1eCeD0e83DCEbf3498B2"; +const { opbnbmainnet } = NETWORK_ADDRESSES; + +forking(28761242, async () => { + const provider = ethers.provider; + let binanceOracle: Contract; + let resilientOracle: Contract; + let boundValidator: Contract; + let treasury: Contract; + let xvsBridgeAdmin: Contract; + let xvsBridge: Contract; + + before(async () => { + binanceOracle = new ethers.Contract(opbnbmainnet.BINANCE_ORACLE, BINANCE_ORACLE_API, provider); + resilientOracle = new ethers.Contract(opbnbmainnet.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); + boundValidator = new ethers.Contract(OPBNBMAINNET_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); + xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, OPBNBMAINNET_XVS_BRIDGE_ADMIN); + xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); + treasury = await ethers.getContractAt(TREASURY_ABI, opbnbmainnet.VTREASURY); + await pretendExecutingVip(await vip021()); + }); + + testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip372()); + + describe("Post-VIP behaviour", async () => { + it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { + expect(await xvsBridgeAdmin.owner()).to.be.equals(opbnbmainnet.NORMAL_TIMELOCK); + }); + it("Normal Timelock should be whitelisted", async () => { + expect(await xvsBridge.whitelist(opbnbmainnet.NORMAL_TIMELOCK)).to.be.true; + }); + + it("oracles should have correct owner", async () => { + expect(await resilientOracle.owner()).equals(opbnbmainnet.NORMAL_TIMELOCK); + expect(await binanceOracle.owner()).equals(opbnbmainnet.NORMAL_TIMELOCK); + expect(await boundValidator.owner()).equals(opbnbmainnet.NORMAL_TIMELOCK); + }); + + it("Normal Timelock should be the owner of the Vtreasury", async () => { + expect(await treasury.owner()).equals(opbnbmainnet.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/simulations/vip-372/opbnbtestnet.ts b/simulations/vip-372/opbnbtestnet.ts new file mode 100644 index 000000000..129194e64 --- /dev/null +++ b/simulations/vip-372/opbnbtestnet.ts @@ -0,0 +1,55 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip021 from "../../multisig/proposals/opbnbtestnet/vip-021"; +import vip372, { OPBNBTESTNET_BOUND_VALIDATOR, OPBNBTESTNET_XVS_BRIDGE_ADMIN } from "../../vips/vip-372/bsctestnet"; +import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; +import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; +import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; +import TREASURY_ABI from "./abi/treasury.json"; +import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; + +const XVS_BRIDGE = "0xA03205bC635A772E533E7BE36b5701E331a70ea3"; +const { opbnbtestnet } = NETWORK_ADDRESSES; + +forking(33739110, async () => { + const provider = ethers.provider; + let binanceOracle: Contract; + let resilientOracle: Contract; + let boundValidator: Contract; + let treasury: Contract; + let xvsBridgeAdmin: Contract; + let xvsBridge: Contract; + before(async () => { + binanceOracle = new ethers.Contract(opbnbtestnet.BINANCE_ORACLE, CHAINLINK_ORACLE_ABI, provider); + resilientOracle = new ethers.Contract(opbnbtestnet.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); + boundValidator = new ethers.Contract(OPBNBTESTNET_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); + xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, OPBNBTESTNET_XVS_BRIDGE_ADMIN); + xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); + treasury = await ethers.getContractAt(TREASURY_ABI, opbnbtestnet.VTREASURY); + await pretendExecutingVip(await vip021()); + }); + + testForkedNetworkVipCommands("vip372", await vip372()); + + describe("Post-VIP behaviour", async () => { + it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { + expect(await xvsBridgeAdmin.owner()).to.be.equals(opbnbtestnet.NORMAL_TIMELOCK); + }); + it("Normal Timelock should be whitelisted", async () => { + expect(await xvsBridge.whitelist(opbnbtestnet.NORMAL_TIMELOCK)).to.be.true; + }); + it("oracles should have correct owner", async () => { + expect(await resilientOracle.owner()).equals(opbnbtestnet.NORMAL_TIMELOCK); + expect(await binanceOracle.owner()).equals(opbnbtestnet.NORMAL_TIMELOCK); + expect(await boundValidator.owner()).equals(opbnbtestnet.NORMAL_TIMELOCK); + }); + it("Normal Timelock should be the owner of the Vtreasury", async () => { + expect(await treasury.owner()).equals(opbnbtestnet.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/simulations/vip-372/sepolia.ts b/simulations/vip-372/sepolia.ts new file mode 100644 index 000000000..9995c671c --- /dev/null +++ b/simulations/vip-372/sepolia.ts @@ -0,0 +1,65 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip060 from "../../multisig/proposals/sepolia/vip-060"; +import vip372, { + SEPOLIA_BOUND_VALIDATOR, + SEPOLIA_XVS_BRIDGE_ADMIN, + SEPOLIA_sFrxETH_ORACLE, +} from "../../vips/vip-372/bsctestnet"; +import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; +import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; +import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; +import SFRAXETH_ORACLE_ABI from "./abi/sFrxETHOracle.json"; +import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; + +const XVS_BRIDGE = "0xc340b7d3406502F43dC11a988E4EC5bbE536E642"; +const { sepolia } = NETWORK_ADDRESSES; + +forking(6276156, async () => { + const provider = ethers.provider; + let chainLinkOracle: Contract; + let redstoneOracle: Contract; + let resilientOracle: Contract; + let boundValidator: Contract; + let sfraxETH: Contract; + + before(async () => { + chainLinkOracle = new ethers.Contract(sepolia.CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); + redstoneOracle = new ethers.Contract(sepolia.REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); + resilientOracle = new ethers.Contract(sepolia.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); + boundValidator = new ethers.Contract(SEPOLIA_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); + sfraxETH = new ethers.Contract(SEPOLIA_sFrxETH_ORACLE, SFRAXETH_ORACLE_ABI, provider); + + await pretendExecutingVip(await vip060()); + }); + + testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip372()); + + describe("Post-VIP behaviour", async () => { + let xvsBridgeAdmin: Contract; + let xvsBridge: Contract; + + before(async () => { + xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, SEPOLIA_XVS_BRIDGE_ADMIN); + xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); + }); + it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { + expect(await xvsBridgeAdmin.owner()).to.be.equals(sepolia.NORMAL_TIMELOCK); + }); + it("Normal Timelock should be whitelisted", async () => { + expect(await xvsBridge.whitelist(sepolia.NORMAL_TIMELOCK)).to.be.true; + }); + it("oracles should have correct owner", async () => { + expect(await resilientOracle.owner()).equals(sepolia.NORMAL_TIMELOCK); + expect(await chainLinkOracle.owner()).equals(sepolia.NORMAL_TIMELOCK); + expect(await redstoneOracle.owner()).equals(sepolia.NORMAL_TIMELOCK); + expect(await boundValidator.owner()).equals(sepolia.NORMAL_TIMELOCK); + expect(await sfraxETH.owner()).equals(sepolia.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/vips/vip-371/bscmainnet.ts b/vips/vip-371/bscmainnet.ts index 568caad1b..12d539b44 100644 --- a/vips/vip-371/bscmainnet.ts +++ b/vips/vip-371/bscmainnet.ts @@ -20,31 +20,6 @@ import { VTOKENS as OPBNBMAINNET_VTOKENS } from "../../multisig/proposals/opbnbm import { POOL_REGISTRY as OPBNBMAINNET_POOL_REGISTRY } from "../../multisig/proposals/opbnbmainnet/vip-021"; import { PSR as OPBNBMAINNET_PSR } from "../../multisig/proposals/opbnbmainnet/vip-021"; -export const ETHEREUM_ACM = "0x230058da2D23eb8836EC5DB7037ef7250c56E25E"; -export const ARBITRUMONE_ACM = "0xD9dD18EB0cf10CbA837677f28A8F9Bda4bc2b157"; -export const OPBNBMAINNET_ACM = "0xA60Deae5344F1152426cA440fb6552eA0e3005D6"; - -export const ARBITRUM_ONE_FASTTRACK_TIMELOCK = "0x2286a9B2a5246218f2fC1F380383f45BDfCE3E04"; -export const ETHEREUM_FASTTRACK_TIMELOCK = "0x8764F50616B62a99A997876C2DEAaa04554C5B2E"; -export const OPBNBMAINNET_FASTTRACK_TIMELOCK = "0xEdD04Ecef0850e834833789576A1d435e7207C0d"; - -export const ARBITRUM_ONE_CRITICAL_TIMELOCK = "0x181E4f8F21D087bF02Ea2F64D5e550849FBca674"; -export const ETHEREUM_CRITICAL_TIMELOCK = "0xeB9b85342c34F65af734C7bd4a149c86c472bC00"; -export const OPBNBMAINNET_CRITICAL_TIMELOCK = "0xA7DD2b15B24377296F11c702e758cd9141AB34AA"; - -export const ARBITRUM_ONE_XVS_STORE = "0x507D9923c954AAD8eC530ed8Dedb75bFc893Ec5e"; -export const ETHEREUM_XVS_STORE = "0x1Db646E1Ab05571AF99e47e8F909801e5C99d37B"; -export const OPBNBMAINNET_XVS_STORE = "0xc3279442a5aCaCF0A2EcB015d1cDDBb3E0f3F775"; - -export const ETHEREUM_XVS_BRIDGE_ADMIN = "0x9C6C95632A8FB3A74f2fB4B7FfC50B003c992b96"; -export const OPBNBMAINNET_XVS_BRIDGE_ADMIN = "0x52fcE05aDbf6103d71ed2BA8Be7A317282731831"; -export const ARBITRUM_XVS_BRIDGE_ADMIN = "0xf5d81C6F7DAA3F97A6265C8441f92eFda22Ad784"; - -export const ARBITRUM_ONE_BOUND_VALIDATOR = "0x2245FA2420925Cd3C2D889Ddc5bA1aefEF0E14CF"; -export const ETHEREUM_BOUND_VALIDATOR = "0x1Cd5f336A1d28Dff445619CC63d3A0329B4d8a58"; -export const OPBNBMAINNET_BOUND_VALIDATOR = "0xd1f80C371C6E2Fa395A5574DB3E3b4dAf43dadCE"; -export const ETHEREUM_sFrxETH_ORACLE = "0x5E06A5f48692E4Fff376fDfCA9E4C0183AAADCD1"; - const vip371 = () => { const meta = { version: "v2", diff --git a/vips/vip-371/bsctestnet.ts b/vips/vip-371/bsctestnet.ts index 2e1fae7fc..4f6c0d852 100644 --- a/vips/vip-371/bsctestnet.ts +++ b/vips/vip-371/bsctestnet.ts @@ -23,25 +23,6 @@ import { COMPTROLLERS as SEPOLIA_COMPTROLLERS } from "../../multisig/proposals/s import { VTOKENS as SEPOLIA_VTOKENS } from "../../multisig/proposals/sepolia/vip-060"; import { POOL_REGISTRY as SEPOLIA_POOL_REGISTRY } from "../../multisig/proposals/sepolia/vip-060"; -export const SEPOLIA_ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; -export const SEPOLIA_FASTTRACK_TIMELOCK = "0x7F043F43Adb392072a3Ba0cC9c96e894C6f7e182"; -export const SEPOLIA_CRITICAL_TIMELOCK = "0xA24A7A65b8968a749841988Bd7d05F6a94329fDe"; -export const ARBITRUM_SEPOLIA_ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; -export const OPBNBTESTNET_ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; - -export const ARBITRUM_SEPOLIA_XVS_STORE = "0x4e909DA6693215dC630104715c035B159dDb67Dd"; -export const SEPOLIA_XVS_STORE = "0x03B868C7858F50900fecE4eBc851199e957b5d3D"; -export const OPBNBTESTNET_XVS_STORE = "0x06473fB3f7bF11e2E8EfEcC95aC55ABEFCb2e0A0"; - -export const SEPOLIA_XVS_BRIDGE_ADMIN = "0xd3c6bdeeadB2359F726aD4cF42EAa8B7102DAd9B"; -export const OPBNBTESTNET_XVS_BRIDGE_ADMIN = "0x19252AFD0B2F539C400aEab7d460CBFbf74c17ff"; -export const ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN = "0xc94578caCC89a29B044a0a1D54d20d48A645E5C8"; - -export const ARBITRUM_SEPOLIA_BOUND_VALIDATOR = "0xfe6bc1545Cc14C131bacA97476D6035ffcC0b889"; -export const SEPOLIA_BOUND_VALIDATOR = "0x60c4Aa92eEb6884a76b309Dd8B3731ad514d6f9B"; -export const OPBNBTESTNET_BOUND_VALIDATOR = "0x049537Bb065e6253e9D8D08B45Bf6b753657A746"; -export const SEPOLIA_sFrxETH_ORACLE = "0x61EB836afA467677e6b403D504fe69D6940e7996"; - const vip352 = () => { const meta = { version: "v2", diff --git a/vips/vip-372/bscmainnet.ts b/vips/vip-372/bscmainnet.ts index fa912457d..77d067ab0 100644 --- a/vips/vip-372/bscmainnet.ts +++ b/vips/vip-372/bscmainnet.ts @@ -2,18 +2,6 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { LzChainId, ProposalType } from "src/types"; import { makeProposal } from "src/utils"; -export const ETHEREUM_ACM = "0x230058da2D23eb8836EC5DB7037ef7250c56E25E"; -export const ARBITRUMONE_ACM = "0xD9dD18EB0cf10CbA837677f28A8F9Bda4bc2b157"; -export const OPBNBMAINNET_ACM = "0xA60Deae5344F1152426cA440fb6552eA0e3005D6"; - -export const ARBITRUM_ONE_FASTTRACK_TIMELOCK = "0x2286a9B2a5246218f2fC1F380383f45BDfCE3E04"; -export const ETHEREUM_FASTTRACK_TIMELOCK = "0x8764F50616B62a99A997876C2DEAaa04554C5B2E"; -export const OPBNBMAINNET_FASTTRACK_TIMELOCK = "0xEdD04Ecef0850e834833789576A1d435e7207C0d"; - -export const ARBITRUM_ONE_CRITICAL_TIMELOCK = "0x181E4f8F21D087bF02Ea2F64D5e550849FBca674"; -export const ETHEREUM_CRITICAL_TIMELOCK = "0xeB9b85342c34F65af734C7bd4a149c86c472bC00"; -export const OPBNBMAINNET_CRITICAL_TIMELOCK = "0xA7DD2b15B24377296F11c702e758cd9141AB34AA"; - export const ARBITRUM_ONE_XVS_STORE = "0x507D9923c954AAD8eC530ed8Dedb75bFc893Ec5e"; export const ETHEREUM_XVS_STORE = "0x1Db646E1Ab05571AF99e47e8F909801e5C99d37B"; export const OPBNBMAINNET_XVS_STORE = "0xc3279442a5aCaCF0A2EcB015d1cDDBb3E0f3F775"; From 6fee4ba803279817c49a63f97faada171781c367 Mon Sep 17 00:00:00 2001 From: Narayan Prusty Date: Sun, 29 Sep 2024 21:38:18 +0400 Subject: [PATCH 007/178] fix: added default role for normal timelock --- multisig/proposals/arbitrumone/vip-014/index.ts | 7 +++++++ multisig/proposals/arbitrumsepolia/vip-014/index.ts | 7 +++++++ multisig/proposals/ethereum/vip-061/index.ts | 8 ++++++++ multisig/proposals/opbnbmainnet/vip-021/index.ts | 7 +++++++ multisig/proposals/opbnbtestnet/vip-021/index.ts | 7 +++++++ multisig/proposals/sepolia/vip-060/index.ts | 7 +++++++ 6 files changed, 43 insertions(+) diff --git a/multisig/proposals/arbitrumone/vip-014/index.ts b/multisig/proposals/arbitrumone/vip-014/index.ts index 72a1e273a..56d6e85bd 100644 --- a/multisig/proposals/arbitrumone/vip-014/index.ts +++ b/multisig/proposals/arbitrumone/vip-014/index.ts @@ -26,6 +26,8 @@ export const VTOKENS = [ "0xAeB0FEd69354f34831fe1D16475D9A83ddaCaDA6", ]; +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + const vip014 = () => { return makeProposal([ { @@ -129,6 +131,11 @@ const vip014 = () => { signature: "transferOwnership(address)", params: [arbitrumone.NORMAL_TIMELOCK], }, + { + target: ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, arbitrumone.NORMAL_TIMELOCK], + }, ]); }; diff --git a/multisig/proposals/arbitrumsepolia/vip-014/index.ts b/multisig/proposals/arbitrumsepolia/vip-014/index.ts index 5b2de90f6..47e2e2163 100644 --- a/multisig/proposals/arbitrumsepolia/vip-014/index.ts +++ b/multisig/proposals/arbitrumsepolia/vip-014/index.ts @@ -26,6 +26,8 @@ export const VTOKENS = [ ]; export const BOUND_VALIDATOR = "0xfe6bc1545Cc14C131bacA97476D6035ffcC0b889"; +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + const vip014 = () => { return makeProposal([ { @@ -129,6 +131,11 @@ const vip014 = () => { signature: "transferOwnership(address)", params: [arbitrumsepolia.NORMAL_TIMELOCK], }, + { + target: ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, arbitrumsepolia.NORMAL_TIMELOCK], + }, ]); }; diff --git a/multisig/proposals/ethereum/vip-061/index.ts b/multisig/proposals/ethereum/vip-061/index.ts index 518851abc..a6c00d6f8 100644 --- a/multisig/proposals/ethereum/vip-061/index.ts +++ b/multisig/proposals/ethereum/vip-061/index.ts @@ -32,6 +32,7 @@ export const COMPTROLLER_BEACON = "0xAE2C3F21896c02510aA187BdA0791cDA77083708"; export const VTOKEN_BEACON = "0xfc08aADC7a1A93857f6296C3fb78aBA1d286533a"; export const ETHEREUM_ACM = "0x230058da2D23eb8836EC5DB7037ef7250c56E25E"; export const POOL_REGISTRY = "0x61CAff113CCaf05FFc6540302c37adcf077C5179"; +export const ACM = "0x230058da2D23eb8836EC5DB7037ef7250c56E25E"; export const COMPTROLLERS = [ "0x687a01ecF6d3907658f7A7c714749fAC32336D1B", @@ -65,6 +66,8 @@ export const XVS = "0xd3CC9d8f3689B83c91b7B59cAB4946B063EB894A"; export const BOUND_VALIDATOR = "0x1Cd5f336A1d28Dff445619CC63d3A0329B4d8a58"; export const SFrxETHOracle = "0x5E06A5f48692E4Fff376fDfCA9E4C0183AAADCD1"; +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + const vip061 = () => { return makeProposal([ { @@ -190,6 +193,11 @@ const vip061 = () => { signature: "transferOwnership(address)", params: [ethereum.NORMAL_TIMELOCK], }, + { + target: ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ethereum.NORMAL_TIMELOCK], + }, ]); }; diff --git a/multisig/proposals/opbnbmainnet/vip-021/index.ts b/multisig/proposals/opbnbmainnet/vip-021/index.ts index 6d84d9708..15087d41d 100644 --- a/multisig/proposals/opbnbmainnet/vip-021/index.ts +++ b/multisig/proposals/opbnbmainnet/vip-021/index.ts @@ -23,6 +23,8 @@ export const XVS_BRIDGE_ADMIN_PROXY = "0x52fcE05aDbf6103d71ed2BA8Be7A31728273183 export const XVS = "0x3E2e61F1c075881F3fB8dd568043d8c221fd5c61"; export const BOUND_VALIDATOR = "0xd1f80C371C6E2Fa395A5574DB3E3b4dAf43dadCE"; +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + const vip021 = () => { return makeProposal([ { @@ -104,6 +106,11 @@ const vip021 = () => { signature: "transferOwnership(address)", params: [opbnbmainnet.NORMAL_TIMELOCK], }, + { + target: ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, opbnbmainnet.NORMAL_TIMELOCK], + }, ]); }; diff --git a/multisig/proposals/opbnbtestnet/vip-021/index.ts b/multisig/proposals/opbnbtestnet/vip-021/index.ts index f476b6ed7..7ed329d64 100644 --- a/multisig/proposals/opbnbtestnet/vip-021/index.ts +++ b/multisig/proposals/opbnbtestnet/vip-021/index.ts @@ -22,6 +22,8 @@ export const XVS_BRIDGE_ADMIN_PROXY = "0x19252AFD0B2F539C400aEab7d460CBFbf74c17f export const XVS = "0xc2931B1fEa69b6D6dA65a50363A8D75d285e4da9"; export const BOUND_VALIDATOR = "0x049537Bb065e6253e9D8D08B45Bf6b753657A746"; +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + const vip021 = () => { return makeProposal([ { @@ -103,6 +105,11 @@ const vip021 = () => { signature: "transferOwnership(address)", params: [opbnbtestnet.NORMAL_TIMELOCK], }, + { + target: ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, opbnbtestnet.NORMAL_TIMELOCK], + }, ]); }; diff --git a/multisig/proposals/sepolia/vip-060/index.ts b/multisig/proposals/sepolia/vip-060/index.ts index 0cc438000..b79cdc5de 100644 --- a/multisig/proposals/sepolia/vip-060/index.ts +++ b/multisig/proposals/sepolia/vip-060/index.ts @@ -62,6 +62,8 @@ export const XVS = "0x66ebd019E86e0af5f228a0439EBB33f045CBe63E"; export const BOUND_VALIDATOR = "0x60c4Aa92eEb6884a76b309Dd8B3731ad514d6f9B"; export const SFrxETHOracle = "0x61EB836afA467677e6b403D504fe69D6940e7996"; +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + const vip060 = () => { return makeProposal([ { @@ -182,6 +184,11 @@ const vip060 = () => { signature: "transferOwnership(address)", params: [sepolia.NORMAL_TIMELOCK], }, + { + target: ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, sepolia.NORMAL_TIMELOCK], + }, ]); }; From dc11c01fe6e026027dcbdd75a6ac1fcb3f251352 Mon Sep 17 00:00:00 2001 From: Narayan Prusty Date: Thu, 3 Oct 2024 16:24:15 +0400 Subject: [PATCH 008/178] fix: added vip to grant and revoke permissions in arbitrum sepolia --- .../vip-373/abi/AccessControlManager.json | 157 ++++++++++++++++++ simulations/vip-373/arbitrumsepolia.ts | 19 +++ vips/vip-373/bsctestnet.ts | 52 ++++++ 3 files changed, 228 insertions(+) create mode 100644 simulations/vip-373/abi/AccessControlManager.json create mode 100644 simulations/vip-373/arbitrumsepolia.ts create mode 100644 vips/vip-373/bsctestnet.ts diff --git a/simulations/vip-373/abi/AccessControlManager.json b/simulations/vip-373/abi/AccessControlManager.json new file mode 100644 index 000000000..2ef119947 --- /dev/null +++ b/simulations/vip-373/abi/AccessControlManager.json @@ -0,0 +1,157 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } + ], + "name": "RoleAdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleRevoked", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_ADMIN_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleAdmin", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToPermit", "type": "address" } + ], + "name": "giveCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "grantRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "hasPermission", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "hasRole", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "isAllowedToCall", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "renounceRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToRevoke", "type": "address" } + ], + "name": "revokeCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "revokeRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], + "name": "supportsInterface", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-373/arbitrumsepolia.ts b/simulations/vip-373/arbitrumsepolia.ts new file mode 100644 index 000000000..956ac70f1 --- /dev/null +++ b/simulations/vip-373/arbitrumsepolia.ts @@ -0,0 +1,19 @@ +import { expectEvents } from "src/utils"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip014 from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import vip373 from "../../vips/vip-373/bsctestnet"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; + +forking(85791092, async () => { + before(async () => { + await pretendExecutingVip(await vip014()); + }); + + testForkedNetworkVipCommands("vip373", await vip373(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [84]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [35]); + }, + }); +}); diff --git a/vips/vip-373/bsctestnet.ts b/vips/vip-373/bsctestnet.ts new file mode 100644 index 000000000..fbf39393a --- /dev/null +++ b/vips/vip-373/bsctestnet.ts @@ -0,0 +1,52 @@ +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const SEPOLIA_ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; +export const ARBITRUM_SEPOLIA_ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; +export const OPBNBTESTNET_ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; + +export const ARBITRUMSEPOLIA_ACM_AGGREGATOR = "0x4fCbfE445396f31005b3Fd2F6DE2A986d6E2dCB5"; + +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + +const vip372 = () => { + const meta = { + version: "v2", + title: "VIP-332 accept ownership & give permissions to Normal Timelock", + description: `### Description`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: ARBITRUM_SEPOLIA_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ARBITRUMSEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ARBITRUMSEPOLIA_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ARBITRUMSEPOLIA_ACM_AGGREGATOR, + signature: "executeRevokePermissions(uint256)", + params: [0], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ARBITRUM_SEPOLIA_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ARBITRUMSEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.arbitrumsepolia, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip372; From 1793fc802b8e3f0ddd21583d04df890413c22a69 Mon Sep 17 00:00:00 2001 From: Narayan Prusty Date: Fri, 4 Oct 2024 15:44:48 +0400 Subject: [PATCH 009/178] fix: added opbnbtestnet grant and revoke permissions --- simulations/vip-373/arbitrumsepolia.ts | 2 +- simulations/vip-373/opbnbtestnet.ts | 19 ++++++++++++++++ vips/vip-373/bsctestnet.ts | 30 ++++++++++++++++++++++++-- 3 files changed, 48 insertions(+), 3 deletions(-) create mode 100644 simulations/vip-373/opbnbtestnet.ts diff --git a/simulations/vip-373/arbitrumsepolia.ts b/simulations/vip-373/arbitrumsepolia.ts index 956ac70f1..e3002387b 100644 --- a/simulations/vip-373/arbitrumsepolia.ts +++ b/simulations/vip-373/arbitrumsepolia.ts @@ -5,7 +5,7 @@ import vip014 from "../../multisig/proposals/arbitrumsepolia/vip-014"; import vip373 from "../../vips/vip-373/bsctestnet"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; -forking(85791092, async () => { +forking(86016842, async () => { before(async () => { await pretendExecutingVip(await vip014()); }); diff --git a/simulations/vip-373/opbnbtestnet.ts b/simulations/vip-373/opbnbtestnet.ts new file mode 100644 index 000000000..cae10dad5 --- /dev/null +++ b/simulations/vip-373/opbnbtestnet.ts @@ -0,0 +1,19 @@ +import { expectEvents } from "src/utils"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip021 from "../../multisig/proposals/opbnbtestnet/vip-021"; +import vip373 from "../../vips/vip-373/bsctestnet"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; + +forking(41162234, async () => { + before(async () => { + await pretendExecutingVip(await vip021()); + }); + + testForkedNetworkVipCommands("vip373", await vip373(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [70]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [20]); + }, + }); +}); diff --git a/vips/vip-373/bsctestnet.ts b/vips/vip-373/bsctestnet.ts index fbf39393a..79d9c356e 100644 --- a/vips/vip-373/bsctestnet.ts +++ b/vips/vip-373/bsctestnet.ts @@ -6,6 +6,7 @@ export const ARBITRUM_SEPOLIA_ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F" export const OPBNBTESTNET_ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; export const ARBITRUMSEPOLIA_ACM_AGGREGATOR = "0x4fCbfE445396f31005b3Fd2F6DE2A986d6E2dCB5"; +export const OPBNBTESTNET_ACM_AGGREGATOR = "0xbDd501dB1B0D6aab299CE69ef5B86C8578947AD0"; export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; @@ -29,13 +30,13 @@ const vip372 = () => { { target: ARBITRUMSEPOLIA_ACM_AGGREGATOR, signature: "executeGrantPermissions(uint256)", - params: [0], + params: [1], dstChainId: LzChainId.arbitrumsepolia, }, { target: ARBITRUMSEPOLIA_ACM_AGGREGATOR, signature: "executeRevokePermissions(uint256)", - params: [0], + params: [1], dstChainId: LzChainId.arbitrumsepolia, }, { @@ -44,6 +45,31 @@ const vip372 = () => { params: [DEFAULT_ADMIN_ROLE, ARBITRUMSEPOLIA_ACM_AGGREGATOR], dstChainId: LzChainId.arbitrumsepolia, }, + + { + target: OPBNBTESTNET_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: OPBNBTESTNET_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: OPBNBTESTNET_ACM_AGGREGATOR, + signature: "executeRevokePermissions(uint256)", + params: [0], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: OPBNBTESTNET_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR], + dstChainId: LzChainId.opbnbtestnet, + }, ], meta, ProposalType.REGULAR, From eef333aaae12d336407095dbcab61a2462bff207 Mon Sep 17 00:00:00 2001 From: web3rover Date: Mon, 7 Oct 2024 13:58:06 +0400 Subject: [PATCH 010/178] fix: added vip for testnet and mainnet --- simulations/vip-381/abi/VTokenCorePool.json | 688 ++++++++++++++++++ simulations/vip-381/bscmainnet.ts | 57 ++ simulations/vip-381/bsctestnet.ts | 48 ++ src/vip-framework/abi/twoKinksIRM.json | 128 ++++ src/vip-framework/checks/interestRateModel.ts | 65 ++ vips/vip-381/bscmainnet.ts | 30 + vips/vip-381/bsctestnet.ts | 30 + 7 files changed, 1046 insertions(+) create mode 100644 simulations/vip-381/abi/VTokenCorePool.json create mode 100644 simulations/vip-381/bscmainnet.ts create mode 100644 simulations/vip-381/bsctestnet.ts create mode 100644 src/vip-framework/abi/twoKinksIRM.json create mode 100644 vips/vip-381/bscmainnet.ts create mode 100644 vips/vip-381/bsctestnet.ts diff --git a/simulations/vip-381/abi/VTokenCorePool.json b/simulations/vip-381/abi/VTokenCorePool.json new file mode 100644 index 000000000..c0187a7ca --- /dev/null +++ b/simulations/vip-381/abi/VTokenCorePool.json @@ -0,0 +1,688 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address payable", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "implementation_", "type": "address" }, + { "internalType": "bytes", "name": "becomeImplementationData", "type": "bytes" } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "error", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "info", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "detail", "type": "uint256" } + ], + "name": "Failure", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "NewAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ComptrollerInterface", + "name": "oldComptroller", + "type": "address" + }, + { "indexed": false, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldImplementation", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newImplementation", "type": "address" } + ], + "name": "NewImplementation", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } + ], + "name": "NewPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "admin", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { "payable": true, "stateMutability": "payable", "type": "fallback" }, + { + "constant": false, + "inputs": [], + "name": "_acceptAdmin", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "_addReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "_reduceReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" }], + "name": "_setComptroller", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "implementation_", "type": "address" }, + { "internalType": "bool", "name": "allowResign", "type": "bool" }, + { "internalType": "bytes", "name": "becomeImplementationData", "type": "bytes" } + ], + "name": "_setImplementation", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "_setInterestRateModel", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address payable", "name": "newPendingAdmin", "type": "address" }], + "name": "_setPendingAdmin", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "_setReserveFactor", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "bytes", "name": "data", "type": "bytes" }], + "name": "delegateToImplementation", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "bytes", "name": "data", "type": "bytes" }], + "name": "delegateToViewImplementation", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-381/bscmainnet.ts b/simulations/vip-381/bscmainnet.ts new file mode 100644 index 000000000..ff9c5b5c5 --- /dev/null +++ b/simulations/vip-381/bscmainnet.ts @@ -0,0 +1,57 @@ +import { TransactionResponse } from "@ethersproject/providers"; +import { expect } from "chai"; +import { ethers } from "hardhat"; +import { expectEvents } from "src/utils"; +import { forking, testVip } from "src/vip-framework"; +import { checkInterestRate, checkTwoKinksInterestRate } from "src/vip-framework/checks/interestRateModel"; + +import vip381, { IRM } from "../../vips/vip-381/bscmainnet"; +import VTOKEN_CORE_POOL_ABI from "./abi/VTokenCorePool.json"; + +const OLD_IRM = "0xDb8347b96c94Be24B9c077A4CDDAAD074F6480cf"; +const VBNB = "0xA07c5b74C9B40447a954e1466938b865b6BBea36"; + +forking(42904608, async () => { + const provider = ethers.provider; + + const vBNB = new ethers.Contract(VBNB, VTOKEN_CORE_POOL_ABI, provider); + + describe("Pre-VIP behaviour", async () => { + it("has expected interest rate model addresses", async () => { + expect(await vBNB.interestRateModel()).to.equal(OLD_IRM); + }); + + describe("old interest rate model parameters", async () => { + checkInterestRate(OLD_IRM, "vBNB", { + base: "0", + multiplier: "0.225", + jump: "6.8", + kink: "0.5", + }); + }); + }); + + testVip("VIP-381", await vip381(), { + callbackAfterExecution: async (txResponse: TransactionResponse) => { + await expectEvents(txResponse, [VTOKEN_CORE_POOL_ABI], ["NewMarketInterestRateModel"], [1]); + }, + }); + + describe("Post-VIP behavior", async () => { + it("has the new interest rate model addresses", async () => { + expect(await vBNB.interestRateModel()).to.equal(IRM); + }); + + describe("new interest rate model parameters", async () => { + checkTwoKinksInterestRate(IRM, "vBNB", { + base: "0", + multiplier: "0.225", + kink1: "0.4", + multiplier2: "0.5", + base2: "0.1", + kink2: "0.7", + jump: "6.8", + }); + }); + }); +}); diff --git a/simulations/vip-381/bsctestnet.ts b/simulations/vip-381/bsctestnet.ts new file mode 100644 index 000000000..e6ea467d8 --- /dev/null +++ b/simulations/vip-381/bsctestnet.ts @@ -0,0 +1,48 @@ +import { TransactionResponse } from "@ethersproject/providers"; +import { expect } from "chai"; +import { ethers } from "hardhat"; +import { expectEvents } from "src/utils"; +import { forking, testVip } from "src/vip-framework"; +import { checkTwoKinksInterestRate } from "src/vip-framework/checks/interestRateModel"; + +import vip381, { IRM } from "../../vips/vip-381/bsctestnet"; +import VTOKEN_CORE_POOL_ABI from "./abi/VTokenCorePool.json"; + +const OLD_IRM = "0x597F1eFCC8DD59598eD1944304814f60230BAe76"; +const VBNB = "0x2E7222e51c0f6e98610A1543Aa3836E092CDe62c"; + +forking(44524703, async () => { + const provider = ethers.provider; + + const vBNB = new ethers.Contract(VBNB, VTOKEN_CORE_POOL_ABI, provider); + + describe("Pre-VIP behaviour", async () => { + it("has expected interest rate model addresses", async () => { + expect(await vBNB.interestRateModel()).to.equal(OLD_IRM); + }); + }); + + testVip("VIP-381", await vip381(), { + callbackAfterExecution: async (txResponse: TransactionResponse) => { + await expectEvents(txResponse, [VTOKEN_CORE_POOL_ABI], ["NewMarketInterestRateModel"], [1]); + }, + }); + + describe("Post-VIP behavior", async () => { + it("has the new interest rate model addresses", async () => { + expect(await vBNB.interestRateModel()).to.equal(IRM); + }); + + describe("new interest rate model parameters", async () => { + checkTwoKinksInterestRate(IRM, "vBNB", { + base: "0", + multiplier: "0.225", + kink1: "0.4", + multiplier2: "0.5", + base2: "0.1", + kink2: "0.7", + jump: "6.8", + }); + }); + }); +}); diff --git a/src/vip-framework/abi/twoKinksIRM.json b/src/vip-framework/abi/twoKinksIRM.json new file mode 100644 index 000000000..e1eb77639 --- /dev/null +++ b/src/vip-framework/abi/twoKinksIRM.json @@ -0,0 +1,128 @@ +[ + { + "inputs": [ + { "internalType": "int256", "name": "baseRatePerYear_", "type": "int256" }, + { "internalType": "int256", "name": "multiplierPerYear_", "type": "int256" }, + { "internalType": "int256", "name": "kink1_", "type": "int256" }, + { "internalType": "int256", "name": "multiplier2PerYear_", "type": "int256" }, + { "internalType": "int256", "name": "baseRate2PerYear_", "type": "int256" }, + { "internalType": "int256", "name": "kink2_", "type": "int256" }, + { "internalType": "int256", "name": "jumpMultiplierPerYear_", "type": "int256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidKink", "type": "error" }, + { "inputs": [], "name": "NegativeValueNotAllowed", "type": "error" }, + { + "inputs": [], + "name": "BASE_RATE_2_PER_BLOCK", + "outputs": [{ "internalType": "int256", "name": "", "type": "int256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "BASE_RATE_PER_BLOCK", + "outputs": [{ "internalType": "int256", "name": "", "type": "int256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "BLOCKS_PER_YEAR", + "outputs": [{ "internalType": "int256", "name": "", "type": "int256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "JUMP_MULTIPLIER_PER_BLOCK", + "outputs": [{ "internalType": "int256", "name": "", "type": "int256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "KINK_1", + "outputs": [{ "internalType": "int256", "name": "", "type": "int256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "KINK_2", + "outputs": [{ "internalType": "int256", "name": "", "type": "int256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MULTIPLIER_2_PER_BLOCK", + "outputs": [{ "internalType": "int256", "name": "", "type": "int256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MULTIPLIER_PER_BLOCK", + "outputs": [{ "internalType": "int256", "name": "", "type": "int256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "RATE_1", + "outputs": [{ "internalType": "int256", "name": "", "type": "int256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "RATE_2", + "outputs": [{ "internalType": "int256", "name": "", "type": "int256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "cash", "type": "uint256" }, + { "internalType": "uint256", "name": "borrows", "type": "uint256" }, + { "internalType": "uint256", "name": "reserves", "type": "uint256" } + ], + "name": "getBorrowRate", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "cash", "type": "uint256" }, + { "internalType": "uint256", "name": "borrows", "type": "uint256" }, + { "internalType": "uint256", "name": "reserves", "type": "uint256" }, + { "internalType": "uint256", "name": "reserveFactorMantissa", "type": "uint256" } + ], + "name": "getSupplyRate", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isInterestRateModel", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "cash", "type": "uint256" }, + { "internalType": "uint256", "name": "borrows", "type": "uint256" }, + { "internalType": "uint256", "name": "reserves", "type": "uint256" } + ], + "name": "utilizationRate", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "pure", + "type": "function" + } +] diff --git a/src/vip-framework/checks/interestRateModel.ts b/src/vip-framework/checks/interestRateModel.ts index 553ed864c..2366c9fd6 100644 --- a/src/vip-framework/checks/interestRateModel.ts +++ b/src/vip-framework/checks/interestRateModel.ts @@ -3,6 +3,7 @@ import { BigNumber, Contract, utils } from "ethers"; import { ethers } from "hardhat"; import RATE_MODEL_ABI from "../abi/il_rateModel.json"; +import TWO_KINKS_RATE_MODEL_ABI from "../abi/twoKinksIRM.json"; const DEFAULT_BLOCKS_PER_YEAR = BigNumber.from(10512000); @@ -53,3 +54,67 @@ export function checkInterestRate( } }); } + +export function checkTwoKinksInterestRate( + rateModelAddress: string, + symbol: string, + { + base, + multiplier, + kink1, + multiplier2, + base2, + kink2, + jump, + }: { + base: string; + multiplier: string; + kink1: string; + multiplier2: string; + base2: string; + kink2: string; + jump: string; + }, + blocksPerYear: BigNumber = DEFAULT_BLOCKS_PER_YEAR, +) { + describe(`${symbol} interest rate model`, () => { + let rateModel: Contract; + + before(async () => { + rateModel = await ethers.getContractAt(TWO_KINKS_RATE_MODEL_ABI, rateModelAddress); + }); + + it(`should have base = ${base}`, async () => { + const basePerBlock = utils.parseUnits(base, 18).div(blocksPerYear); + expect(await rateModel.BASE_RATE_PER_BLOCK()).to.equal(basePerBlock); + }); + + it(`should have multiplier = ${multiplier}`, async () => { + const multiplierPerBlock = utils.parseUnits(multiplier, 18).div(blocksPerYear); + expect(await rateModel.MULTIPLIER_PER_BLOCK()).to.equal(multiplierPerBlock); + }); + + it(`should have kink1 = ${kink1}`, async () => { + expect(await rateModel.KINK_1()).to.equal(utils.parseUnits(kink1, 18)); + }); + + it(`should have multiplier2 = ${multiplier2}`, async () => { + const multiplierPerBlock = utils.parseUnits(multiplier2, 18).div(blocksPerYear); + expect(await rateModel.MULTIPLIER_2_PER_BLOCK()).to.equal(multiplierPerBlock); + }); + + it(`should have base2 = ${base2}`, async () => { + const basePerBlock = utils.parseUnits(base2, 18).div(blocksPerYear); + expect(await rateModel.BASE_RATE_2_PER_BLOCK()).to.equal(basePerBlock); + }); + + it(`should have kink2 = ${kink2}`, async () => { + expect(await rateModel.KINK_2()).to.equal(utils.parseUnits(kink2, 18)); + }); + + it(`should have jump = ${jump}`, async () => { + const jumpPerBlock = utils.parseUnits(jump, 18).div(blocksPerYear); + expect(await rateModel.JUMP_MULTIPLIER_PER_BLOCK()).to.equal(jumpPerBlock); + }); + }); +} diff --git a/vips/vip-381/bscmainnet.ts b/vips/vip-381/bscmainnet.ts new file mode 100644 index 000000000..65c887847 --- /dev/null +++ b/vips/vip-381/bscmainnet.ts @@ -0,0 +1,30 @@ +import { ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const IRM = "0xc9Be85a8851348f40A6f4773E0fAbC5459E38611"; +export const VBNB_ADMIN = "0x9A7890534d9d91d473F28cB97962d176e2B65f1d"; + +const vip381 = () => { + const meta = { + version: "v2", + title: "VIP-381", + description: ``, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + + return makeProposal( + [ + { + target: VBNB_ADMIN, + signature: "setInterestRateModel(address)", + params: [IRM], + }, + ], + meta, + ProposalType.REGULAR, + ); +}; + +export default vip381; diff --git a/vips/vip-381/bsctestnet.ts b/vips/vip-381/bsctestnet.ts new file mode 100644 index 000000000..9a2af47ca --- /dev/null +++ b/vips/vip-381/bsctestnet.ts @@ -0,0 +1,30 @@ +import { ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const IRM = "0x752B56f94c8dF2c3804c0Dd213Cf607FAa9D11b1"; +export const VBNB_ADMIN = "0x04109575c1dbB4ac2e59e60c783800ea10441BBe"; + +const vip381 = () => { + const meta = { + version: "v2", + title: "VIP-381", + description: ``, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + + return makeProposal( + [ + { + target: VBNB_ADMIN, + signature: "setInterestRateModel(address)", + params: [IRM], + }, + ], + meta, + ProposalType.REGULAR, + ); +}; + +export default vip381; From 5f043d614a26de9c66ac938af93996b9d8c9ab79 Mon Sep 17 00:00:00 2001 From: web3rover Date: Mon, 7 Oct 2024 14:51:05 +0400 Subject: [PATCH 011/178] fix: added sepolia commands --- .../vip-373/abi/OmnichainProposalSender.json | 314 ++++++++++++++++++ simulations/vip-373/bsctestnet.ts | 17 + simulations/vip-373/sepolia.ts | 19 ++ vips/vip-373/bsctestnet.ts | 26 ++ 4 files changed, 376 insertions(+) create mode 100644 simulations/vip-373/abi/OmnichainProposalSender.json create mode 100644 simulations/vip-373/bsctestnet.ts create mode 100644 simulations/vip-373/sepolia.ts diff --git a/simulations/vip-373/abi/OmnichainProposalSender.json b/simulations/vip-373/abi/OmnichainProposalSender.json new file mode 100644 index 000000000..66fd4df02 --- /dev/null +++ b/simulations/vip-373/abi/OmnichainProposalSender.json @@ -0,0 +1,314 @@ +[ + { + "inputs": [ + { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } + ], + "name": "ClearPayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } + ], + "name": "ExecuteRemoteProposal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "FallbackWithdraw", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } + ], + "name": "StorePayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], + "name": "TrustedRemoteRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "LZ_ENDPOINT", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourCommandsSent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLastProposalSentTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bool", "name": "useZro_", "type": "bool" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } + ], + "name": "estimateFees", + "outputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } + ], + "name": "execute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "fallbackWithdraw", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "proposalCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], + "name": "removeTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "retryExecute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" }, + { "internalType": "bytes", "name": "config_", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "storedExecutionHashes", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } +] diff --git a/simulations/vip-373/bsctestnet.ts b/simulations/vip-373/bsctestnet.ts new file mode 100644 index 000000000..e91202249 --- /dev/null +++ b/simulations/vip-373/bsctestnet.ts @@ -0,0 +1,17 @@ +import { expectEvents } from "../../src/utils"; +import { forking, testVip } from "../../src/vip-framework"; +import vip373 from "../../vips/vip-373/bsctestnet"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +forking(41938696, async () => { + testVip("vip372 XVS vault permission proposal", await vip373(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [3, 0], + ); + }, + }); +}); diff --git a/simulations/vip-373/sepolia.ts b/simulations/vip-373/sepolia.ts new file mode 100644 index 000000000..07381ec35 --- /dev/null +++ b/simulations/vip-373/sepolia.ts @@ -0,0 +1,19 @@ +import { expectEvents } from "src/utils"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip060 from "../../multisig/proposals/sepolia/vip-060"; +import vip373 from "../../vips/vip-373/bsctestnet"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; + +forking(6831661, async () => { + before(async () => { + await pretendExecutingVip(await vip060()); + }); + + testForkedNetworkVipCommands("vip373", await vip373(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [95]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [42]); + }, + }); +}); diff --git a/vips/vip-373/bsctestnet.ts b/vips/vip-373/bsctestnet.ts index 79d9c356e..134a0dbdc 100644 --- a/vips/vip-373/bsctestnet.ts +++ b/vips/vip-373/bsctestnet.ts @@ -7,6 +7,7 @@ export const OPBNBTESTNET_ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; export const ARBITRUMSEPOLIA_ACM_AGGREGATOR = "0x4fCbfE445396f31005b3Fd2F6DE2A986d6E2dCB5"; export const OPBNBTESTNET_ACM_AGGREGATOR = "0xbDd501dB1B0D6aab299CE69ef5B86C8578947AD0"; +export const SEPOLIA_ACM_AGGREGATOR = "0x0653830c55035d678e1287b2d4550519fd263d0e"; export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; @@ -70,6 +71,31 @@ const vip372 = () => { params: [DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR], dstChainId: LzChainId.opbnbtestnet, }, + + { + target: SEPOLIA_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.sepolia, + }, + { + target: SEPOLIA_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.sepolia, + }, + { + target: SEPOLIA_ACM_AGGREGATOR, + signature: "executeRevokePermissions(uint256)", + params: [0], + dstChainId: LzChainId.sepolia, + }, + { + target: SEPOLIA_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.sepolia, + }, ], meta, ProposalType.REGULAR, From cd2e228eaf42f62b084d568f4eaf98a1c637f612 Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Mon, 7 Oct 2024 14:17:20 +0300 Subject: [PATCH 012/178] feat(framework): add ACM to known addresses on BNB chain --- src/networkAddresses.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/networkAddresses.ts b/src/networkAddresses.ts index 29305788f..746c5b5dc 100644 --- a/src/networkAddresses.ts +++ b/src/networkAddresses.ts @@ -26,6 +26,7 @@ export const ORACLE_BNB = "0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB"; export const NETWORK_ADDRESSES = { bscmainnet: { DEFAULT_PROPOSER_ADDRESS: "0x97a32D4506F6A35De68e0680859cDF41D077a9a9", + ACCESS_CONTROL_MANAGER: "0x4788629ABc6cFCA10F9f969efdEAa1cF70c23555", GOVERNOR_PROXY: govBscmainnetContracts.addresses.GovernorBravoDelegator, NORMAL_TIMELOCK: govBscmainnetContracts.addresses.NormalTimelock, FAST_TRACK_TIMELOCK: govBscmainnetContracts.addresses.FastTrackTimelock, @@ -51,6 +52,7 @@ export const NETWORK_ADDRESSES = { bsctestnet: { DEFAULT_PROPOSER_ADDRESS: "0x2Ce1d0ffD7E869D9DF33e28552b12DdDed326706", GUARDIAN: "0x2Ce1d0ffD7E869D9DF33e28552b12DdDed326706", + ACCESS_CONTROL_MANAGER: govBsctestnetContracts.addresses.AccessControlManager, GOVERNOR_PROXY: govBsctestnetContracts.addresses.GovernorBravoDelegator, NORMAL_TIMELOCK: govBsctestnetContracts.addresses.NormalTimelock, FAST_TRACK_TIMELOCK: govBsctestnetContracts.addresses.FastTrackTimelock, From e3ef16e461b6a7b46ccd3834b3496a40e9c2dead Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Mon, 7 Oct 2024 18:32:29 +0530 Subject: [PATCH 013/178] refactor: give permissions using ACMAggregator --- .../proposals/zksyncsepolia/vip-010/index.ts | 77 --- .../zksyncsepolia/vip-010/index.ts | 44 +- simulations/vip-365/bsctestnet.ts | 1 - simulations/vip-365/zksyncsepolia.ts | 13 +- .../vip-366/abi/AccessControlManager_ABI.json | 157 ----- .../abi/OmnichainGovernanceExecutor_ABI.json | 539 ------------------ .../vip-366/abi/OmnichainProposalSender.json | 314 ---------- simulations/vip-366/bsctestnet.ts | 26 - simulations/vip-366/zksyncsepolia.ts | 45 -- vips/vip-365/bsctestnet.ts | 135 +---- vips/vip-366/bsctestnet.ts | 132 ----- 11 files changed, 26 insertions(+), 1457 deletions(-) delete mode 100644 simulations/vip-366/abi/AccessControlManager_ABI.json delete mode 100644 simulations/vip-366/abi/OmnichainGovernanceExecutor_ABI.json delete mode 100644 simulations/vip-366/abi/OmnichainProposalSender.json delete mode 100644 simulations/vip-366/bsctestnet.ts delete mode 100644 simulations/vip-366/zksyncsepolia.ts delete mode 100644 vips/vip-366/bsctestnet.ts diff --git a/multisig/proposals/zksyncsepolia/vip-010/index.ts b/multisig/proposals/zksyncsepolia/vip-010/index.ts index 1790c7435..f0fea6d62 100644 --- a/multisig/proposals/zksyncsepolia/vip-010/index.ts +++ b/multisig/proposals/zksyncsepolia/vip-010/index.ts @@ -1,88 +1,11 @@ -import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { makeProposal } from "src/utils"; -export const ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER = "0xa34607D58146FA02aF5f920f29C3D916acAb0bC5"; export const ZKSYNCSEPOLIA_ACM = "0xD07f543d47c3a8997D6079958308e981AC14CD01"; export const ZKSYNCSEPOLIA_NORMAL_TIMELOCK = "0x1730527a0f0930269313D77A317361b42971a67E"; const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; -const { zksyncsepolia } = NETWORK_ADDRESSES; - export const vip010 = () => { return makeProposal([ - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "forceResumeReceive(uint16,bytes)", zksyncsepolia.GUARDIAN], - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setMaxDailyReceiveLimit(uint256)", zksyncsepolia.GUARDIAN], - }, - - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "pause()", zksyncsepolia.GUARDIAN], - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "unpause()", zksyncsepolia.GUARDIAN], - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setTrustedRemoteAddress(uint16,bytes)", zksyncsepolia.GUARDIAN], - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "addTimelocks(address[])", zksyncsepolia.GUARDIAN], - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "setTimelockPendingAdmin(address,uint8)", - zksyncsepolia.GUARDIAN, - ], - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "retryMessage(uint16,bytes,uint64,bytes)", - zksyncsepolia.GUARDIAN, - ], - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setSrcChainId(uint16)", zksyncsepolia.GUARDIAN], - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setReceiveVersion(uint16)", zksyncsepolia.GUARDIAN], - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "setConfig(uint16,uint16,uint256,bytes)", - zksyncsepolia.GUARDIAN, - ], - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "transferBridgeOwnership(address)", zksyncsepolia.GUARDIAN], - }, { target: ZKSYNCSEPOLIA_ACM, signature: "grantRole(bytes32,address)", diff --git a/multisig/simulations/zksyncsepolia/vip-010/index.ts b/multisig/simulations/zksyncsepolia/vip-010/index.ts index e91f8531b..11d0dee9b 100644 --- a/multisig/simulations/zksyncsepolia/vip-010/index.ts +++ b/multisig/simulations/zksyncsepolia/vip-010/index.ts @@ -1,18 +1,11 @@ import { expect } from "chai"; import { Contract } from "ethers"; import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { forking, pretendExecutingVip } from "src/vip-framework"; -import vip010, { - ZKSYNCSEPOLIA_ACM, - ZKSYNCSEPOLIA_NORMAL_TIMELOCK, - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, -} from "../../../proposals/zksyncsepolia/vip-010"; +import vip010, { ZKSYNCSEPOLIA_ACM, ZKSYNCSEPOLIA_NORMAL_TIMELOCK } from "../../../proposals/zksyncsepolia/vip-010"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManagerAbi.json"; -const { zksyncsepolia } = NETWORK_ADDRESSES; - forking(3771669, async () => { let acm: Contract; let defaultAdminRole: string; @@ -25,24 +18,6 @@ forking(3771669, async () => { const hasRole = await acm.hasRole(defaultAdminRole, ZKSYNCSEPOLIA_NORMAL_TIMELOCK); expect(hasRole).equals(false); }); - - it("Guardian is not allowed to call retryMessage", async () => { - const role = ethers.utils.solidityPack( - ["address", "string"], - [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "retryMessage(uint16,bytes,uint64,bytes)"], - ); - const roleHash = ethers.utils.keccak256(role); - expect(await acm.hasRole(roleHash, zksyncsepolia.GUARDIAN)).to.be.false; - }); - - it("Guardian is not allowed to call forceResumeReceive", async () => { - const role = ethers.utils.solidityPack( - ["address", "string"], - [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "forceResumeReceive(uint16,bytes)"], - ); - const roleHash = ethers.utils.keccak256(role); - expect(await acm.hasRole(roleHash, zksyncsepolia.GUARDIAN)).to.be.false; - }); }); describe("Post-VIP behavior", async () => { before(async () => { @@ -52,22 +27,5 @@ forking(3771669, async () => { const hasRole = await acm.hasRole(defaultAdminRole, ZKSYNCSEPOLIA_NORMAL_TIMELOCK); expect(hasRole).equals(true); }); - it("Guardian is allowed to call retryMessage", async () => { - const role = ethers.utils.solidityPack( - ["address", "string"], - [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "retryMessage(uint16,bytes,uint64,bytes)"], - ); - const roleHash = ethers.utils.keccak256(role); - expect(await acm.hasRole(roleHash, zksyncsepolia.GUARDIAN)).to.be.true; - }); - - it("Guardian is allowed to call forceResumeReceive", async () => { - const role = ethers.utils.solidityPack( - ["address", "string"], - [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "forceResumeReceive(uint16,bytes)"], - ); - const roleHash = ethers.utils.keccak256(role); - expect(await acm.hasRole(roleHash, zksyncsepolia.GUARDIAN)).to.be.true; - }); }); }); diff --git a/simulations/vip-365/bsctestnet.ts b/simulations/vip-365/bsctestnet.ts index 7f8e66523..6f80e4ae9 100644 --- a/simulations/vip-365/bsctestnet.ts +++ b/simulations/vip-365/bsctestnet.ts @@ -32,7 +32,6 @@ forking(43836268, async () => { await expectEvents( txResponse, [ACCESS_CONTROL_MANAGER_ABI, OMNICHAIN_PROPOSAL_SENDER_ABI], - ["SetMaxDailyLimit", "SetTrustedRemoteAddress", "ExecuteRemoteProposal", "StorePayload"], [1, 1, 1, 0], ); diff --git a/simulations/vip-365/zksyncsepolia.ts b/simulations/vip-365/zksyncsepolia.ts index e42cb42a5..df54c3d7b 100644 --- a/simulations/vip-365/zksyncsepolia.ts +++ b/simulations/vip-365/zksyncsepolia.ts @@ -7,7 +7,12 @@ import { expectEvents, getOmnichainProposalSenderAddress } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; import vip010 from "../../multisig/proposals/zksyncsepolia/vip-010"; -import vip365, { ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER } from "../../vips/vip-365/bsctestnet"; +import vip365, { + DEFAULT_ADMIN_ROLE, + ZKSYNCSEPOLIA_ACM, + ZKSYNCSEPOLIA_ACM_AGGREGATOR, + ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, +} from "../../vips/vip-365/bsctestnet"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_EXECUTOR_OWNER_ABI from "./abi/OmnichainExecutorOwner_ABI.json"; import OMNICHAIN_GOVERNANCE_EXECUTOR_ABI from "./abi/OmnichainGovernanceExecutor_ABI.json"; @@ -16,7 +21,7 @@ const { zksyncsepolia } = NETWORK_ADDRESSES; const FAST_TRACK_TIMELOCK = "0xb055e028b27d53a455a6c040a6952e44E9E615c4"; const CRITICAL_TIMELOCK = "0x0E6138bE0FA1915efC73670a20A10EFd720a6Cc8"; -forking(3771669, async () => { +forking(3880136, async () => { const provider = ethers.provider; let lastProposalReceived: BigNumber; let executor: Contract; @@ -93,5 +98,9 @@ forking(3771669, async () => { expect(await executorOwner.functionRegistry(selector)).equals(signature); } }); + it("Default admin role must be revoked from ACMAggregator contract on ZKsync sepolia", async () => { + const acm = new ethers.Contract(ZKSYNCSEPOLIA_ACM, ACCESS_CONTROL_MANAGER_ABI, provider); + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, ZKSYNCSEPOLIA_ACM_AGGREGATOR)).to.be.false; + }); }); }); diff --git a/simulations/vip-366/abi/AccessControlManager_ABI.json b/simulations/vip-366/abi/AccessControlManager_ABI.json deleted file mode 100644 index 2ef119947..000000000 --- a/simulations/vip-366/abi/AccessControlManager_ABI.json +++ /dev/null @@ -1,157 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, - { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "PermissionGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, - { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "PermissionRevoked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, - { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } - ], - "name": "RoleAdminChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } - ], - "name": "RoleGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } - ], - "name": "RoleRevoked", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_ADMIN_ROLE", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], - "name": "getRoleAdmin", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" }, - { "internalType": "address", "name": "accountToPermit", "type": "address" } - ], - "name": "giveCallPermission", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "grantRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "hasPermission", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "hasRole", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "isAllowedToCall", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "renounceRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" }, - { "internalType": "address", "name": "accountToRevoke", "type": "address" } - ], - "name": "revokeCallPermission", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "revokeRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], - "name": "supportsInterface", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-366/abi/OmnichainGovernanceExecutor_ABI.json b/simulations/vip-366/abi/OmnichainGovernanceExecutor_ABI.json deleted file mode 100644 index b40c3cf44..000000000 --- a/simulations/vip-366/abi/OmnichainGovernanceExecutor_ABI.json +++ /dev/null @@ -1,539 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "endpoint_", "type": "address" }, - { "internalType": "address", "name": "guardian_", "type": "address" }, - { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidProposalId", "type": "error" }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "indexed": false, "internalType": "bytes", "name": "_payload", "type": "bytes" }, - { "indexed": false, "internalType": "bytes", "name": "_reason", "type": "bytes" } - ], - "name": "MessageFailed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldGuardian", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newGuardian", "type": "address" } - ], - "name": "NewGuardian", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "uint256", "name": "id", "type": "uint256" }], - "name": "ProposalCanceled", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "uint256", "name": "id", "type": "uint256" }], - "name": "ProposalExecuted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "id", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "eta", "type": "uint256" } - ], - "name": "ProposalQueued", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": false, "internalType": "address[]", "name": "targets", "type": "address[]" }, - { "indexed": false, "internalType": "uint256[]", "name": "values", "type": "uint256[]" }, - { "indexed": false, "internalType": "string[]", "name": "signatures", "type": "string[]" }, - { "indexed": false, "internalType": "bytes[]", "name": "calldatas", "type": "bytes[]" }, - { "indexed": false, "internalType": "uint8", "name": "proposalType", "type": "uint8" } - ], - "name": "ProposalReceived", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "srcChainId", "type": "uint16" }, - { "indexed": true, "internalType": "bytes", "name": "srcAddress", "type": "bytes" }, - { "indexed": false, "internalType": "uint64", "name": "nonce", "type": "uint64" }, - { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } - ], - "name": "ReceivePayloadFailed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "indexed": false, "internalType": "bytes32", "name": "_payloadHash", "type": "bytes32" } - ], - "name": "RetryMessageSuccess", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } - ], - "name": "SetMaxDailyReceiveLimit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint16", "name": "_type", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "_minDstGas", "type": "uint256" } - ], - "name": "SetMinDstGas", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "precrime", "type": "address" }], - "name": "SetPrecrime", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "oldSrcChainId", "type": "uint16" }, - { "indexed": true, "internalType": "uint16", "name": "newSrcChainId", "type": "uint16" } - ], - "name": "SetSrcChainId", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "", "type": "address" }, - { "indexed": false, "internalType": "uint8", "name": "", "type": "uint8" } - ], - "name": "SetTimelockPendingAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_path", "type": "bytes" } - ], - "name": "SetTrustedRemote", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } - ], - "name": "SetTrustedRemoteAddress", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint8", "name": "routeType", "type": "uint8" }, - { "indexed": true, "internalType": "address", "name": "oldTimelock", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newTimelock", "type": "address" } - ], - "name": "TimelockAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_PAYLOAD_SIZE_LIMIT", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ITimelock[]", "name": "timelocks_", "type": "address[]" }], - "name": "addTimelocks", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "proposalId_", "type": "uint256" }], - "name": "cancel", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "proposalId_", "type": "uint256" }], - "name": "execute", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "", "type": "uint16" }, - { "internalType": "bytes", "name": "", "type": "bytes" }, - { "internalType": "uint64", "name": "", "type": "uint64" } - ], - "name": "failedMessages", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } - ], - "name": "forceResumeReceive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_version", "type": "uint16" }, - { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "_configType", "type": "uint256" } - ], - "name": "getConfig", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }], - "name": "getTrustedRemoteAddress", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "guardian", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } - ], - "name": "isTrustedRemote", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "last24HourCommandsReceived", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "last24HourReceiveWindowStart", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "lastProposalReceived", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "lzEndpoint", - "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "internalType": "bytes", "name": "_payload", "type": "bytes" } - ], - "name": "lzReceive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxDailyReceiveLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "", "type": "uint16" }, - { "internalType": "uint16", "name": "", "type": "uint16" } - ], - "name": "minDstGasLookup", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "internalType": "bytes", "name": "_payload", "type": "bytes" } - ], - "name": "nonblockingLzReceive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "payloadSizeLimitLookup", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "precrime", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "proposalTimelocks", - "outputs": [{ "internalType": "contract ITimelock", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "proposals", - "outputs": [ - { "internalType": "uint256", "name": "id", "type": "uint256" }, - { "internalType": "uint256", "name": "eta", "type": "uint256" }, - { "internalType": "bool", "name": "canceled", "type": "bool" }, - { "internalType": "bool", "name": "executed", "type": "bool" }, - { "internalType": "uint8", "name": "proposalType", "type": "uint8" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "queued", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "srcAddress_", "type": "bytes" }, - { "internalType": "uint64", "name": "nonce_", "type": "uint64" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" } - ], - "name": "retryMessage", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_version", "type": "uint16" }, - { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, - { "internalType": "uint256", "name": "_configType", "type": "uint256" }, - { "internalType": "bytes", "name": "_config", "type": "bytes" } - ], - "name": "setConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newGuardian", "type": "address" }], - "name": "setGuardian", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit_", "type": "uint256" }], - "name": "setMaxDailyReceiveLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "internalType": "uint16", "name": "_packetType", "type": "uint16" }, - { "internalType": "uint256", "name": "_minGas", "type": "uint256" } - ], - "name": "setMinDstGas", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "internalType": "uint256", "name": "_size", "type": "uint256" } - ], - "name": "setPayloadSizeLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_precrime", "type": "address" }], - "name": "setPrecrime", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], - "name": "setReceiveVersion", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], - "name": "setSendVersion", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }], - "name": "setSrcChainId", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "pendingAdmin_", "type": "address" }, - { "internalType": "uint8", "name": "proposalType_", "type": "uint8" } - ], - "name": "setTimelockPendingAdmin", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_path", "type": "bytes" } - ], - "name": "setTrustedRemote", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "srcChainId", - "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "proposalId_", "type": "uint256" }], - "name": "state", - "outputs": [{ "internalType": "enum OmnichainGovernanceExecutor.ProposalState", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "trustedRemoteLookup", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } -] diff --git a/simulations/vip-366/abi/OmnichainProposalSender.json b/simulations/vip-366/abi/OmnichainProposalSender.json deleted file mode 100644 index 66fd4df02..000000000 --- a/simulations/vip-366/abi/OmnichainProposalSender.json +++ /dev/null @@ -1,314 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } - ], - "name": "ClearPayload", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } - ], - "name": "ExecuteRemoteProposal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } - ], - "name": "FallbackWithdraw", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } - ], - "name": "SetMaxDailyLimit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, - { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } - ], - "name": "SetTrustedRemoteAddress", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, - { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, - { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, - { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } - ], - "name": "StorePayload", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], - "name": "TrustedRemoteRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "LZ_ENDPOINT", - "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourCommandsSent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourWindowStart", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLastProposalSentTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToMaxDailyLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bool", "name": "useZro_", "type": "bool" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } - ], - "name": "estimateFees", - "outputs": [ - { "internalType": "uint256", "name": "", "type": "uint256" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, - { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } - ], - "name": "execute", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "to_", "type": "address" }, - { "internalType": "uint256", "name": "pId_", "type": "uint256" }, - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, - { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } - ], - "name": "fallbackWithdraw", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "version_", "type": "uint16" }, - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "configType_", "type": "uint256" } - ], - "name": "getConfig", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "proposalCount", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], - "name": "removeTrustedRemote", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "uint256", "name": "pId_", "type": "uint256" }, - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, - { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, - { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } - ], - "name": "retryExecute", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "version_", "type": "uint16" }, - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "configType_", "type": "uint256" }, - { "internalType": "bytes", "name": "config_", "type": "bytes" } - ], - "name": "setConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "limit_", "type": "uint256" } - ], - "name": "setMaxDailyLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], - "name": "setSendVersion", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "storedExecutionHashes", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "trustedRemoteLookup", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } -] diff --git a/simulations/vip-366/bsctestnet.ts b/simulations/vip-366/bsctestnet.ts deleted file mode 100644 index a1f11cde2..000000000 --- a/simulations/vip-366/bsctestnet.ts +++ /dev/null @@ -1,26 +0,0 @@ -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { expectEvents } from "src/utils"; -import { forking, pretendExecutingVip, testVip } from "src/vip-framework"; - -import vip365 from "../../vips/vip-365/bsctestnet"; -import vip366 from "../../vips/vip-366/bsctestnet"; -import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; - -const { bsctestnet } = NETWORK_ADDRESSES; - -forking(43839242, async () => { - before(async () => { - await pretendExecutingVip(await vip365(), bsctestnet.NORMAL_TIMELOCK); - }); - - testVip("vip329 give permissions to critical & fasttrack timelock", await vip366(), { - callbackAfterExecution: async txResponse => { - await expectEvents( - txResponse, - [OMNICHAIN_PROPOSAL_SENDER_ABI], - ["ExecuteRemoteProposal", "StorePayload"], - [1, 0], - ); - }, - }); -}); diff --git a/simulations/vip-366/zksyncsepolia.ts b/simulations/vip-366/zksyncsepolia.ts deleted file mode 100644 index 9237d82e8..000000000 --- a/simulations/vip-366/zksyncsepolia.ts +++ /dev/null @@ -1,45 +0,0 @@ -import { expect } from "chai"; -import { BigNumber, Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { expectEvents } from "src/utils"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; - -import vip010 from "../../multisig/proposals/zksyncsepolia/vip-010"; -import vip366 from "../../vips/vip-366/bsctestnet"; -import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; -import OMNICHAIN_GOVERNANCE_EXECUTOR_ABI from "./abi/OmnichainGovernanceExecutor_ABI.json"; - -const { zksyncsepolia } = NETWORK_ADDRESSES; - -forking(3771669, async () => { - const provider = ethers.provider; - let lastProposalReceived: BigNumber; - let executor: Contract; - - before(async () => { - executor = new ethers.Contract( - zksyncsepolia.OMNICHAIN_GOVERNANCE_EXECUTOR, - OMNICHAIN_GOVERNANCE_EXECUTOR_ABI, - provider, - ); - lastProposalReceived = await executor.lastProposalReceived(); - await pretendExecutingVip(await vip010()); - }); - - testForkedNetworkVipCommands("vip366 configures bridge", await vip366(), { - callbackAfterExecution: async txResponse => { - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [12]); - }, - }); - - describe("Post-VIP behaviour", async () => { - it("Proposal id should be incremented", async () => { - expect(await executor.lastProposalReceived()).to.be.equals(lastProposalReceived.add(1)); - }); - it("proposal should be executed", async () => { - const pId = await executor.lastProposalReceived(); - expect(await executor.state(pId)).to.be.equals(2); - }); - }); -}); diff --git a/vips/vip-365/bsctestnet.ts b/vips/vip-365/bsctestnet.ts index 09ec70cad..fc1beb6e5 100644 --- a/vips/vip-365/bsctestnet.ts +++ b/vips/vip-365/bsctestnet.ts @@ -7,7 +7,8 @@ export const OMNICHAIN_PROPOSAL_SENDER = "0xCfD34AEB46b1CB4779c945854d405E91D27A export const ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER = "0xa34607D58146FA02aF5f920f29C3D916acAb0bC5"; export const ZKSYNCSEPOLIA_ACM = "0xD07f543d47c3a8997D6079958308e981AC14CD01"; - +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; +export const ZKSYNCSEPOLIA_ACM_AGGREGATOR = "0x920Bb18c4bd4D7bc41Bf39933BCAa3D078641502"; export const MAX_DAILY_LIMIT = 100; const ZKSYNCSEPOLIA_CHAIN_ID = LzChainId.zksyncsepolia; @@ -15,10 +16,8 @@ const ZKSYNCSEPOLIA_CHAIN_ID = LzChainId.zksyncsepolia; const vip365 = () => { const meta = { version: "v2", - title: "VIP-365 Enable Multichain Governance on zksync sepolia (1/2)", - description: `### Summary - -`, + title: "VIP-365 Enable Multichain Governance on zksync sepolia", + description: `### Summary`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", @@ -35,7 +34,6 @@ const vip365 = () => { signature: "setTrustedRemoteAddress(uint16,bytes)", params: [ZKSYNCSEPOLIA_CHAIN_ID, zksyncsepolia.OMNICHAIN_GOVERNANCE_EXECUTOR], }, - { target: ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, signature: "acceptOwnership()", @@ -44,126 +42,21 @@ const vip365 = () => { }, { target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setSrcChainId(uint16)", zksyncsepolia.NORMAL_TIMELOCK], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "transferBridgeOwnership(address)", - zksyncsepolia.NORMAL_TIMELOCK, - ], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setSendVersion(uint16)", zksyncsepolia.NORMAL_TIMELOCK], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setReceiveVersion(uint16)", zksyncsepolia.NORMAL_TIMELOCK], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "setMaxDailyReceiveLimit(uint256)", - zksyncsepolia.NORMAL_TIMELOCK, - ], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "pause()", zksyncsepolia.NORMAL_TIMELOCK], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setPrecrime(address)", zksyncsepolia.NORMAL_TIMELOCK], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "setMinDstGas(uint16,uint16,uint256)", - zksyncsepolia.NORMAL_TIMELOCK, - ], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "setPayloadSizeLimit(uint16,uint256)", - zksyncsepolia.NORMAL_TIMELOCK, - ], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "setConfig(uint16,uint16,uint256,bytes)", - zksyncsepolia.NORMAL_TIMELOCK, - ], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "addTimelocks(address[])", zksyncsepolia.NORMAL_TIMELOCK], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "setTrustedRemoteAddress(uint16,bytes)", - zksyncsepolia.NORMAL_TIMELOCK, - ], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ZKSYNCSEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.zksyncsepolia, }, { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "setTimelockPendingAdmin(address,uint8)", - zksyncsepolia.NORMAL_TIMELOCK, - ], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + target: ZKSYNCSEPOLIA_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.zksyncsepolia, }, { target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "retryMessage(uint16,bytes,uint64,bytes)", - zksyncsepolia.NORMAL_TIMELOCK, - ], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setGuardian(address)", zksyncsepolia.NORMAL_TIMELOCK], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ZKSYNCSEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.zksyncsepolia, }, ], meta, diff --git a/vips/vip-366/bsctestnet.ts b/vips/vip-366/bsctestnet.ts deleted file mode 100644 index cc3c9b205..000000000 --- a/vips/vip-366/bsctestnet.ts +++ /dev/null @@ -1,132 +0,0 @@ -import { LzChainId, ProposalType } from "src/types"; -import { makeProposal } from "src/utils"; - -const ZKSYNCSEPOLIA_FASTTRACK_TIMELOCK = "0xb055e028b27d53a455a6c040a6952e44E9E615c4"; -const ZKSYNCSEPOLIA_CRITICAL_TIMELOCK = "0x0E6138bE0FA1915efC73670a20A10EFd720a6Cc8"; -export const ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER = "0xa34607D58146FA02aF5f920f29C3D916acAb0bC5"; -export const ZKSYNCSEPOLIA_ACM = "0xD07f543d47c3a8997D6079958308e981AC14CD01"; - -const ZKSYNCSEPOLIA_CHAIN_ID = LzChainId.zksyncsepolia; - -const vip366 = () => { - const meta = { - version: "v2", - title: "VIP-366 Enable Multichain Governance on Zksync sepolia (2/2)", - description: `### Description - -Related with the VIP-366, if passed, this VIP will grant permission to Fast-track and Critical timelocks to execute privilege commands on the OmnichainProposalExecutor on Zksync sepolia. Review VIP-365 for more details. - -### References -`, - forDescription: "I agree that Venus Protocol should proceed with this proposal", - againstDescription: "I do not think that Venus Protocol should proceed with this proposal", - abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", - }; - return makeProposal( - [ - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setReceiveVersion(uint16)", ZKSYNCSEPOLIA_FASTTRACK_TIMELOCK], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setReceiveVersion(uint16)", ZKSYNCSEPOLIA_CRITICAL_TIMELOCK], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "setMaxDailyReceiveLimit(uint256)", - ZKSYNCSEPOLIA_FASTTRACK_TIMELOCK, - ], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "setMaxDailyReceiveLimit(uint256)", - ZKSYNCSEPOLIA_CRITICAL_TIMELOCK, - ], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "pause()", ZKSYNCSEPOLIA_FASTTRACK_TIMELOCK], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "pause()", ZKSYNCSEPOLIA_CRITICAL_TIMELOCK], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "setConfig(uint16,uint16,uint256,bytes)", - ZKSYNCSEPOLIA_FASTTRACK_TIMELOCK, - ], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "setConfig(uint16,uint16,uint256,bytes)", - ZKSYNCSEPOLIA_CRITICAL_TIMELOCK, - ], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "addTimelocks(address[])", ZKSYNCSEPOLIA_FASTTRACK_TIMELOCK], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "addTimelocks(address[])", ZKSYNCSEPOLIA_CRITICAL_TIMELOCK], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "retryMessage(uint16,bytes,uint64,bytes)", - ZKSYNCSEPOLIA_FASTTRACK_TIMELOCK, - ], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - - { - target: ZKSYNCSEPOLIA_ACM, - signature: "giveCallPermission(address,string,address)", - params: [ - ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - "retryMessage(uint16,bytes,uint64,bytes)", - ZKSYNCSEPOLIA_CRITICAL_TIMELOCK, - ], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, - }, - ], - meta, - ProposalType.REGULAR, - ); -}; -export default vip366; From 0c57add8d58104273e060e89486fdd3a8793b9da Mon Sep 17 00:00:00 2001 From: web3rover Date: Mon, 7 Oct 2024 18:25:34 +0400 Subject: [PATCH 014/178] fix: use fast track timelock --- vips/vip-381/bscmainnet.ts | 2 +- vips/vip-381/bsctestnet.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/vips/vip-381/bscmainnet.ts b/vips/vip-381/bscmainnet.ts index 65c887847..7c942423c 100644 --- a/vips/vip-381/bscmainnet.ts +++ b/vips/vip-381/bscmainnet.ts @@ -23,7 +23,7 @@ const vip381 = () => { }, ], meta, - ProposalType.REGULAR, + ProposalType.FAST_TRACK, ); }; diff --git a/vips/vip-381/bsctestnet.ts b/vips/vip-381/bsctestnet.ts index 9a2af47ca..a9a0078e2 100644 --- a/vips/vip-381/bsctestnet.ts +++ b/vips/vip-381/bsctestnet.ts @@ -23,7 +23,7 @@ const vip381 = () => { }, ], meta, - ProposalType.REGULAR, + ProposalType.FAST_TRACK, ); }; From 736933fb79db6ad8143ac181c88a9873286eadb2 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Tue, 8 Oct 2024 14:47:26 +0530 Subject: [PATCH 015/178] feat: add more test in simulation --- simulations/vip-365/abi/ACMAggregator.json | 242 +++++++++++++++++++++ simulations/vip-365/zksyncsepolia.ts | 53 ++++- vips/vip-365/bsctestnet.ts | 8 +- 3 files changed, 294 insertions(+), 9 deletions(-) create mode 100644 simulations/vip-365/abi/ACMAggregator.json diff --git a/simulations/vip-365/abi/ACMAggregator.json b/simulations/vip-365/abi/ACMAggregator.json new file mode 100644 index 000000000..6650a3f3c --- /dev/null +++ b/simulations/vip-365/abi/ACMAggregator.json @@ -0,0 +1,242 @@ +[ + { + "inputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "_acm", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [], + "name": "EmptyPermissions", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "GrantPermissionsAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "GrantPermissionsExecuted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "RevokePermissionsAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "RevokePermissionsExecuted", + "type": "event" + }, + { + "inputs": [], + "name": "ACM", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "internalType": "struct ACMCommandsAggregator.Permission[]", + "name": "_permissions", + "type": "tuple[]" + } + ], + "name": "addGrantPermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "internalType": "struct ACMCommandsAggregator.Permission[]", + "name": "_permissions", + "type": "tuple[]" + } + ], + "name": "addRevokePermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "executeGrantPermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "executeRevokePermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "grantPermissions", + "outputs": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "revokePermissions", + "outputs": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-365/zksyncsepolia.ts b/simulations/vip-365/zksyncsepolia.ts index df54c3d7b..48b354c40 100644 --- a/simulations/vip-365/zksyncsepolia.ts +++ b/simulations/vip-365/zksyncsepolia.ts @@ -13,6 +13,7 @@ import vip365, { ZKSYNCSEPOLIA_ACM_AGGREGATOR, ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, } from "../../vips/vip-365/bsctestnet"; +import ACMAggregator_ABI from "./abi/ACMAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_EXECUTOR_OWNER_ABI from "./abi/OmnichainExecutorOwner_ABI.json"; import OMNICHAIN_GOVERNANCE_EXECUTOR_ABI from "./abi/OmnichainGovernanceExecutor_ABI.json"; @@ -21,7 +22,7 @@ const { zksyncsepolia } = NETWORK_ADDRESSES; const FAST_TRACK_TIMELOCK = "0xb055e028b27d53a455a6c040a6952e44E9E615c4"; const CRITICAL_TIMELOCK = "0x0E6138bE0FA1915efC73670a20A10EFd720a6Cc8"; -forking(3880136, async () => { +forking(3884819, async () => { const provider = ethers.provider; let lastProposalReceived: BigNumber; let executor: Contract; @@ -38,13 +39,24 @@ forking(3880136, async () => { await pretendExecutingVip(await vip010()); }); + describe("Pre-VIP behaviour", async () => { + it("Normal Timelock has default admin role on ZKsync sepolia", async () => { + const acm = await ethers.getContractAt(ACCESS_CONTROL_MANAGER_ABI, ZKSYNCSEPOLIA_ACM); + const hasRole = await acm.hasRole(DEFAULT_ADMIN_ROLE, zksyncsepolia.NORMAL_TIMELOCK); + expect(hasRole).equals(true); + }); + }); + testForkedNetworkVipCommands("vip365 configures bridge", await vip365(), { callbackAfterExecution: async txResponse => { - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [15]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [39]); + await expectEvents(txResponse, [ACMAggregator_ABI], ["GrantPermissionsExecuted"], [1]); }, }); describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(ZKSYNCSEPOLIA_ACM, ACCESS_CONTROL_MANAGER_ABI, provider); + it("Proposal id should be incremented", async () => { expect(await executor.lastProposalReceived()).to.be.equals(lastProposalReceived.add(1)); }); @@ -68,7 +80,7 @@ forking(3880136, async () => { // Check receiving limit expect(await executor.maxDailyReceiveLimit()).equals(100); - expect(await executor.last24HourCommandsReceived()).equals(16); + expect(await executor.last24HourCommandsReceived()).equals(4); // Check function registry const functionSignatures: string[] = [ @@ -99,8 +111,41 @@ forking(3880136, async () => { } }); it("Default admin role must be revoked from ACMAggregator contract on ZKsync sepolia", async () => { - const acm = new ethers.Contract(ZKSYNCSEPOLIA_ACM, ACCESS_CONTROL_MANAGER_ABI, provider); expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, ZKSYNCSEPOLIA_ACM_AGGREGATOR)).to.be.false; }); + it("Guardian and all timelocks are allowed to call retryMessage ", async () => { + const role = ethers.utils.solidityPack( + ["address", "string"], + [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "retryMessage(uint16,bytes,uint64,bytes)"], + ); + const roleHash = ethers.utils.keccak256(role); + expect(await acm.hasRole(roleHash, zksyncsepolia.GUARDIAN)).to.be.true; + expect(await acm.hasRole(roleHash, zksyncsepolia.NORMAL_TIMELOCK)).to.be.true; + expect(await acm.hasRole(roleHash, FAST_TRACK_TIMELOCK)).to.be.true; + expect(await acm.hasRole(roleHash, CRITICAL_TIMELOCK)).to.be.true; + }); + + it("Guardian is allowed to call forceResumeReceive but not timelocks", async () => { + const role = ethers.utils.solidityPack( + ["address", "string"], + [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "forceResumeReceive(uint16,bytes)"], + ); + const roleHash = ethers.utils.keccak256(role); + expect(await acm.hasRole(roleHash, zksyncsepolia.GUARDIAN)).to.be.true; + expect(await acm.hasRole(roleHash, zksyncsepolia.NORMAL_TIMELOCK)).to.be.false; + expect(await acm.hasRole(roleHash, FAST_TRACK_TIMELOCK)).to.be.false; + expect(await acm.hasRole(roleHash, CRITICAL_TIMELOCK)).to.be.false; + }); + it("Normal Timelock is allowed to call setSendVersion but not other timelocks and guardian", async () => { + const role = ethers.utils.solidityPack( + ["address", "string"], + [ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setSendVersion(uint16)"], + ); + const roleHash = ethers.utils.keccak256(role); + expect(await acm.hasRole(roleHash, zksyncsepolia.GUARDIAN)).to.be.false; + expect(await acm.hasRole(roleHash, zksyncsepolia.NORMAL_TIMELOCK)).to.be.true; + expect(await acm.hasRole(roleHash, FAST_TRACK_TIMELOCK)).to.be.false; + expect(await acm.hasRole(roleHash, CRITICAL_TIMELOCK)).to.be.false; + }); }); }); diff --git a/vips/vip-365/bsctestnet.ts b/vips/vip-365/bsctestnet.ts index fc1beb6e5..f13e10157 100644 --- a/vips/vip-365/bsctestnet.ts +++ b/vips/vip-365/bsctestnet.ts @@ -11,8 +11,6 @@ export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000 export const ZKSYNCSEPOLIA_ACM_AGGREGATOR = "0x920Bb18c4bd4D7bc41Bf39933BCAa3D078641502"; export const MAX_DAILY_LIMIT = 100; -const ZKSYNCSEPOLIA_CHAIN_ID = LzChainId.zksyncsepolia; - const vip365 = () => { const meta = { version: "v2", @@ -27,18 +25,18 @@ const vip365 = () => { { target: OMNICHAIN_PROPOSAL_SENDER, signature: "setMaxDailyLimit(uint16,uint256)", - params: [ZKSYNCSEPOLIA_CHAIN_ID, MAX_DAILY_LIMIT], + params: [LzChainId.zksyncsepolia, MAX_DAILY_LIMIT], }, { target: OMNICHAIN_PROPOSAL_SENDER, signature: "setTrustedRemoteAddress(uint16,bytes)", - params: [ZKSYNCSEPOLIA_CHAIN_ID, zksyncsepolia.OMNICHAIN_GOVERNANCE_EXECUTOR], + params: [LzChainId.zksyncsepolia, zksyncsepolia.OMNICHAIN_GOVERNANCE_EXECUTOR], }, { target: ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, signature: "acceptOwnership()", params: [], - dstChainId: ZKSYNCSEPOLIA_CHAIN_ID, + dstChainId: LzChainId.zksyncsepolia, }, { target: ZKSYNCSEPOLIA_ACM, From 0a100a86fae2e5bea810050a8e215c87f3439f85 Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 9 Oct 2024 14:47:14 +0400 Subject: [PATCH 016/178] fix: removed grant default role to normal timelock --- multisig/proposals/arbitrumone/vip-014/index.ts | 5 ----- multisig/proposals/arbitrumsepolia/vip-014/index.ts | 5 ----- multisig/proposals/ethereum/vip-061/index.ts | 5 ----- multisig/proposals/opbnbmainnet/vip-021/index.ts | 5 ----- multisig/proposals/opbnbtestnet/vip-021/index.ts | 5 ----- multisig/proposals/sepolia/vip-060/index.ts | 5 ----- 6 files changed, 30 deletions(-) diff --git a/multisig/proposals/arbitrumone/vip-014/index.ts b/multisig/proposals/arbitrumone/vip-014/index.ts index 56d6e85bd..fbaf5c613 100644 --- a/multisig/proposals/arbitrumone/vip-014/index.ts +++ b/multisig/proposals/arbitrumone/vip-014/index.ts @@ -131,11 +131,6 @@ const vip014 = () => { signature: "transferOwnership(address)", params: [arbitrumone.NORMAL_TIMELOCK], }, - { - target: ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, arbitrumone.NORMAL_TIMELOCK], - }, ]); }; diff --git a/multisig/proposals/arbitrumsepolia/vip-014/index.ts b/multisig/proposals/arbitrumsepolia/vip-014/index.ts index 47e2e2163..e144b055e 100644 --- a/multisig/proposals/arbitrumsepolia/vip-014/index.ts +++ b/multisig/proposals/arbitrumsepolia/vip-014/index.ts @@ -131,11 +131,6 @@ const vip014 = () => { signature: "transferOwnership(address)", params: [arbitrumsepolia.NORMAL_TIMELOCK], }, - { - target: ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, arbitrumsepolia.NORMAL_TIMELOCK], - }, ]); }; diff --git a/multisig/proposals/ethereum/vip-061/index.ts b/multisig/proposals/ethereum/vip-061/index.ts index a6c00d6f8..b8f5473e6 100644 --- a/multisig/proposals/ethereum/vip-061/index.ts +++ b/multisig/proposals/ethereum/vip-061/index.ts @@ -193,11 +193,6 @@ const vip061 = () => { signature: "transferOwnership(address)", params: [ethereum.NORMAL_TIMELOCK], }, - { - target: ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, ethereum.NORMAL_TIMELOCK], - }, ]); }; diff --git a/multisig/proposals/opbnbmainnet/vip-021/index.ts b/multisig/proposals/opbnbmainnet/vip-021/index.ts index 15087d41d..6806596f6 100644 --- a/multisig/proposals/opbnbmainnet/vip-021/index.ts +++ b/multisig/proposals/opbnbmainnet/vip-021/index.ts @@ -106,11 +106,6 @@ const vip021 = () => { signature: "transferOwnership(address)", params: [opbnbmainnet.NORMAL_TIMELOCK], }, - { - target: ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, opbnbmainnet.NORMAL_TIMELOCK], - }, ]); }; diff --git a/multisig/proposals/opbnbtestnet/vip-021/index.ts b/multisig/proposals/opbnbtestnet/vip-021/index.ts index 7ed329d64..739b1a586 100644 --- a/multisig/proposals/opbnbtestnet/vip-021/index.ts +++ b/multisig/proposals/opbnbtestnet/vip-021/index.ts @@ -105,11 +105,6 @@ const vip021 = () => { signature: "transferOwnership(address)", params: [opbnbtestnet.NORMAL_TIMELOCK], }, - { - target: ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, opbnbtestnet.NORMAL_TIMELOCK], - }, ]); }; diff --git a/multisig/proposals/sepolia/vip-060/index.ts b/multisig/proposals/sepolia/vip-060/index.ts index b79cdc5de..0da7245f8 100644 --- a/multisig/proposals/sepolia/vip-060/index.ts +++ b/multisig/proposals/sepolia/vip-060/index.ts @@ -184,11 +184,6 @@ const vip060 = () => { signature: "transferOwnership(address)", params: [sepolia.NORMAL_TIMELOCK], }, - { - target: ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, sepolia.NORMAL_TIMELOCK], - }, ]); }; From 54c01b79efd150761ec746057046e9d26748fdbb Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 9 Oct 2024 15:02:59 +0400 Subject: [PATCH 017/178] fix: whitelisted normal timelock in xvs bridge admin --- multisig/proposals/arbitrumone/vip-014/index.ts | 5 +++++ multisig/proposals/arbitrumsepolia/vip-014/index.ts | 5 +++++ multisig/proposals/ethereum/vip-061/index.ts | 5 +++++ multisig/proposals/opbnbmainnet/vip-021/index.ts | 5 +++++ multisig/proposals/opbnbtestnet/vip-021/index.ts | 5 +++++ multisig/proposals/sepolia/vip-060/index.ts | 5 +++++ 6 files changed, 30 insertions(+) diff --git a/multisig/proposals/arbitrumone/vip-014/index.ts b/multisig/proposals/arbitrumone/vip-014/index.ts index fbaf5c613..72a353aca 100644 --- a/multisig/proposals/arbitrumone/vip-014/index.ts +++ b/multisig/proposals/arbitrumone/vip-014/index.ts @@ -131,6 +131,11 @@ const vip014 = () => { signature: "transferOwnership(address)", params: [arbitrumone.NORMAL_TIMELOCK], }, + { + target: XVS_BRIDGE_ADMIN_PROXY, + signature: "setWhitelist(address,bool)", + params: [arbitrumone.NORMAL_TIMELOCK, true], + }, ]); }; diff --git a/multisig/proposals/arbitrumsepolia/vip-014/index.ts b/multisig/proposals/arbitrumsepolia/vip-014/index.ts index e144b055e..5953a3f91 100644 --- a/multisig/proposals/arbitrumsepolia/vip-014/index.ts +++ b/multisig/proposals/arbitrumsepolia/vip-014/index.ts @@ -131,6 +131,11 @@ const vip014 = () => { signature: "transferOwnership(address)", params: [arbitrumsepolia.NORMAL_TIMELOCK], }, + { + target: XVS_BRIDGE_ADMIN_PROXY, + signature: "setWhitelist(address,bool)", + params: [arbitrumsepolia.NORMAL_TIMELOCK, true], + }, ]); }; diff --git a/multisig/proposals/ethereum/vip-061/index.ts b/multisig/proposals/ethereum/vip-061/index.ts index b8f5473e6..acf7b850c 100644 --- a/multisig/proposals/ethereum/vip-061/index.ts +++ b/multisig/proposals/ethereum/vip-061/index.ts @@ -193,6 +193,11 @@ const vip061 = () => { signature: "transferOwnership(address)", params: [ethereum.NORMAL_TIMELOCK], }, + { + target: XVS_BRIDGE_ADMIN_PROXY, + signature: "setWhitelist(address,bool)", + params: [ethereum.NORMAL_TIMELOCK, true], + }, ]); }; diff --git a/multisig/proposals/opbnbmainnet/vip-021/index.ts b/multisig/proposals/opbnbmainnet/vip-021/index.ts index 6806596f6..c1b81a2bd 100644 --- a/multisig/proposals/opbnbmainnet/vip-021/index.ts +++ b/multisig/proposals/opbnbmainnet/vip-021/index.ts @@ -106,6 +106,11 @@ const vip021 = () => { signature: "transferOwnership(address)", params: [opbnbmainnet.NORMAL_TIMELOCK], }, + { + target: XVS_BRIDGE_ADMIN_PROXY, + signature: "setWhitelist(address,bool)", + params: [opbnbmainnet.NORMAL_TIMELOCK, true], + }, ]); }; diff --git a/multisig/proposals/opbnbtestnet/vip-021/index.ts b/multisig/proposals/opbnbtestnet/vip-021/index.ts index 739b1a586..9ccf7a7b2 100644 --- a/multisig/proposals/opbnbtestnet/vip-021/index.ts +++ b/multisig/proposals/opbnbtestnet/vip-021/index.ts @@ -105,6 +105,11 @@ const vip021 = () => { signature: "transferOwnership(address)", params: [opbnbtestnet.NORMAL_TIMELOCK], }, + { + target: XVS_BRIDGE_ADMIN_PROXY, + signature: "setWhitelist(address,bool)", + params: [opbnbtestnet.NORMAL_TIMELOCK, true], + }, ]); }; diff --git a/multisig/proposals/sepolia/vip-060/index.ts b/multisig/proposals/sepolia/vip-060/index.ts index 0da7245f8..928022f41 100644 --- a/multisig/proposals/sepolia/vip-060/index.ts +++ b/multisig/proposals/sepolia/vip-060/index.ts @@ -184,6 +184,11 @@ const vip060 = () => { signature: "transferOwnership(address)", params: [sepolia.NORMAL_TIMELOCK], }, + { + target: XVS_BRIDGE_ADMIN_PROXY, + signature: "setWhitelist(address,bool)", + params: [sepolia.NORMAL_TIMELOCK, true], + }, ]); }; From afd2ede25b2f85af447253b7105b62e34de6ce3e Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 9 Oct 2024 15:49:53 +0400 Subject: [PATCH 018/178] fix: check if default role is revoked --- simulations/vip-373/arbitrumsepolia.ts | 13 +++++++++++-- simulations/vip-373/opbnbtestnet.ts | 13 +++++++++++-- simulations/vip-373/sepolia.ts | 13 +++++++++++-- 3 files changed, 33 insertions(+), 6 deletions(-) diff --git a/simulations/vip-373/arbitrumsepolia.ts b/simulations/vip-373/arbitrumsepolia.ts index e3002387b..b63908598 100644 --- a/simulations/vip-373/arbitrumsepolia.ts +++ b/simulations/vip-373/arbitrumsepolia.ts @@ -1,8 +1,10 @@ +import { expect } from "chai"; +import { ethers } from "hardhat"; import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip014 from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import vip373 from "../../vips/vip-373/bsctestnet"; +import vip014, { ACM } from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import vip373, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-373/bsctestnet"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; forking(86016842, async () => { @@ -16,4 +18,11 @@ forking(86016842, async () => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [35]); }, }); + + describe("Post-VIP behaviour", async () => { + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; + }); + }); }); diff --git a/simulations/vip-373/opbnbtestnet.ts b/simulations/vip-373/opbnbtestnet.ts index cae10dad5..b50b38082 100644 --- a/simulations/vip-373/opbnbtestnet.ts +++ b/simulations/vip-373/opbnbtestnet.ts @@ -1,8 +1,10 @@ +import { expect } from "chai"; +import { ethers } from "hardhat"; import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip021 from "../../multisig/proposals/opbnbtestnet/vip-021"; -import vip373 from "../../vips/vip-373/bsctestnet"; +import vip021, { ACM } from "../../multisig/proposals/opbnbtestnet/vip-021"; +import vip373, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-373/bsctestnet"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; forking(41162234, async () => { @@ -16,4 +18,11 @@ forking(41162234, async () => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [20]); }, }); + + describe("Post-VIP behaviour", async () => { + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; + }); + }); }); diff --git a/simulations/vip-373/sepolia.ts b/simulations/vip-373/sepolia.ts index 07381ec35..a9adca15b 100644 --- a/simulations/vip-373/sepolia.ts +++ b/simulations/vip-373/sepolia.ts @@ -1,8 +1,10 @@ +import { expect } from "chai"; +import { ethers } from "hardhat"; import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip060 from "../../multisig/proposals/sepolia/vip-060"; -import vip373 from "../../vips/vip-373/bsctestnet"; +import vip060, { ACM } from "../../multisig/proposals/sepolia/vip-060"; +import vip373, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-373/bsctestnet"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; forking(6831661, async () => { @@ -16,4 +18,11 @@ forking(6831661, async () => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [42]); }, }); + + describe("Post-VIP behaviour", async () => { + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; + }); + }); }); From 2b290b26444b610aecf458446172456de5a78a5e Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 9 Oct 2024 15:57:54 +0400 Subject: [PATCH 019/178] fix: added check for GrantPermissionsExecuted and RevokePermissionsExecuted events --- .../vip-373/abi/ACMCommandsAggregator.json | 242 ++++++++++++++++++ simulations/vip-373/arbitrumsepolia.ts | 3 + simulations/vip-373/opbnbtestnet.ts | 3 + simulations/vip-373/sepolia.ts | 3 + 4 files changed, 251 insertions(+) create mode 100644 simulations/vip-373/abi/ACMCommandsAggregator.json diff --git a/simulations/vip-373/abi/ACMCommandsAggregator.json b/simulations/vip-373/abi/ACMCommandsAggregator.json new file mode 100644 index 000000000..6650a3f3c --- /dev/null +++ b/simulations/vip-373/abi/ACMCommandsAggregator.json @@ -0,0 +1,242 @@ +[ + { + "inputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "_acm", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [], + "name": "EmptyPermissions", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "GrantPermissionsAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "GrantPermissionsExecuted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "RevokePermissionsAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "RevokePermissionsExecuted", + "type": "event" + }, + { + "inputs": [], + "name": "ACM", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "internalType": "struct ACMCommandsAggregator.Permission[]", + "name": "_permissions", + "type": "tuple[]" + } + ], + "name": "addGrantPermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "internalType": "struct ACMCommandsAggregator.Permission[]", + "name": "_permissions", + "type": "tuple[]" + } + ], + "name": "addRevokePermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "executeGrantPermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "executeRevokePermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "grantPermissions", + "outputs": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "revokePermissions", + "outputs": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-373/arbitrumsepolia.ts b/simulations/vip-373/arbitrumsepolia.ts index b63908598..61ad86ab0 100644 --- a/simulations/vip-373/arbitrumsepolia.ts +++ b/simulations/vip-373/arbitrumsepolia.ts @@ -5,6 +5,7 @@ import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/ import vip014, { ACM } from "../../multisig/proposals/arbitrumsepolia/vip-014"; import vip373, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-373/bsctestnet"; +import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; forking(86016842, async () => { @@ -16,6 +17,8 @@ forking(86016842, async () => { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [84]); await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [35]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); }, }); diff --git a/simulations/vip-373/opbnbtestnet.ts b/simulations/vip-373/opbnbtestnet.ts index b50b38082..9747211f2 100644 --- a/simulations/vip-373/opbnbtestnet.ts +++ b/simulations/vip-373/opbnbtestnet.ts @@ -5,6 +5,7 @@ import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/ import vip021, { ACM } from "../../multisig/proposals/opbnbtestnet/vip-021"; import vip373, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-373/bsctestnet"; +import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; forking(41162234, async () => { @@ -16,6 +17,8 @@ forking(41162234, async () => { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [70]); await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [20]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); }, }); diff --git a/simulations/vip-373/sepolia.ts b/simulations/vip-373/sepolia.ts index a9adca15b..fe452e2dc 100644 --- a/simulations/vip-373/sepolia.ts +++ b/simulations/vip-373/sepolia.ts @@ -5,6 +5,7 @@ import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/ import vip060, { ACM } from "../../multisig/proposals/sepolia/vip-060"; import vip373, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-373/bsctestnet"; +import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; forking(6831661, async () => { @@ -16,6 +17,8 @@ forking(6831661, async () => { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [95]); await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [42]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); }, }); From 00e4b059381a897c534cff9575f557b53e25779c Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 9 Oct 2024 16:11:02 +0400 Subject: [PATCH 020/178] fix: check permissions --- simulations/vip-373/arbitrumsepolia.ts | 20 +++++++++++++++++++- simulations/vip-373/opbnbtestnet.ts | 20 +++++++++++++++++++- simulations/vip-373/sepolia.ts | 20 +++++++++++++++++++- 3 files changed, 57 insertions(+), 3 deletions(-) diff --git a/simulations/vip-373/arbitrumsepolia.ts b/simulations/vip-373/arbitrumsepolia.ts index 61ad86ab0..1afa6fbbf 100644 --- a/simulations/vip-373/arbitrumsepolia.ts +++ b/simulations/vip-373/arbitrumsepolia.ts @@ -1,5 +1,6 @@ import { expect } from "chai"; import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; @@ -8,6 +9,7 @@ import vip373, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../v import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; +const { arbitrumsepolia } = NETWORK_ADDRESSES; forking(86016842, async () => { before(async () => { await pretendExecutingVip(await vip014()); @@ -23,9 +25,25 @@ forking(86016842, async () => { }); describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { - const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; }); + + it("check few permissions", async () => { + const role1 = ethers.utils.solidityPack(["address", "string"], [arbitrumsepolia.RESILIENT_ORACLE, "pause()"]); + + const roleHash = ethers.utils.keccak256(role1); + expect(await acm.hasRole(roleHash, arbitrumsepolia.NORMAL_TIMELOCK)).to.be.true; + + const role2 = ethers.utils.solidityPack( + ["address", "string"], + [arbitrumsepolia.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], + ); + + const roleHash2 = ethers.utils.keccak256(role2); + expect(await acm.hasRole(roleHash2, arbitrumsepolia.NORMAL_TIMELOCK)).to.be.true; + }); }); }); diff --git a/simulations/vip-373/opbnbtestnet.ts b/simulations/vip-373/opbnbtestnet.ts index 9747211f2..a300e241b 100644 --- a/simulations/vip-373/opbnbtestnet.ts +++ b/simulations/vip-373/opbnbtestnet.ts @@ -1,5 +1,6 @@ import { expect } from "chai"; import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; @@ -8,6 +9,7 @@ import vip373, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../v import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; +const { opbnbtestnet } = NETWORK_ADDRESSES; forking(41162234, async () => { before(async () => { await pretendExecutingVip(await vip021()); @@ -23,9 +25,25 @@ forking(41162234, async () => { }); describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { - const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; }); + + it("check few permissions", async () => { + const role1 = ethers.utils.solidityPack(["address", "string"], [opbnbtestnet.RESILIENT_ORACLE, "pause()"]); + + const roleHash = ethers.utils.keccak256(role1); + expect(await acm.hasRole(roleHash, opbnbtestnet.NORMAL_TIMELOCK)).to.be.true; + + const role2 = ethers.utils.solidityPack( + ["address", "string"], + [opbnbtestnet.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], + ); + + const roleHash2 = ethers.utils.keccak256(role2); + expect(await acm.hasRole(roleHash2, opbnbtestnet.NORMAL_TIMELOCK)).to.be.true; + }); }); }); diff --git a/simulations/vip-373/sepolia.ts b/simulations/vip-373/sepolia.ts index fe452e2dc..a69fafa47 100644 --- a/simulations/vip-373/sepolia.ts +++ b/simulations/vip-373/sepolia.ts @@ -1,5 +1,6 @@ import { expect } from "chai"; import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; @@ -8,6 +9,7 @@ import vip373, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../v import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; +const { sepolia } = NETWORK_ADDRESSES; forking(6831661, async () => { before(async () => { await pretendExecutingVip(await vip060()); @@ -23,9 +25,25 @@ forking(6831661, async () => { }); describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { - const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; }); + + it("check few permissions", async () => { + const role1 = ethers.utils.solidityPack(["address", "string"], [sepolia.RESILIENT_ORACLE, "pause()"]); + + const roleHash = ethers.utils.keccak256(role1); + expect(await acm.hasRole(roleHash, sepolia.NORMAL_TIMELOCK)).to.be.true; + + const role2 = ethers.utils.solidityPack( + ["address", "string"], + [sepolia.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], + ); + + const roleHash2 = ethers.utils.keccak256(role2); + expect(await acm.hasRole(roleHash2, sepolia.NORMAL_TIMELOCK)).to.be.true; + }); }); }); From 9099c81df860616258750c4570982624f3cbdf9b Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 9 Oct 2024 16:20:15 +0400 Subject: [PATCH 021/178] fix: merged vips --- simulations/vip-372/arbitrumsepolia.ts | 38 ++- simulations/vip-372/opbnbtestnet.ts | 44 ++- simulations/vip-372/sepolia.ts | 40 ++- .../vip-373/abi/ACMCommandsAggregator.json | 242 -------------- .../vip-373/abi/AccessControlManager.json | 157 --------- .../vip-373/abi/OmnichainProposalSender.json | 314 ------------------ simulations/vip-373/arbitrumsepolia.ts | 49 --- simulations/vip-373/bsctestnet.ts | 17 - simulations/vip-373/opbnbtestnet.ts | 49 --- simulations/vip-373/sepolia.ts | 49 --- vips/vip-372/bsctestnet.ts | 81 +++++ vips/vip-373/bsctestnet.ts | 104 ------ 12 files changed, 192 insertions(+), 992 deletions(-) delete mode 100644 simulations/vip-373/abi/ACMCommandsAggregator.json delete mode 100644 simulations/vip-373/abi/AccessControlManager.json delete mode 100644 simulations/vip-373/abi/OmnichainProposalSender.json delete mode 100644 simulations/vip-373/arbitrumsepolia.ts delete mode 100644 simulations/vip-373/bsctestnet.ts delete mode 100644 simulations/vip-373/opbnbtestnet.ts delete mode 100644 simulations/vip-373/sepolia.ts delete mode 100644 vips/vip-373/bsctestnet.ts diff --git a/simulations/vip-372/arbitrumsepolia.ts b/simulations/vip-372/arbitrumsepolia.ts index 50bc99e79..aebfa8711 100644 --- a/simulations/vip-372/arbitrumsepolia.ts +++ b/simulations/vip-372/arbitrumsepolia.ts @@ -2,13 +2,18 @@ import { expect } from "chai"; import { Contract } from "ethers"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip014 from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import vip014, { ACM } from "../../multisig/proposals/arbitrumsepolia/vip-014"; import vip372, { ARBITRUM_SEPOLIA_BOUND_VALIDATOR, ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN, + DEFAULT_ADMIN_ROLE, + OPBNBTESTNET_ACM_AGGREGATOR, } from "../../vips/vip-372/bsctestnet"; +import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; @@ -19,7 +24,7 @@ import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; const XVS_BRIDGE = "0xFdC5cEC63FD167DA46cF006585b30D03B104eFD4"; const { arbitrumsepolia } = NETWORK_ADDRESSES; -forking(62418214, async () => { +forking(86016842, async () => { const provider = ethers.provider; let chainLinkOracle: Contract; let redstoneOracle: Contract; @@ -40,9 +45,36 @@ forking(62418214, async () => { await pretendExecutingVip(await vip014()); }); - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip372()); + testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip372(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [70]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [20]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); + }, + }); describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); + + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; + }); + + it("check few permissions", async () => { + const role1 = ethers.utils.solidityPack(["address", "string"], [arbitrumsepolia.RESILIENT_ORACLE, "pause()"]); + + const roleHash = ethers.utils.keccak256(role1); + expect(await acm.hasRole(roleHash, arbitrumsepolia.NORMAL_TIMELOCK)).to.be.true; + + const role2 = ethers.utils.solidityPack( + ["address", "string"], + [arbitrumsepolia.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], + ); + + const roleHash2 = ethers.utils.keccak256(role2); + expect(await acm.hasRole(roleHash2, arbitrumsepolia.NORMAL_TIMELOCK)).to.be.true; + }); it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { expect(await xvsBridgeAdmin.owner()).to.be.equals(arbitrumsepolia.NORMAL_TIMELOCK); }); diff --git a/simulations/vip-372/opbnbtestnet.ts b/simulations/vip-372/opbnbtestnet.ts index 129194e64..7a500dbdf 100644 --- a/simulations/vip-372/opbnbtestnet.ts +++ b/simulations/vip-372/opbnbtestnet.ts @@ -2,10 +2,18 @@ import { expect } from "chai"; import { Contract } from "ethers"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip021 from "../../multisig/proposals/opbnbtestnet/vip-021"; -import vip372, { OPBNBTESTNET_BOUND_VALIDATOR, OPBNBTESTNET_XVS_BRIDGE_ADMIN } from "../../vips/vip-372/bsctestnet"; +import vip021, { ACM } from "../../multisig/proposals/opbnbtestnet/vip-021"; +import vip372, { + DEFAULT_ADMIN_ROLE, + OPBNBTESTNET_ACM_AGGREGATOR, + OPBNBTESTNET_BOUND_VALIDATOR, + OPBNBTESTNET_XVS_BRIDGE_ADMIN, +} from "../../vips/vip-372/bsctestnet"; +import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; @@ -16,7 +24,7 @@ import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; const XVS_BRIDGE = "0xA03205bC635A772E533E7BE36b5701E331a70ea3"; const { opbnbtestnet } = NETWORK_ADDRESSES; -forking(33739110, async () => { +forking(41162234, async () => { const provider = ethers.provider; let binanceOracle: Contract; let resilientOracle: Contract; @@ -34,9 +42,37 @@ forking(33739110, async () => { await pretendExecutingVip(await vip021()); }); - testForkedNetworkVipCommands("vip372", await vip372()); + testForkedNetworkVipCommands("vip372", await vip372(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [70]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [20]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); + }, + }); describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); + + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; + }); + + it("check few permissions", async () => { + const role1 = ethers.utils.solidityPack(["address", "string"], [opbnbtestnet.RESILIENT_ORACLE, "pause()"]); + + const roleHash = ethers.utils.keccak256(role1); + expect(await acm.hasRole(roleHash, opbnbtestnet.NORMAL_TIMELOCK)).to.be.true; + + const role2 = ethers.utils.solidityPack( + ["address", "string"], + [opbnbtestnet.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], + ); + + const roleHash2 = ethers.utils.keccak256(role2); + expect(await acm.hasRole(roleHash2, opbnbtestnet.NORMAL_TIMELOCK)).to.be.true; + }); + it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { expect(await xvsBridgeAdmin.owner()).to.be.equals(opbnbtestnet.NORMAL_TIMELOCK); }); diff --git a/simulations/vip-372/sepolia.ts b/simulations/vip-372/sepolia.ts index 9995c671c..4fd043e4f 100644 --- a/simulations/vip-372/sepolia.ts +++ b/simulations/vip-372/sepolia.ts @@ -2,14 +2,19 @@ import { expect } from "chai"; import { Contract } from "ethers"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip060 from "../../multisig/proposals/sepolia/vip-060"; +import vip060, { ACM } from "../../multisig/proposals/sepolia/vip-060"; import vip372, { + DEFAULT_ADMIN_ROLE, + OPBNBTESTNET_ACM_AGGREGATOR, SEPOLIA_BOUND_VALIDATOR, SEPOLIA_XVS_BRIDGE_ADMIN, SEPOLIA_sFrxETH_ORACLE, } from "../../vips/vip-372/bsctestnet"; +import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; @@ -20,7 +25,7 @@ import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; const XVS_BRIDGE = "0xc340b7d3406502F43dC11a988E4EC5bbE536E642"; const { sepolia } = NETWORK_ADDRESSES; -forking(6276156, async () => { +forking(6831661, async () => { const provider = ethers.provider; let chainLinkOracle: Contract; let redstoneOracle: Contract; @@ -38,16 +43,43 @@ forking(6276156, async () => { await pretendExecutingVip(await vip060()); }); - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip372()); + testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip372(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [95]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [42]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); + }, + }); describe("Post-VIP behaviour", async () => { let xvsBridgeAdmin: Contract; let xvsBridge: Contract; - + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); before(async () => { xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, SEPOLIA_XVS_BRIDGE_ADMIN); xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); }); + + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; + }); + + it("check few permissions", async () => { + const role1 = ethers.utils.solidityPack(["address", "string"], [sepolia.RESILIENT_ORACLE, "pause()"]); + + const roleHash = ethers.utils.keccak256(role1); + expect(await acm.hasRole(roleHash, sepolia.NORMAL_TIMELOCK)).to.be.true; + + const role2 = ethers.utils.solidityPack( + ["address", "string"], + [sepolia.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], + ); + + const roleHash2 = ethers.utils.keccak256(role2); + expect(await acm.hasRole(roleHash2, sepolia.NORMAL_TIMELOCK)).to.be.true; + }); + it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { expect(await xvsBridgeAdmin.owner()).to.be.equals(sepolia.NORMAL_TIMELOCK); }); diff --git a/simulations/vip-373/abi/ACMCommandsAggregator.json b/simulations/vip-373/abi/ACMCommandsAggregator.json deleted file mode 100644 index 6650a3f3c..000000000 --- a/simulations/vip-373/abi/ACMCommandsAggregator.json +++ /dev/null @@ -1,242 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "_acm", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [], - "name": "EmptyPermissions", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "GrantPermissionsAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "GrantPermissionsExecuted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "RevokePermissionsAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "RevokePermissionsExecuted", - "type": "event" - }, - { - "inputs": [], - "name": "ACM", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "contractAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "functionSig", - "type": "string" - }, - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "internalType": "struct ACMCommandsAggregator.Permission[]", - "name": "_permissions", - "type": "tuple[]" - } - ], - "name": "addGrantPermissions", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "contractAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "functionSig", - "type": "string" - }, - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "internalType": "struct ACMCommandsAggregator.Permission[]", - "name": "_permissions", - "type": "tuple[]" - } - ], - "name": "addRevokePermissions", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "executeGrantPermissions", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "executeRevokePermissions", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "name": "grantPermissions", - "outputs": [ - { - "internalType": "address", - "name": "contractAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "functionSig", - "type": "string" - }, - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "name": "revokePermissions", - "outputs": [ - { - "internalType": "address", - "name": "contractAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "functionSig", - "type": "string" - }, - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/AccessControlManager.json b/simulations/vip-373/abi/AccessControlManager.json deleted file mode 100644 index 2ef119947..000000000 --- a/simulations/vip-373/abi/AccessControlManager.json +++ /dev/null @@ -1,157 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, - { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "PermissionGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, - { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "PermissionRevoked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, - { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } - ], - "name": "RoleAdminChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } - ], - "name": "RoleGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } - ], - "name": "RoleRevoked", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_ADMIN_ROLE", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], - "name": "getRoleAdmin", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" }, - { "internalType": "address", "name": "accountToPermit", "type": "address" } - ], - "name": "giveCallPermission", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "grantRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "hasPermission", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "hasRole", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "isAllowedToCall", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "renounceRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" }, - { "internalType": "address", "name": "accountToRevoke", "type": "address" } - ], - "name": "revokeCallPermission", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "revokeRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], - "name": "supportsInterface", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/OmnichainProposalSender.json b/simulations/vip-373/abi/OmnichainProposalSender.json deleted file mode 100644 index 66fd4df02..000000000 --- a/simulations/vip-373/abi/OmnichainProposalSender.json +++ /dev/null @@ -1,314 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } - ], - "name": "ClearPayload", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } - ], - "name": "ExecuteRemoteProposal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } - ], - "name": "FallbackWithdraw", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } - ], - "name": "SetMaxDailyLimit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, - { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } - ], - "name": "SetTrustedRemoteAddress", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, - { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, - { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, - { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } - ], - "name": "StorePayload", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], - "name": "TrustedRemoteRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "LZ_ENDPOINT", - "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourCommandsSent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourWindowStart", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLastProposalSentTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToMaxDailyLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bool", "name": "useZro_", "type": "bool" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } - ], - "name": "estimateFees", - "outputs": [ - { "internalType": "uint256", "name": "", "type": "uint256" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, - { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } - ], - "name": "execute", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "to_", "type": "address" }, - { "internalType": "uint256", "name": "pId_", "type": "uint256" }, - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, - { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } - ], - "name": "fallbackWithdraw", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "version_", "type": "uint16" }, - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "configType_", "type": "uint256" } - ], - "name": "getConfig", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "proposalCount", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], - "name": "removeTrustedRemote", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "uint256", "name": "pId_", "type": "uint256" }, - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, - { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, - { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } - ], - "name": "retryExecute", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "version_", "type": "uint16" }, - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "configType_", "type": "uint256" }, - { "internalType": "bytes", "name": "config_", "type": "bytes" } - ], - "name": "setConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "limit_", "type": "uint256" } - ], - "name": "setMaxDailyLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], - "name": "setSendVersion", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "storedExecutionHashes", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "trustedRemoteLookup", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } -] diff --git a/simulations/vip-373/arbitrumsepolia.ts b/simulations/vip-373/arbitrumsepolia.ts deleted file mode 100644 index 1afa6fbbf..000000000 --- a/simulations/vip-373/arbitrumsepolia.ts +++ /dev/null @@ -1,49 +0,0 @@ -import { expect } from "chai"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { expectEvents } from "src/utils"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; - -import vip014, { ACM } from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import vip373, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-373/bsctestnet"; -import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; -import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; - -const { arbitrumsepolia } = NETWORK_ADDRESSES; -forking(86016842, async () => { - before(async () => { - await pretendExecutingVip(await vip014()); - }); - - testForkedNetworkVipCommands("vip373", await vip373(), { - callbackAfterExecution: async txResponse => { - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [84]); - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [35]); - await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); - await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); - }, - }); - - describe("Post-VIP behaviour", async () => { - const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); - - it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { - expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; - }); - - it("check few permissions", async () => { - const role1 = ethers.utils.solidityPack(["address", "string"], [arbitrumsepolia.RESILIENT_ORACLE, "pause()"]); - - const roleHash = ethers.utils.keccak256(role1); - expect(await acm.hasRole(roleHash, arbitrumsepolia.NORMAL_TIMELOCK)).to.be.true; - - const role2 = ethers.utils.solidityPack( - ["address", "string"], - [arbitrumsepolia.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], - ); - - const roleHash2 = ethers.utils.keccak256(role2); - expect(await acm.hasRole(roleHash2, arbitrumsepolia.NORMAL_TIMELOCK)).to.be.true; - }); - }); -}); diff --git a/simulations/vip-373/bsctestnet.ts b/simulations/vip-373/bsctestnet.ts deleted file mode 100644 index e91202249..000000000 --- a/simulations/vip-373/bsctestnet.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { expectEvents } from "../../src/utils"; -import { forking, testVip } from "../../src/vip-framework"; -import vip373 from "../../vips/vip-373/bsctestnet"; -import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; - -forking(41938696, async () => { - testVip("vip372 XVS vault permission proposal", await vip373(), { - callbackAfterExecution: async txResponse => { - await expectEvents( - txResponse, - [OMNICHAIN_PROPOSAL_SENDER_ABI], - ["ExecuteRemoteProposal", "StorePayload"], - [3, 0], - ); - }, - }); -}); diff --git a/simulations/vip-373/opbnbtestnet.ts b/simulations/vip-373/opbnbtestnet.ts deleted file mode 100644 index a300e241b..000000000 --- a/simulations/vip-373/opbnbtestnet.ts +++ /dev/null @@ -1,49 +0,0 @@ -import { expect } from "chai"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { expectEvents } from "src/utils"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; - -import vip021, { ACM } from "../../multisig/proposals/opbnbtestnet/vip-021"; -import vip373, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-373/bsctestnet"; -import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; -import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; - -const { opbnbtestnet } = NETWORK_ADDRESSES; -forking(41162234, async () => { - before(async () => { - await pretendExecutingVip(await vip021()); - }); - - testForkedNetworkVipCommands("vip373", await vip373(), { - callbackAfterExecution: async txResponse => { - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [70]); - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [20]); - await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); - await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); - }, - }); - - describe("Post-VIP behaviour", async () => { - const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); - - it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { - expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; - }); - - it("check few permissions", async () => { - const role1 = ethers.utils.solidityPack(["address", "string"], [opbnbtestnet.RESILIENT_ORACLE, "pause()"]); - - const roleHash = ethers.utils.keccak256(role1); - expect(await acm.hasRole(roleHash, opbnbtestnet.NORMAL_TIMELOCK)).to.be.true; - - const role2 = ethers.utils.solidityPack( - ["address", "string"], - [opbnbtestnet.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], - ); - - const roleHash2 = ethers.utils.keccak256(role2); - expect(await acm.hasRole(roleHash2, opbnbtestnet.NORMAL_TIMELOCK)).to.be.true; - }); - }); -}); diff --git a/simulations/vip-373/sepolia.ts b/simulations/vip-373/sepolia.ts deleted file mode 100644 index a69fafa47..000000000 --- a/simulations/vip-373/sepolia.ts +++ /dev/null @@ -1,49 +0,0 @@ -import { expect } from "chai"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { expectEvents } from "src/utils"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; - -import vip060, { ACM } from "../../multisig/proposals/sepolia/vip-060"; -import vip373, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-373/bsctestnet"; -import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; -import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; - -const { sepolia } = NETWORK_ADDRESSES; -forking(6831661, async () => { - before(async () => { - await pretendExecutingVip(await vip060()); - }); - - testForkedNetworkVipCommands("vip373", await vip373(), { - callbackAfterExecution: async txResponse => { - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [95]); - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [42]); - await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); - await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); - }, - }); - - describe("Post-VIP behaviour", async () => { - const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); - - it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { - expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; - }); - - it("check few permissions", async () => { - const role1 = ethers.utils.solidityPack(["address", "string"], [sepolia.RESILIENT_ORACLE, "pause()"]); - - const roleHash = ethers.utils.keccak256(role1); - expect(await acm.hasRole(roleHash, sepolia.NORMAL_TIMELOCK)).to.be.true; - - const role2 = ethers.utils.solidityPack( - ["address", "string"], - [sepolia.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], - ); - - const roleHash2 = ethers.utils.keccak256(role2); - expect(await acm.hasRole(roleHash2, sepolia.NORMAL_TIMELOCK)).to.be.true; - }); - }); -}); diff --git a/vips/vip-372/bsctestnet.ts b/vips/vip-372/bsctestnet.ts index 88cee4bd9..584bbf913 100644 --- a/vips/vip-372/bsctestnet.ts +++ b/vips/vip-372/bsctestnet.ts @@ -25,6 +25,12 @@ export const SEPOLIA_BOUND_VALIDATOR = "0x60c4Aa92eEb6884a76b309Dd8B3731ad514d6f export const OPBNBTESTNET_BOUND_VALIDATOR = "0x049537Bb065e6253e9D8D08B45Bf6b753657A746"; export const SEPOLIA_sFrxETH_ORACLE = "0x61EB836afA467677e6b403D504fe69D6940e7996"; +export const ARBITRUMSEPOLIA_ACM_AGGREGATOR = "0x4fCbfE445396f31005b3Fd2F6DE2A986d6E2dCB5"; +export const OPBNBTESTNET_ACM_AGGREGATOR = "0xbDd501dB1B0D6aab299CE69ef5B86C8578947AD0"; +export const SEPOLIA_ACM_AGGREGATOR = "0x0653830c55035d678e1287b2d4550519fd263d0e"; + +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + const { arbitrumsepolia, sepolia, opbnbtestnet } = NETWORK_ADDRESSES; const vip372 = () => { @@ -178,6 +184,81 @@ const vip372 = () => { params: [], dstChainId: LzChainId.opbnbtestnet, }, + + { + target: ARBITRUM_SEPOLIA_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ARBITRUMSEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ARBITRUMSEPOLIA_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [1], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ARBITRUMSEPOLIA_ACM_AGGREGATOR, + signature: "executeRevokePermissions(uint256)", + params: [1], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ARBITRUM_SEPOLIA_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ARBITRUMSEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.arbitrumsepolia, + }, + + { + target: OPBNBTESTNET_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: OPBNBTESTNET_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: OPBNBTESTNET_ACM_AGGREGATOR, + signature: "executeRevokePermissions(uint256)", + params: [0], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: OPBNBTESTNET_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR], + dstChainId: LzChainId.opbnbtestnet, + }, + + { + target: SEPOLIA_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.sepolia, + }, + { + target: SEPOLIA_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.sepolia, + }, + { + target: SEPOLIA_ACM_AGGREGATOR, + signature: "executeRevokePermissions(uint256)", + params: [0], + dstChainId: LzChainId.sepolia, + }, + { + target: SEPOLIA_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.sepolia, + }, ], meta, ProposalType.REGULAR, diff --git a/vips/vip-373/bsctestnet.ts b/vips/vip-373/bsctestnet.ts deleted file mode 100644 index 134a0dbdc..000000000 --- a/vips/vip-373/bsctestnet.ts +++ /dev/null @@ -1,104 +0,0 @@ -import { LzChainId, ProposalType } from "src/types"; -import { makeProposal } from "src/utils"; - -export const SEPOLIA_ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; -export const ARBITRUM_SEPOLIA_ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; -export const OPBNBTESTNET_ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; - -export const ARBITRUMSEPOLIA_ACM_AGGREGATOR = "0x4fCbfE445396f31005b3Fd2F6DE2A986d6E2dCB5"; -export const OPBNBTESTNET_ACM_AGGREGATOR = "0xbDd501dB1B0D6aab299CE69ef5B86C8578947AD0"; -export const SEPOLIA_ACM_AGGREGATOR = "0x0653830c55035d678e1287b2d4550519fd263d0e"; - -export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; - -const vip372 = () => { - const meta = { - version: "v2", - title: "VIP-332 accept ownership & give permissions to Normal Timelock", - description: `### Description`, - forDescription: "I agree that Venus Protocol should proceed with this proposal", - againstDescription: "I do not think that Venus Protocol should proceed with this proposal", - abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", - }; - return makeProposal( - [ - { - target: ARBITRUM_SEPOLIA_ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, ARBITRUMSEPOLIA_ACM_AGGREGATOR], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: ARBITRUMSEPOLIA_ACM_AGGREGATOR, - signature: "executeGrantPermissions(uint256)", - params: [1], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: ARBITRUMSEPOLIA_ACM_AGGREGATOR, - signature: "executeRevokePermissions(uint256)", - params: [1], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: ARBITRUM_SEPOLIA_ACM, - signature: "revokeRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, ARBITRUMSEPOLIA_ACM_AGGREGATOR], - dstChainId: LzChainId.arbitrumsepolia, - }, - - { - target: OPBNBTESTNET_ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR], - dstChainId: LzChainId.opbnbtestnet, - }, - { - target: OPBNBTESTNET_ACM_AGGREGATOR, - signature: "executeGrantPermissions(uint256)", - params: [0], - dstChainId: LzChainId.opbnbtestnet, - }, - { - target: OPBNBTESTNET_ACM_AGGREGATOR, - signature: "executeRevokePermissions(uint256)", - params: [0], - dstChainId: LzChainId.opbnbtestnet, - }, - { - target: OPBNBTESTNET_ACM, - signature: "revokeRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR], - dstChainId: LzChainId.opbnbtestnet, - }, - - { - target: SEPOLIA_ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR], - dstChainId: LzChainId.sepolia, - }, - { - target: SEPOLIA_ACM_AGGREGATOR, - signature: "executeGrantPermissions(uint256)", - params: [0], - dstChainId: LzChainId.sepolia, - }, - { - target: SEPOLIA_ACM_AGGREGATOR, - signature: "executeRevokePermissions(uint256)", - params: [0], - dstChainId: LzChainId.sepolia, - }, - { - target: SEPOLIA_ACM, - signature: "revokeRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR], - dstChainId: LzChainId.sepolia, - }, - ], - meta, - ProposalType.REGULAR, - ); -}; -export default vip372; From 5b9a2447f70fac48adddb97f31d56ce6dede35cb Mon Sep 17 00:00:00 2001 From: Narayan <7037606+web3rover@users.noreply.github.com> Date: Thu, 10 Oct 2024 12:27:30 +0400 Subject: [PATCH 022/178] fix: added new markers for arb Co-authored-by: Jesus Lanchas --- multisig/proposals/arbitrumone/vip-014/index.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/multisig/proposals/arbitrumone/vip-014/index.ts b/multisig/proposals/arbitrumone/vip-014/index.ts index 72a353aca..dcf0d7af2 100644 --- a/multisig/proposals/arbitrumone/vip-014/index.ts +++ b/multisig/proposals/arbitrumone/vip-014/index.ts @@ -24,6 +24,9 @@ export const VTOKENS = [ "0xB9F9117d4200dC296F9AcD1e8bE1937df834a2fD", "0x7D8609f8da70fF9027E9bc5229Af4F6727662707", "0xAeB0FEd69354f34831fe1D16475D9A83ddaCaDA6", + "0x39D6d13Ea59548637104E40e729E4aABE27FE106", + "0x246a35E79a3a0618535A469aDaF5091cAA9f7E88", + "0x9df6B5132135f14719696bBAe3C54BAb272fDb16", ]; export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; From f509b10360d8f2c9f529dcafdc9a8af01697ad07 Mon Sep 17 00:00:00 2001 From: Narayan <7037606+web3rover@users.noreply.github.com> Date: Thu, 10 Oct 2024 12:27:41 +0400 Subject: [PATCH 023/178] fix: added new markers for arb Co-authored-by: Jesus Lanchas --- multisig/proposals/arbitrumsepolia/vip-014/index.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/multisig/proposals/arbitrumsepolia/vip-014/index.ts b/multisig/proposals/arbitrumsepolia/vip-014/index.ts index 5953a3f91..3154ab36d 100644 --- a/multisig/proposals/arbitrumsepolia/vip-014/index.ts +++ b/multisig/proposals/arbitrumsepolia/vip-014/index.ts @@ -23,6 +23,9 @@ export const VTOKENS = [ "0xdEFbf0F9Ab6CdDd0a1FdDC894b358D0c0a39B052", "0xd9d1e754464eFc7493B177d2c7be04816E089b4C", "0x292Ec2b45C549Bc2c6B31937dBd511beaAEabea8", + "0xd7057250b439c0849377bB6C3263eb8f9cf49d98", + "0x75f841b14305935D8D7E806f249D9FA52EF1550B", + "0x253515E19e8b888a4CA5a0a3363B712402ce4046", ]; export const BOUND_VALIDATOR = "0xfe6bc1545Cc14C131bacA97476D6035ffcC0b889"; From 10d71039a00efd9a663b30dcef5279f19f8b5ca2 Mon Sep 17 00:00:00 2001 From: Narayan <7037606+web3rover@users.noreply.github.com> Date: Thu, 10 Oct 2024 12:29:15 +0400 Subject: [PATCH 024/178] fix: added vweETH Co-authored-by: Jesus Lanchas --- multisig/proposals/ethereum/vip-061/index.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/multisig/proposals/ethereum/vip-061/index.ts b/multisig/proposals/ethereum/vip-061/index.ts index acf7b850c..ffe05ed09 100644 --- a/multisig/proposals/ethereum/vip-061/index.ts +++ b/multisig/proposals/ethereum/vip-061/index.ts @@ -59,6 +59,7 @@ export const VTOKENS = [ "0xc82780Db1257C788F262FBbDA960B3706Dfdcaf2", "0x4a240F0ee138697726C8a3E43eFE6Ac3593432CB", "0xb4933AF59868986316Ed37fa865C829Eba2df0C7", + "0xEF26C64bC06A8dE4CA5D31f119835f9A1d9433b9", ]; export const XVS_STORE = "0x1Db646E1Ab05571AF99e47e8F909801e5C99d37B"; export const XVS_BRIDGE_ADMIN_PROXY = "0x9C6C95632A8FB3A74f2fB4B7FfC50B003c992b96"; From b959873e4c9c95ff2acc7073d1bc282b12b9b534 Mon Sep 17 00:00:00 2001 From: Narayan <7037606+web3rover@users.noreply.github.com> Date: Thu, 10 Oct 2024 12:29:23 +0400 Subject: [PATCH 025/178] fix: added vweETH Co-authored-by: Jesus Lanchas --- multisig/proposals/sepolia/vip-060/index.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/multisig/proposals/sepolia/vip-060/index.ts b/multisig/proposals/sepolia/vip-060/index.ts index 928022f41..d7861599a 100644 --- a/multisig/proposals/sepolia/vip-060/index.ts +++ b/multisig/proposals/sepolia/vip-060/index.ts @@ -55,6 +55,7 @@ export const VTOKENS = [ "0x9C5e7a3B4db931F07A6534f9e44100DDDc78c408", "0xD5f83FCbb4a62779D0B37b9E603CD19Ad84884F0", "0x93dff2053D4B08823d8B39F1dCdf8497f15200f4", + "0xB3A201887396F57bad3fF50DFd02022fE1Fd1774", ]; export const XVS_STORE = "0x03B868C7858F50900fecE4eBc851199e957b5d3D"; export const XVS_BRIDGE_ADMIN_PROXY = "0xd3c6bdeeadB2359F726aD4cF42EAa8B7102DAd9B"; From 95b0e0df3a63e6ea05d1f7d57581891a359934ba Mon Sep 17 00:00:00 2001 From: web3rover Date: Thu, 10 Oct 2024 14:52:09 +0400 Subject: [PATCH 026/178] fix: split vips --- .../vip-371/abi/ACMCommandsAggregator.json | 242 +++++ .../vip-371/abi/AccessControlManager.json | 157 +++ .../vip-372/abi/ACMCommandsAggregator.json | 242 +++++ .../vip-372/abi/AccessControlManager.json | 157 +++ simulations/vip-372/arbitrumsepolia.ts | 46 +- simulations/vip-372/opbnbtestnet.ts | 38 - simulations/vip-372/sepolia.ts | 45 - .../vip-373/abi/ACMCommandsAggregator.json | 242 +++++ .../vip-373/abi/AccessControlManager.json | 157 +++ simulations/vip-373/abi/Comptroller.json | 929 ++++++++++++++++++ .../vip-373/abi/ComptrollerBeacon.json | 51 + simulations/vip-373/abi/ConverterNetwork.json | 205 ++++ .../vip-373/abi/DefaultProxyAdmin.json | 76 ++ .../vip-373/abi/OmnichainProposalSender.json | 314 ++++++ simulations/vip-373/abi/PoolRegistry.json | 379 +++++++ simulations/vip-373/abi/Prime.json | 763 ++++++++++++++ .../vip-373/abi/PrimeLiquidityProvider.json | 385 ++++++++ .../vip-373/abi/ProtocolShareReserve.json | 356 +++++++ .../vip-373/abi/RewardDistributor.json | 532 ++++++++++ .../vip-373/abi/SingleTokenConverter.json | 587 +++++++++++ .../abi/SingleTokenConverterBeacon.json | 51 + simulations/vip-373/abi/VToken.json | 861 ++++++++++++++++ simulations/vip-373/abi/VTokenBeacon.json | 51 + simulations/vip-373/abi/XVSStore.json | 130 +++ simulations/vip-373/abi/XVSVault.json | 787 +++++++++++++++ simulations/vip-373/abi/XVSVaultProxy.json | 122 +++ simulations/vip-373/abi/binanceOracle.json | 284 ++++++ simulations/vip-373/abi/boundValidator.json | 498 ++++++++++ simulations/vip-373/abi/chainlinkOracle.json | 459 +++++++++ simulations/vip-373/abi/resilientOracle.json | 640 ++++++++++++ simulations/vip-373/abi/sFrxETHOracle.json | 148 +++ simulations/vip-373/abi/treasury.json | 86 ++ simulations/vip-373/abi/xvs.json | 716 ++++++++++++++ simulations/vip-373/abi/xvsBridge.json | 807 +++++++++++++++ simulations/vip-373/abi/xvsBridgeAdmin.json | 329 +++++++ .../{vip-372 => vip-373}/arbitrumone.ts | 4 +- simulations/vip-373/arbitrumsepolia.ts | 63 ++ .../{vip-372 => vip-373}/bscmainnet.ts | 4 +- simulations/vip-373/bsctestnet.ts | 17 + simulations/{vip-372 => vip-373}/ethereum.ts | 6 +- .../{vip-372 => vip-373}/opbnbmainnet.ts | 4 +- simulations/vip-373/opbnbtestnet.ts | 60 ++ simulations/vip-373/sepolia.ts | 66 ++ vips/vip-372/bsctestnet.ts | 162 --- vips/{vip-372 => vip-373}/bscmainnet.ts | 8 +- vips/vip-373/bsctestnet.ts | 192 ++++ 46 files changed, 12156 insertions(+), 302 deletions(-) create mode 100644 simulations/vip-371/abi/ACMCommandsAggregator.json create mode 100644 simulations/vip-371/abi/AccessControlManager.json create mode 100644 simulations/vip-372/abi/ACMCommandsAggregator.json create mode 100644 simulations/vip-372/abi/AccessControlManager.json create mode 100644 simulations/vip-373/abi/ACMCommandsAggregator.json create mode 100644 simulations/vip-373/abi/AccessControlManager.json create mode 100644 simulations/vip-373/abi/Comptroller.json create mode 100644 simulations/vip-373/abi/ComptrollerBeacon.json create mode 100644 simulations/vip-373/abi/ConverterNetwork.json create mode 100644 simulations/vip-373/abi/DefaultProxyAdmin.json create mode 100644 simulations/vip-373/abi/OmnichainProposalSender.json create mode 100644 simulations/vip-373/abi/PoolRegistry.json create mode 100644 simulations/vip-373/abi/Prime.json create mode 100644 simulations/vip-373/abi/PrimeLiquidityProvider.json create mode 100644 simulations/vip-373/abi/ProtocolShareReserve.json create mode 100644 simulations/vip-373/abi/RewardDistributor.json create mode 100644 simulations/vip-373/abi/SingleTokenConverter.json create mode 100644 simulations/vip-373/abi/SingleTokenConverterBeacon.json create mode 100644 simulations/vip-373/abi/VToken.json create mode 100644 simulations/vip-373/abi/VTokenBeacon.json create mode 100644 simulations/vip-373/abi/XVSStore.json create mode 100644 simulations/vip-373/abi/XVSVault.json create mode 100644 simulations/vip-373/abi/XVSVaultProxy.json create mode 100644 simulations/vip-373/abi/binanceOracle.json create mode 100644 simulations/vip-373/abi/boundValidator.json create mode 100644 simulations/vip-373/abi/chainlinkOracle.json create mode 100644 simulations/vip-373/abi/resilientOracle.json create mode 100644 simulations/vip-373/abi/sFrxETHOracle.json create mode 100644 simulations/vip-373/abi/treasury.json create mode 100644 simulations/vip-373/abi/xvs.json create mode 100644 simulations/vip-373/abi/xvsBridge.json create mode 100644 simulations/vip-373/abi/xvsBridgeAdmin.json rename simulations/{vip-372 => vip-373}/arbitrumone.ts (95%) create mode 100644 simulations/vip-373/arbitrumsepolia.ts rename simulations/{vip-372 => vip-373}/bscmainnet.ts (79%) create mode 100644 simulations/vip-373/bsctestnet.ts rename simulations/{vip-372 => vip-373}/ethereum.ts (96%) rename simulations/{vip-372 => vip-373}/opbnbmainnet.ts (95%) create mode 100644 simulations/vip-373/opbnbtestnet.ts create mode 100644 simulations/vip-373/sepolia.ts rename vips/{vip-372 => vip-373}/bscmainnet.ts (97%) create mode 100644 vips/vip-373/bsctestnet.ts diff --git a/simulations/vip-371/abi/ACMCommandsAggregator.json b/simulations/vip-371/abi/ACMCommandsAggregator.json new file mode 100644 index 000000000..6650a3f3c --- /dev/null +++ b/simulations/vip-371/abi/ACMCommandsAggregator.json @@ -0,0 +1,242 @@ +[ + { + "inputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "_acm", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [], + "name": "EmptyPermissions", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "GrantPermissionsAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "GrantPermissionsExecuted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "RevokePermissionsAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "RevokePermissionsExecuted", + "type": "event" + }, + { + "inputs": [], + "name": "ACM", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "internalType": "struct ACMCommandsAggregator.Permission[]", + "name": "_permissions", + "type": "tuple[]" + } + ], + "name": "addGrantPermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "internalType": "struct ACMCommandsAggregator.Permission[]", + "name": "_permissions", + "type": "tuple[]" + } + ], + "name": "addRevokePermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "executeGrantPermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "executeRevokePermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "grantPermissions", + "outputs": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "revokePermissions", + "outputs": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-371/abi/AccessControlManager.json b/simulations/vip-371/abi/AccessControlManager.json new file mode 100644 index 000000000..2ef119947 --- /dev/null +++ b/simulations/vip-371/abi/AccessControlManager.json @@ -0,0 +1,157 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } + ], + "name": "RoleAdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleRevoked", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_ADMIN_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleAdmin", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToPermit", "type": "address" } + ], + "name": "giveCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "grantRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "hasPermission", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "hasRole", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "isAllowedToCall", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "renounceRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToRevoke", "type": "address" } + ], + "name": "revokeCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "revokeRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], + "name": "supportsInterface", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/ACMCommandsAggregator.json b/simulations/vip-372/abi/ACMCommandsAggregator.json new file mode 100644 index 000000000..6650a3f3c --- /dev/null +++ b/simulations/vip-372/abi/ACMCommandsAggregator.json @@ -0,0 +1,242 @@ +[ + { + "inputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "_acm", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [], + "name": "EmptyPermissions", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "GrantPermissionsAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "GrantPermissionsExecuted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "RevokePermissionsAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "RevokePermissionsExecuted", + "type": "event" + }, + { + "inputs": [], + "name": "ACM", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "internalType": "struct ACMCommandsAggregator.Permission[]", + "name": "_permissions", + "type": "tuple[]" + } + ], + "name": "addGrantPermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "internalType": "struct ACMCommandsAggregator.Permission[]", + "name": "_permissions", + "type": "tuple[]" + } + ], + "name": "addRevokePermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "executeGrantPermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "executeRevokePermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "grantPermissions", + "outputs": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "revokePermissions", + "outputs": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-372/abi/AccessControlManager.json b/simulations/vip-372/abi/AccessControlManager.json new file mode 100644 index 000000000..2ef119947 --- /dev/null +++ b/simulations/vip-372/abi/AccessControlManager.json @@ -0,0 +1,157 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } + ], + "name": "RoleAdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleRevoked", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_ADMIN_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleAdmin", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToPermit", "type": "address" } + ], + "name": "giveCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "grantRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "hasPermission", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "hasRole", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "isAllowedToCall", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "renounceRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToRevoke", "type": "address" } + ], + "name": "revokeCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "revokeRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], + "name": "supportsInterface", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-372/arbitrumsepolia.ts b/simulations/vip-372/arbitrumsepolia.ts index aebfa8711..972bc23a6 100644 --- a/simulations/vip-372/arbitrumsepolia.ts +++ b/simulations/vip-372/arbitrumsepolia.ts @@ -1,5 +1,4 @@ import { expect } from "chai"; -import { Contract } from "ethers"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; @@ -7,48 +6,22 @@ import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/ import vip014, { ACM } from "../../multisig/proposals/arbitrumsepolia/vip-014"; import vip372, { - ARBITRUM_SEPOLIA_BOUND_VALIDATOR, - ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN, DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR, } from "../../vips/vip-372/bsctestnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; -import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; -import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; -import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; -import TREASURY_ABI from "./abi/treasury.json"; -import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; -import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; - -const XVS_BRIDGE = "0xFdC5cEC63FD167DA46cF006585b30D03B104eFD4"; const { arbitrumsepolia } = NETWORK_ADDRESSES; forking(86016842, async () => { - const provider = ethers.provider; - let chainLinkOracle: Contract; - let redstoneOracle: Contract; - let resilientOracle: Contract; - let boundValidator: Contract; - let xvsBridgeAdmin: Contract; - let xvsBridge: Contract; - let treasury: Contract; before(async () => { - chainLinkOracle = new ethers.Contract(arbitrumsepolia.CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); - redstoneOracle = new ethers.Contract(arbitrumsepolia.REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); - resilientOracle = new ethers.Contract(arbitrumsepolia.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); - boundValidator = new ethers.Contract(ARBITRUM_SEPOLIA_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); - xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN); - xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); - treasury = await ethers.getContractAt(TREASURY_ABI, arbitrumsepolia.VTREASURY); - await pretendExecutingVip(await vip014()); }); testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip372(), { callbackAfterExecution: async txResponse => { - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [70]); - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [20]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [84]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [35]); await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); }, @@ -75,20 +48,5 @@ forking(86016842, async () => { const roleHash2 = ethers.utils.keccak256(role2); expect(await acm.hasRole(roleHash2, arbitrumsepolia.NORMAL_TIMELOCK)).to.be.true; }); - it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { - expect(await xvsBridgeAdmin.owner()).to.be.equals(arbitrumsepolia.NORMAL_TIMELOCK); - }); - it("Normal Timelock should be whitelisted", async () => { - expect(await xvsBridge.whitelist(arbitrumsepolia.NORMAL_TIMELOCK)).to.be.true; - }); - it("oracles should have correct owner", async () => { - expect(await resilientOracle.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); - expect(await chainLinkOracle.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); - expect(await redstoneOracle.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); - expect(await boundValidator.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); - }); - it("Normal Timelock should be the owner of the Vtreasury", async () => { - expect(await treasury.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); - }); }); }); diff --git a/simulations/vip-372/opbnbtestnet.ts b/simulations/vip-372/opbnbtestnet.ts index 7a500dbdf..a333cfb73 100644 --- a/simulations/vip-372/opbnbtestnet.ts +++ b/simulations/vip-372/opbnbtestnet.ts @@ -1,5 +1,4 @@ import { expect } from "chai"; -import { Contract } from "ethers"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; @@ -9,36 +8,14 @@ import vip021, { ACM } from "../../multisig/proposals/opbnbtestnet/vip-021"; import vip372, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR, - OPBNBTESTNET_BOUND_VALIDATOR, - OPBNBTESTNET_XVS_BRIDGE_ADMIN, } from "../../vips/vip-372/bsctestnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; -import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; -import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; -import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; -import TREASURY_ABI from "./abi/treasury.json"; -import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; -import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; -const XVS_BRIDGE = "0xA03205bC635A772E533E7BE36b5701E331a70ea3"; const { opbnbtestnet } = NETWORK_ADDRESSES; forking(41162234, async () => { - const provider = ethers.provider; - let binanceOracle: Contract; - let resilientOracle: Contract; - let boundValidator: Contract; - let treasury: Contract; - let xvsBridgeAdmin: Contract; - let xvsBridge: Contract; before(async () => { - binanceOracle = new ethers.Contract(opbnbtestnet.BINANCE_ORACLE, CHAINLINK_ORACLE_ABI, provider); - resilientOracle = new ethers.Contract(opbnbtestnet.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); - boundValidator = new ethers.Contract(OPBNBTESTNET_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); - xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, OPBNBTESTNET_XVS_BRIDGE_ADMIN); - xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); - treasury = await ethers.getContractAt(TREASURY_ABI, opbnbtestnet.VTREASURY); await pretendExecutingVip(await vip021()); }); @@ -72,20 +49,5 @@ forking(41162234, async () => { const roleHash2 = ethers.utils.keccak256(role2); expect(await acm.hasRole(roleHash2, opbnbtestnet.NORMAL_TIMELOCK)).to.be.true; }); - - it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { - expect(await xvsBridgeAdmin.owner()).to.be.equals(opbnbtestnet.NORMAL_TIMELOCK); - }); - it("Normal Timelock should be whitelisted", async () => { - expect(await xvsBridge.whitelist(opbnbtestnet.NORMAL_TIMELOCK)).to.be.true; - }); - it("oracles should have correct owner", async () => { - expect(await resilientOracle.owner()).equals(opbnbtestnet.NORMAL_TIMELOCK); - expect(await binanceOracle.owner()).equals(opbnbtestnet.NORMAL_TIMELOCK); - expect(await boundValidator.owner()).equals(opbnbtestnet.NORMAL_TIMELOCK); - }); - it("Normal Timelock should be the owner of the Vtreasury", async () => { - expect(await treasury.owner()).equals(opbnbtestnet.NORMAL_TIMELOCK); - }); }); }); diff --git a/simulations/vip-372/sepolia.ts b/simulations/vip-372/sepolia.ts index 4fd043e4f..592551a4c 100644 --- a/simulations/vip-372/sepolia.ts +++ b/simulations/vip-372/sepolia.ts @@ -1,5 +1,4 @@ import { expect } from "chai"; -import { Contract } from "ethers"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; @@ -9,37 +8,14 @@ import vip060, { ACM } from "../../multisig/proposals/sepolia/vip-060"; import vip372, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR, - SEPOLIA_BOUND_VALIDATOR, - SEPOLIA_XVS_BRIDGE_ADMIN, - SEPOLIA_sFrxETH_ORACLE, } from "../../vips/vip-372/bsctestnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; -import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; -import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; -import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; -import SFRAXETH_ORACLE_ABI from "./abi/sFrxETHOracle.json"; -import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; -import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; -const XVS_BRIDGE = "0xc340b7d3406502F43dC11a988E4EC5bbE536E642"; const { sepolia } = NETWORK_ADDRESSES; forking(6831661, async () => { - const provider = ethers.provider; - let chainLinkOracle: Contract; - let redstoneOracle: Contract; - let resilientOracle: Contract; - let boundValidator: Contract; - let sfraxETH: Contract; - before(async () => { - chainLinkOracle = new ethers.Contract(sepolia.CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); - redstoneOracle = new ethers.Contract(sepolia.REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); - resilientOracle = new ethers.Contract(sepolia.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); - boundValidator = new ethers.Contract(SEPOLIA_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); - sfraxETH = new ethers.Contract(SEPOLIA_sFrxETH_ORACLE, SFRAXETH_ORACLE_ABI, provider); - await pretendExecutingVip(await vip060()); }); @@ -53,14 +29,7 @@ forking(6831661, async () => { }); describe("Post-VIP behaviour", async () => { - let xvsBridgeAdmin: Contract; - let xvsBridge: Contract; const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); - before(async () => { - xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, SEPOLIA_XVS_BRIDGE_ADMIN); - xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); - }); - it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; }); @@ -79,19 +48,5 @@ forking(6831661, async () => { const roleHash2 = ethers.utils.keccak256(role2); expect(await acm.hasRole(roleHash2, sepolia.NORMAL_TIMELOCK)).to.be.true; }); - - it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { - expect(await xvsBridgeAdmin.owner()).to.be.equals(sepolia.NORMAL_TIMELOCK); - }); - it("Normal Timelock should be whitelisted", async () => { - expect(await xvsBridge.whitelist(sepolia.NORMAL_TIMELOCK)).to.be.true; - }); - it("oracles should have correct owner", async () => { - expect(await resilientOracle.owner()).equals(sepolia.NORMAL_TIMELOCK); - expect(await chainLinkOracle.owner()).equals(sepolia.NORMAL_TIMELOCK); - expect(await redstoneOracle.owner()).equals(sepolia.NORMAL_TIMELOCK); - expect(await boundValidator.owner()).equals(sepolia.NORMAL_TIMELOCK); - expect(await sfraxETH.owner()).equals(sepolia.NORMAL_TIMELOCK); - }); }); }); diff --git a/simulations/vip-373/abi/ACMCommandsAggregator.json b/simulations/vip-373/abi/ACMCommandsAggregator.json new file mode 100644 index 000000000..6650a3f3c --- /dev/null +++ b/simulations/vip-373/abi/ACMCommandsAggregator.json @@ -0,0 +1,242 @@ +[ + { + "inputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "_acm", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [], + "name": "EmptyPermissions", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "GrantPermissionsAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "GrantPermissionsExecuted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "RevokePermissionsAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "RevokePermissionsExecuted", + "type": "event" + }, + { + "inputs": [], + "name": "ACM", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "internalType": "struct ACMCommandsAggregator.Permission[]", + "name": "_permissions", + "type": "tuple[]" + } + ], + "name": "addGrantPermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "internalType": "struct ACMCommandsAggregator.Permission[]", + "name": "_permissions", + "type": "tuple[]" + } + ], + "name": "addRevokePermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "executeGrantPermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "executeRevokePermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "grantPermissions", + "outputs": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "revokePermissions", + "outputs": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/AccessControlManager.json b/simulations/vip-373/abi/AccessControlManager.json new file mode 100644 index 000000000..2ef119947 --- /dev/null +++ b/simulations/vip-373/abi/AccessControlManager.json @@ -0,0 +1,157 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } + ], + "name": "RoleAdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleRevoked", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_ADMIN_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleAdmin", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToPermit", "type": "address" } + ], + "name": "giveCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "grantRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "hasPermission", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "hasRole", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "isAllowedToCall", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "renounceRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToRevoke", "type": "address" } + ], + "name": "revokeCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "revokeRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], + "name": "supportsInterface", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/Comptroller.json b/simulations/vip-373/abi/Comptroller.json new file mode 100644 index 000000000..f3b2445ac --- /dev/null +++ b/simulations/vip-373/abi/Comptroller.json @@ -0,0 +1,929 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, + { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, + { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, + { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, + { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, + { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "TooMuchRepay", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "expectedSender", "type": "address" }, + { "internalType": "address", "name": "actualSender", "type": "address" } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, + { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "accountAssets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "actionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allMarkets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "approvedDelegates", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "borrowCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "contract VToken", "name": "vToken", "type": "address" } + ], + "name": "checkMembership", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], + "name": "enterMarkets", + "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], + "name": "exitMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAssetsIn", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getBorrowingPower", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "vTokenModify", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isForcedLiquidationEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "isMarketListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [ + { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "bool", "name": "isListed", "type": "bool" }, + { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "seizerContract", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, + { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, + { "internalType": "bool", "name": "paused", "type": "bool" } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "supplyCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "delegate", "type": "address" }, + { "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/ComptrollerBeacon.json b/simulations/vip-373/abi/ComptrollerBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/simulations/vip-373/abi/ComptrollerBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/ConverterNetwork.json b/simulations/vip-373/abi/ConverterNetwork.json new file mode 100644 index 000000000..396f12a91 --- /dev/null +++ b/simulations/vip-373/abi/ConverterNetwork.json @@ -0,0 +1,205 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { "inputs": [], "name": "ConverterAlreadyExists", "type": "error" }, + { "inputs": [], "name": "ConverterDoesNotExist", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "InvalidMaxLoopsLimit", + "type": "error" + }, + { "inputs": [], "name": "InvalidTokenConverterAddress", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], + "name": "ConverterAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], + "name": "ConverterRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], + "name": "addTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allConverters", + "outputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } + ], + "name": "findTokenConverters", + "outputs": [ + { "internalType": "address[]", "name": "converters", "type": "address[]" }, + { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } + ], + "name": "findTokenConvertersForConverters", + "outputs": [ + { "internalType": "address[]", "name": "converters", "type": "address[]" }, + { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getAllConverters", + "outputs": [{ "internalType": "contract IAbstractTokenConverter[]", "name": "converters", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_tokenConverter", "type": "address" }], + "name": "isTokenConverter", + "outputs": [{ "internalType": "bool", "name": "isConverter", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], + "name": "removeTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/DefaultProxyAdmin.json b/simulations/vip-373/abi/DefaultProxyAdmin.json new file mode 100644 index 000000000..9801cfcc7 --- /dev/null +++ b/simulations/vip-373/abi/DefaultProxyAdmin.json @@ -0,0 +1,76 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "changeProxyAdmin", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], + "name": "getProxyImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" } + ], + "name": "upgrade", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, + { "internalType": "address", "name": "implementation", "type": "address" }, + { "internalType": "bytes", "name": "data", "type": "bytes" } + ], + "name": "upgradeAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/OmnichainProposalSender.json b/simulations/vip-373/abi/OmnichainProposalSender.json new file mode 100644 index 000000000..66fd4df02 --- /dev/null +++ b/simulations/vip-373/abi/OmnichainProposalSender.json @@ -0,0 +1,314 @@ +[ + { + "inputs": [ + { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } + ], + "name": "ClearPayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } + ], + "name": "ExecuteRemoteProposal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "FallbackWithdraw", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } + ], + "name": "StorePayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], + "name": "TrustedRemoteRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "LZ_ENDPOINT", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourCommandsSent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLastProposalSentTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bool", "name": "useZro_", "type": "bool" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } + ], + "name": "estimateFees", + "outputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } + ], + "name": "execute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "fallbackWithdraw", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "proposalCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], + "name": "removeTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "retryExecute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" }, + { "internalType": "bytes", "name": "config_", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "storedExecutionHashes", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } +] diff --git a/simulations/vip-373/abi/PoolRegistry.json b/simulations/vip-373/abi/PoolRegistry.json new file mode 100644 index 000000000..31b1e2a17 --- /dev/null +++ b/simulations/vip-373/abi/PoolRegistry.json @@ -0,0 +1,379 @@ +[ + { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, + { + "name": "Unauthorized", + "type": "error", + "inputs": [ + { "name": "sender", "type": "address", "internalType": "address" }, + { "name": "calledContract", "type": "address", "internalType": "address" }, + { "name": "methodSignature", "type": "string", "internalType": "string" } + ] + }, + { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, + { + "name": "Initialized", + "type": "event", + "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], + "anonymous": false, + "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" + }, + { + "name": "MarketAdded", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" + }, + { + "name": "NewAccessControlManager", + "type": "event", + "inputs": [ + { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, + { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" + }, + { + "name": "OwnershipTransferStarted", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" + }, + { + "name": "OwnershipTransferred", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" + }, + { + "name": "PoolMetadataUpdated", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "oldMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + }, + { + "name": "newMetadata", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "anonymous": false, + "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" + }, + { + "name": "PoolNameSet", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, + { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } + ], + "anonymous": false, + "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" + }, + { + "name": "PoolRegistered", + "type": "event", + "inputs": [ + { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, + { + "name": "pool", + "type": "tuple", + "indexed": false, + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "anonymous": false, + "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" + }, + { + "name": "acceptOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x79ba5097", + "stateMutability": "nonpayable" + }, + { + "name": "accessControlManager", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "contract IAccessControlManagerV8" + } + ], + "constant": true, + "signature": "0xb4a0bdf3", + "stateMutability": "view" + }, + { + "name": "addMarket", + "type": "function", + "inputs": [ + { + "name": "input", + "type": "tuple", + "components": [ + { "name": "vToken", "type": "address", "internalType": "contract VToken" }, + { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, + { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, + { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, + { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, + { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistry.AddMarketInput" + } + ], + "outputs": [], + "signature": "0x23dc8d64", + "stateMutability": "nonpayable" + }, + { + "name": "addPool", + "type": "function", + "inputs": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, + { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, + { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, + { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } + ], + "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], + "signature": "0xeed873c2", + "stateMutability": "nonpayable" + }, + { + "name": "getAllPools", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "tuple[]", + "value": [], + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool[]" + } + ], + "constant": true, + "signature": "0xd88ff1f4", + "stateMutability": "view" + }, + { + "name": "getPoolByComptroller", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "name", "type": "string", "internalType": "string" }, + { "name": "creator", "type": "address", "internalType": "address" }, + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, + { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool" + } + ], + "constant": true, + "signature": "0x7aee632d", + "stateMutability": "view" + }, + { + "name": "getPoolsSupportedByAsset", + "type": "function", + "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], + "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], + "constant": true, + "signature": "0xf36dba38", + "stateMutability": "view" + }, + { + "name": "getVTokenForAsset", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "asset", "type": "address", "internalType": "address" } + ], + "outputs": [{ "name": "", "type": "address", "internalType": "address" }], + "constant": true, + "signature": "0x266e0a7f", + "stateMutability": "view" + }, + { + "name": "getVenusPoolMetadata", + "type": "function", + "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], + "outputs": [ + { + "name": "", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "constant": true, + "signature": "0xa3aefa2c", + "stateMutability": "view" + }, + { + "name": "initialize", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xc4d66de8", + "stateMutability": "nonpayable" + }, + { + "name": "metadata", + "type": "function", + "inputs": [{ "name": "", "type": "address", "internalType": "address" }], + "outputs": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "constant": true, + "signature": "0x2ba21572", + "stateMutability": "view" + }, + { + "name": "owner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x8da5cb5b", + "stateMutability": "view" + }, + { + "name": "pendingOwner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0xe30c3978", + "stateMutability": "view" + }, + { + "name": "renounceOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x715018a6", + "stateMutability": "nonpayable" + }, + { + "name": "setAccessControlManager", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0x0e32cb86", + "stateMutability": "nonpayable" + }, + { + "name": "setPoolName", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { "name": "name", "type": "string", "internalType": "string" } + ], + "outputs": [], + "signature": "0x1cb6bb7e", + "stateMutability": "nonpayable" + }, + { + "name": "transferOwnership", + "type": "function", + "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xf2fde38b", + "stateMutability": "nonpayable" + }, + { + "name": "updatePoolMetadata", + "type": "function", + "inputs": [ + { "name": "comptroller", "type": "address", "internalType": "address" }, + { + "name": "metadata_", + "type": "tuple", + "components": [ + { "name": "category", "type": "string", "internalType": "string" }, + { "name": "logoURL", "type": "string", "internalType": "string" }, + { "name": "description", "type": "string", "internalType": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" + } + ], + "outputs": [], + "signature": "0xff94d958", + "stateMutability": "nonpayable" + } +] diff --git a/simulations/vip-373/abi/Prime.json b/simulations/vip-373/abi/Prime.json new file mode 100644 index 000000000..e8bfa99ff --- /dev/null +++ b/simulations/vip-373/abi/Prime.json @@ -0,0 +1,763 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, + { "internalType": "address", "name": "_nativeMarket", "type": "address" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, + { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, + { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, + { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, + { "internalType": "bool", "name": "_timeBased", "type": "bool" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, + { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidComptroller", "type": "error" }, + { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "n", "type": "uint256" }, + { "internalType": "uint256", "name": "d", "type": "uint256" } + ], + "name": "InvalidFraction", + "type": "error" + }, + { "inputs": [], "name": "InvalidLength", "type": "error" }, + { "inputs": [], "name": "InvalidLimit", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, + { "inputs": [], "name": "InvalidVToken", "type": "error" }, + { + "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], + "name": "LnNonRealResult", + "type": "error" + }, + { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, + { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, + { "inputs": [], "name": "MarketNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, + { "inputs": [], "name": "WaitMoreTime", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, + { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, + { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } + ], + "name": "AlphaUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "Burn", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "InterestClaimed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } + ], + "name": "MintLimitsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, + { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } + ], + "name": "MultiplierUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } + ], + "name": "StakedAtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "TokenUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], + "name": "UserScoreUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "MAXIMUM_XVS_CAP", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MINIMUM_STAKED_XVS", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_MARKET", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "STAKING_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WRAPPED_NATIVE_TOKEN", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "accrueInterest", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" } + ], + "name": "accrueInterestAndUpdateScore", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "alphaDenominator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "alphaNumerator", + "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "calculateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "claimInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "claimTimeRemaining", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "uint256", "name": "borrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supply", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } + ], + "name": "estimateAPR", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, + { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, + { "internalType": "uint256", "name": "userScore", "type": "uint256" }, + { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, + { "internalType": "uint256", "name": "capital", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, + { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, + { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "getInterestAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "getPendingRewards", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "internalType": "struct PrimeStorageV1.PendingReward[]", + "name": "pendingRewards", + "type": "tuple[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "incomeDistributionYearly", + "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "xvsVault_", "type": "address" }, + { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, + { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, + { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, + { "internalType": "address", "name": "comptroller_", "type": "address" }, + { "internalType": "address", "name": "oracle_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "name": "initializeV2", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "interests", + "outputs": [ + { "internalType": "uint256", "name": "accrued", "type": "uint256" }, + { "internalType": "uint256", "name": "score", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "irrevocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "isScoreUpdated", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "isUserPrimeHolder", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, + { "internalType": "address[]", "name": "users", "type": "address[]" } + ], + "name": "issue", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, + { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, + { "internalType": "bool", "name": "exists", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "nextScoreUpdateRoundId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingScoreUpdates", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "primeLiquidityProvider", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "revocableLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } + ], + "name": "setLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "users", "type": "address[]" }, + { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } + ], + "name": "setStakedAt", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "stakedAt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokens", + "outputs": [ + { "internalType": "bool", "name": "exists", "type": "bool" }, + { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalIrrevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalRevocable", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalScoreUpdatesRequired", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "unreleasedPLPIncome", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, + { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } + ], + "name": "updateAlpha", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } + ], + "name": "updateMultipliers", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], + "name": "updateScores", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "vTokenForAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "xvsUpdated", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVault", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultPoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/PrimeLiquidityProvider.json b/simulations/vip-373/abi/PrimeLiquidityProvider.json new file mode 100644 index 000000000..02ca8e0bf --- /dev/null +++ b/simulations/vip-373/abi/PrimeLiquidityProvider.json @@ -0,0 +1,385 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "_timeBased", "type": "bool" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, + { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "balance", "type": "uint256" } + ], + "name": "InsufficientBalance", + "type": "error" + }, + { "inputs": [], "name": "InvalidArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidCaller", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "speed", "type": "uint256" }, + { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } + ], + "name": "InvalidDistributionSpeed", + "type": "error" + }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenAlreadyInitialized", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "TokenNotInitialized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "MaxTokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } + ], + "name": "PrimeTokenUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenDistributionInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "TokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokenTransferredToPrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokensAccrued", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "accrueTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "getEffectiveDistributionSpeed", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], + "name": "initializeTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "lastAccruedBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastAccruedBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "maxTokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } + ], + "name": "setMaxTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } + ], + "name": "setTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "tokenAmountAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/ProtocolShareReserve.json b/simulations/vip-373/abi/ProtocolShareReserve.json new file mode 100644 index 000000000..b33d7c495 --- /dev/null +++ b/simulations/vip-373/abi/ProtocolShareReserve.json @@ -0,0 +1,356 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, + { "internalType": "address", "name": "_wbnb", "type": "address" }, + { "internalType": "address", "name": "_vbnb", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetReleased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IProtocolShareReserve.IncomeType", + "name": "incomeType", + "type": "uint8" + }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "AssetsReservesUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, + { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "DistributionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } + ], + "name": "PoolRegistryUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "ReservesUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "CORE_POOL_COMPTROLLER", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MAX_PERCENT", + "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "internalType": "struct ProtocolShareReserve.DistributionConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "addOrUpdateDistributionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } + ], + "name": "assetsReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "distributionTargets", + "outputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "uint16", "name": "percentage", "type": "uint16" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } + ], + "name": "getPercentageDistribution", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "getUnreleasedFunds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address[]", "name": "assets", "type": "address[]" } + ], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, + { "internalType": "address", "name": "destination", "type": "address" } + ], + "name": "removeDistributionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], + "name": "setPoolRegistry", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAssetReserve", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalDistributions", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBNB", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/RewardDistributor.json b/simulations/vip-373/abi/RewardDistributor.json new file mode 100644 index 000000000..249fdd111 --- /dev/null +++ b/simulations/vip-373/abi/RewardDistributor.json @@ -0,0 +1,532 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "BorrowLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "BorrowLastRewardingBlockUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "ContributorRewardTokenSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } + ], + "name": "ContributorRewardsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } + ], + "name": "DistributedBorrowerRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } + ], + "name": "DistributedSupplierRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "MarketInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "indexed": false, + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "RewardTokenBorrowIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenBorrowSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RewardTokenGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "RewardTokenSupplyIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "RewardTokenSupplySpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } + ], + "name": "SupplyLastRewardingBlockTimestampUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } + ], + "name": "SupplyLastRewardingBlockUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "INITIAL_INDEX", + "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "holder", "type": "address" }, + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } + ], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "distributeBorrowerRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "supplier", "type": "address" } + ], + "name": "distributeSupplierRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "grantRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, + { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "initializeMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastContributorBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "rewardToken", + "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenBorrowStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenBorrowerIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenContributorSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "rewardTokenSupplierIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplySpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyState", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint32", "name": "block", "type": "uint32" }, + { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenSupplyStateTimeBased", + "outputs": [ + { "internalType": "uint224", "name": "index", "type": "uint224" }, + { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contributor", "type": "address" }, + { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } + ], + "name": "setContributorRewardTokenSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } + ], + "name": "setLastRewardingBlockTimestamps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, + { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } + ], + "name": "setLastRewardingBlocks", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } + ], + "name": "setRewardTokenSpeeds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], + "name": "updateContributorRewards", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { + "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "updateRewardTokenBorrowIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "updateRewardTokenSupplyIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/SingleTokenConverter.json b/simulations/vip-373/abi/SingleTokenConverter.json new file mode 100644 index 000000000..8ea10cc8d --- /dev/null +++ b/simulations/vip-373/abi/SingleTokenConverter.json @@ -0,0 +1,587 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { "inputs": [], "name": "AmountInMismatched", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, + { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, + { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, + { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, + { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, + { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, + { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, + { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, + { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, + { "inputs": [], "name": "InvalidToAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, + { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetTransferredToDestination", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } + ], + "name": "BaseAssetUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, + { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "baseAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "conversionConfigurations", + "outputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, + { "internalType": "address", "name": "destinationAddress_", "type": "address" }, + { "internalType": "address", "name": "baseAsset_", "type": "address" }, + { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], + "name": "setBaseAsset", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/SingleTokenConverterBeacon.json b/simulations/vip-373/abi/SingleTokenConverterBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/simulations/vip-373/abi/SingleTokenConverterBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/VToken.json b/simulations/vip-373/abi/VToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/simulations/vip-373/abi/VToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/VTokenBeacon.json b/simulations/vip-373/abi/VTokenBeacon.json new file mode 100644 index 000000000..fe7f3e52f --- /dev/null +++ b/simulations/vip-373/abi/VTokenBeacon.json @@ -0,0 +1,51 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], + "name": "Upgraded", + "type": "event" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/XVSStore.json b/simulations/vip-373/abi/XVSStore.json new file mode 100644 index 000000000..2d9ea2bb2 --- /dev/null +++ b/simulations/vip-373/abi/XVSStore.json @@ -0,0 +1,130 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "AdminTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } + ], + "name": "NewPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnerTransferred", + "type": "event" + }, + { + "constant": false, + "inputs": [], + "name": "acceptAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "emergencyRewardWithdraw", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokens", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "token", "type": "address" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "safeRewardTransfer", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], + "name": "setNewOwner", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], + "name": "setPendingAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_tokenAddress", "type": "address" }, + { "internalType": "bool", "name": "status", "type": "bool" } + ], + "name": "setRewardToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/XVSVault.json b/simulations/vip-373/abi/XVSVault.json new file mode 100644 index 000000000..51d8d540c --- /dev/null +++ b/simulations/vip-373/abi/XVSVault.json @@ -0,0 +1,787 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Claim", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } + ], + "name": "DelegateChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } + ], + "name": "DelegateVotesChangedV2", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Deposit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ExecutedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "name": "PoolAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } + ], + "name": "PoolUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "RequestedWithdrawal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } + ], + "name": "RewardAmountUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } + ], + "name": "StoreUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } + ], + "name": "VaultDebtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], + "name": "VaultResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } + ], + "name": "WithdrawalLockingPeriodUpdated", + "type": "event" + }, + { + "constant": true, + "inputs": [], + "name": "DELEGATION_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "DOMAIN_TYPEHASH", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "MAX_LOCK_PERIOD", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "SECONDS_PER_YEAR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], + "name": "_become", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, + { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, + { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } + ], + "name": "add", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint32", "name": "", "type": "uint32" } + ], + "name": "checkpoints", + "outputs": [ + { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, + { "internalType": "uint96", "name": "votes", "type": "uint96" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_account", "type": "address" }, + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "claim", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], + "name": "delegate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "delegatee", "type": "address" }, + { "internalType": "uint256", "name": "nonce", "type": "uint256" }, + { "internalType": "uint256", "name": "expiry", "type": "uint256" }, + { "internalType": "uint8", "name": "v", "type": "uint8" }, + { "internalType": "bytes32", "name": "r", "type": "bytes32" }, + { "internalType": "bytes32", "name": "s", "type": "bytes32" } + ], + "name": "delegateBySig", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "delegates", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "deposit", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "executeWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getCurrentVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getEligibleWithdrawalAmount", + "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } + ], + "name": "getPriorVotes", + "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getRequestedAmount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getUserInfo", + "outputs": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, + { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "getWithdrawalRequests", + "outputs": [ + { + "components": [ + { "internalType": "uint256", "name": "amount", "type": "uint256" }, + { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, + { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } + ], + "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", + "name": "", + "type": "tuple[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "bool", "name": "timeBased_", "type": "bool" }, + { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } + ], + "name": "initializeTimeManager", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isStakedToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "nonces", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "numCheckpoints", + "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "pause", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingReward", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "pendingRewardTransfers", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "address", "name": "_user", "type": "address" } + ], + "name": "pendingWithdrawalsBeforeUpgrade", + "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingXVSVaultImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "poolInfos", + "outputs": [ + { "internalType": "contract IBEP20", "name": "token", "type": "address" }, + { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, + { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, + { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, + { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], + "name": "poolLength", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primePoolId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeRewardToken", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "primeToken", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "requestWithdrawal", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "resume", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], + "name": "rewardTokenAmountsPerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "rewardTokenAmountsPerBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } + ], + "name": "set", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], + "name": "setAccessControl", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, + { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } + ], + "name": "setPrimeToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } + ], + "name": "setRewardAmountPerBlockOrSecond", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" }, + { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } + ], + "name": "setWithdrawalLockingPeriod", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_xvs", "type": "address" }, + { "internalType": "address", "name": "_xvsStore", "type": "address" } + ], + "name": "setXvsStore", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "totalAllocPoints", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "totalPendingWithdrawals", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "_pid", "type": "uint256" } + ], + "name": "updatePool", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "vaultPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "xvsStore", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/XVSVaultProxy.json b/simulations/vip-373/abi/XVSVaultProxy.json new file mode 100644 index 000000000..070a7fa56 --- /dev/null +++ b/simulations/vip-373/abi/XVSVaultProxy.json @@ -0,0 +1,122 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "error", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "info", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "detail", "type": "uint256" } + ], + "name": "Failure", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "NewAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldImplementation", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newImplementation", "type": "address" } + ], + "name": "NewImplementation", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } + ], + "name": "NewPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingImplementation", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingImplementation", "type": "address" } + ], + "name": "NewPendingImplementation", + "type": "event" + }, + { "payable": true, "stateMutability": "payable", "type": "fallback" }, + { + "constant": false, + "inputs": [], + "name": "_acceptAdmin", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "_acceptImplementation", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newPendingAdmin", "type": "address" }], + "name": "_setPendingAdmin", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newPendingImplementation", "type": "address" }], + "name": "_setPendingImplementation", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingXVSVaultImplementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/binanceOracle.json b/simulations/vip-373/abi/binanceOracle.json new file mode 100644 index 000000000..513793a74 --- /dev/null +++ b/simulations/vip-373/abi/binanceOracle.json @@ -0,0 +1,284 @@ +[ + { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, + { + "name": "Unauthorized", + "type": "error", + "inputs": [ + { "name": "sender", "type": "address", "internalType": "address" }, + { "name": "calledContract", "type": "address", "internalType": "address" }, + { "name": "methodSignature", "type": "string", "internalType": "string" } + ] + }, + { + "name": "FeedRegistryUpdated", + "type": "event", + "inputs": [ + { "name": "oldFeedRegistry", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newFeedRegistry", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x6d1006252b3dd171af76c28c184327bfddc39f439a50e0ac7f418c660b8894b5" + }, + { + "name": "Initialized", + "type": "event", + "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], + "anonymous": false, + "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" + }, + { + "name": "MaxStalePeriodAdded", + "type": "event", + "inputs": [ + { "name": "asset", "type": "string", "indexed": true, "internalType": "string" }, + { "name": "maxStalePeriod", "type": "uint256", "indexed": false, "internalType": "uint256" } + ], + "anonymous": false, + "signature": "0x37839d4a80c5e3f2578f59515c911ee8cce42383d7ebaa1c92afcde9871c4b58" + }, + { + "name": "NewAccessControlManager", + "type": "event", + "inputs": [ + { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, + { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" + }, + { + "name": "OwnershipTransferStarted", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" + }, + { + "name": "OwnershipTransferred", + "type": "event", + "inputs": [ + { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, + { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } + ], + "anonymous": false, + "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" + }, + { + "name": "SymbolOverridden", + "type": "event", + "inputs": [ + { "name": "symbol", "type": "string", "indexed": true, "internalType": "string" }, + { "name": "overriddenSymbol", "type": "string", "indexed": false, "internalType": "string" } + ], + "anonymous": false, + "signature": "0xceb1f47aa91b96f02ea70e1deed25fe154ad1885aea509bd7222f9eec0a0bda5" + }, + { + "name": "BNB_ADDR", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x3e83b6b8", + "stateMutability": "view" + }, + { + "name": "acceptOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x79ba5097", + "stateMutability": "nonpayable" + }, + { + "name": "accessControlManager", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "contract IAccessControlManagerV8" + } + ], + "constant": true, + "signature": "0xb4a0bdf3", + "stateMutability": "view" + }, + { + "name": "feedRegistryAddress", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x011d3962", + "stateMutability": "view" + }, + { + "name": "getFeedRegistryAddress", + "type": "function", + "inputs": [], + "outputs": [{ "name": "", "type": "address", "internalType": "address" }], + "constant": true, + "signature": "0x99fe040e", + "stateMutability": "view" + }, + { + "name": "getPrice", + "type": "function", + "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], + "outputs": [{ "name": "", "type": "uint256", "internalType": "uint256" }], + "constant": true, + "signature": "0x41976e09", + "stateMutability": "view" + }, + { + "name": "initialize", + "type": "function", + "inputs": [ + { "name": "_sidRegistryAddress", "type": "address", "internalType": "address" }, + { "name": "_accessControlManager", "type": "address", "internalType": "address" } + ], + "outputs": [], + "signature": "0x485cc955", + "stateMutability": "nonpayable" + }, + { + "name": "maxStalePeriod", + "type": "function", + "inputs": [{ "name": "", "type": "string", "internalType": "string" }], + "outputs": [{ "name": "", "type": "uint256", "internalType": "uint256" }], + "constant": true, + "signature": "0xfdfbc277", + "stateMutability": "view" + }, + { + "name": "owner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x8da5cb5b", + "stateMutability": "view" + }, + { + "name": "pendingOwner", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0xe30c3978", + "stateMutability": "view" + }, + { + "name": "renounceOwnership", + "type": "function", + "inputs": [], + "outputs": [], + "signature": "0x715018a6", + "stateMutability": "nonpayable" + }, + { + "name": "setAccessControlManager", + "type": "function", + "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0x0e32cb86", + "stateMutability": "nonpayable" + }, + { + "name": "setFeedRegistryAddress", + "type": "function", + "inputs": [{ "name": "newfeedRegistryAddress", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0x255ce37a", + "stateMutability": "nonpayable" + }, + { + "name": "setMaxStalePeriod", + "type": "function", + "inputs": [ + { "name": "symbol", "type": "string", "internalType": "string" }, + { "name": "_maxStalePeriod", "type": "uint256", "internalType": "uint256" } + ], + "outputs": [], + "signature": "0x636b999a", + "stateMutability": "nonpayable" + }, + { + "name": "setSymbolOverride", + "type": "function", + "inputs": [ + { "name": "symbol", "type": "string", "internalType": "string" }, + { "name": "overrideSymbol", "type": "string", "internalType": "string" } + ], + "outputs": [], + "signature": "0x9eab1ad6", + "stateMutability": "nonpayable" + }, + { + "name": "sidRegistryAddress", + "type": "function", + "inputs": [], + "outputs": [ + { + "name": "", + "type": "address", + "value": "0x0000000000000000000000000000000000000000", + "internalType": "address" + } + ], + "constant": true, + "signature": "0x475e7de5", + "stateMutability": "view" + }, + { + "name": "symbols", + "type": "function", + "inputs": [{ "name": "", "type": "string", "internalType": "string" }], + "outputs": [{ "name": "", "type": "string", "internalType": "string" }], + "constant": true, + "signature": "0x047a74b2", + "stateMutability": "view" + }, + { + "name": "transferOwnership", + "type": "function", + "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], + "outputs": [], + "signature": "0xf2fde38b", + "stateMutability": "nonpayable" + } +] diff --git a/simulations/vip-373/abi/boundValidator.json b/simulations/vip-373/abi/boundValidator.json new file mode 100644 index 000000000..d16c8fb08 --- /dev/null +++ b/simulations/vip-373/abi/boundValidator.json @@ -0,0 +1,498 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "previousAdmin", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAdmin", + "type": "address" + } + ], + "name": "AdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "beacon", + "type": "address" + } + ], + "name": "BeaconUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "implementation", + "type": "address" + } + ], + "name": "Upgraded", + "type": "event" + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "inputs": [], + "name": "admin", + "outputs": [ + { + "internalType": "address", + "name": "admin_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [ + { + "internalType": "address", + "name": "implementation_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + } + ], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "upgradeToAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "stateMutability": "payable", + "type": "receive" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "upperBound", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "lowerBound", + "type": "uint256" + } + ], + "name": "ValidateConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig", + "name": "config", + "type": "tuple" + } + ], + "name": "setValidateConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "internalType": "struct BoundValidator.ValidateConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "setValidateConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "validateConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "upperBoundRatio", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lowerBoundRatio", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "reportedPrice", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "anchorPrice", + "type": "uint256" + } + ], + "name": "validatePriceWithAnchorPrice", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_logic", + "type": "address" + }, + { + "internalType": "address", + "name": "admin_", + "type": "address" + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes" + } + ], + "stateMutability": "payable", + "type": "constructor" + } +] diff --git a/simulations/vip-373/abi/chainlinkOracle.json b/simulations/vip-373/abi/chainlinkOracle.json new file mode 100644 index 000000000..cdd689acb --- /dev/null +++ b/simulations/vip-373/abi/chainlinkOracle.json @@ -0,0 +1,459 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "vBnbAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "previousPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "requestedPriceMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newPriceMantissa", + "type": "uint256" + } + ], + "name": "PricePosted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManager", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "prices", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + } + ], + "name": "setDirectPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "internalType": "struct TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VBep20Interface", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "underlyingPriceMantissa", + "type": "uint256" + } + ], + "name": "setUnderlyingPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "tokenConfigs", + "outputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "feed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "maxStalePeriod", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/resilientOracle.json b/simulations/vip-373/abi/resilientOracle.json new file mode 100644 index 000000000..35f52caa0 --- /dev/null +++ b/simulations/vip-373/abi/resilientOracle.json @@ -0,0 +1,640 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "nativeMarketAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + }, + { + "internalType": "contract BoundValidatorInterface", + "name": "_boundValidator", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "mainOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "pivotOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "fallbackOracle", + "type": "address" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [ + { + "internalType": "contract BoundValidatorInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "getOracle", + "outputs": [ + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "bool", + "name": "enabled", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/sFrxETHOracle.json b/simulations/vip-373/abi/sFrxETHOracle.json new file mode 100644 index 000000000..b461549ba --- /dev/null +++ b/simulations/vip-373/abi/sFrxETHOracle.json @@ -0,0 +1,148 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "_sfrxEthFraxOracle", "type": "address" }, + { "internalType": "address", "name": "_sfrxETH", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "BadPriceData", "type": "error" }, + { "inputs": [], "name": "InvalidTokenAddress", "type": "error" }, + { "inputs": [], "name": "PriceDifferenceExceeded", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxAllowedPriceDifference", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxAllowedPriceDifference", "type": "uint256" } + ], + "name": "MaxAllowedPriceDifferenceUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "SFRXETH", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "SFRXETH_FRAX_ORACLE", + "outputs": [{ "internalType": "contract ISfrxEthFraxOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_accessControlManager", "type": "address" }, + { "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxAllowedPriceDifference", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" }], + "name": "setMaxAllowedPriceDifference", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/treasury.json b/simulations/vip-373/abi/treasury.json new file mode 100644 index 000000000..18aabb61a --- /dev/null +++ b/simulations/vip-373/abi/treasury.json @@ -0,0 +1,86 @@ +[ + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryNative", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryToken", + "type": "event" + }, + { "stateMutability": "payable", "type": "fallback" }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryNative", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "stateMutability": "payable", "type": "receive" } +] diff --git a/simulations/vip-373/abi/xvs.json b/simulations/vip-373/abi/xvs.json new file mode 100644 index 000000000..69092bb4a --- /dev/null +++ b/simulations/vip-373/abi/xvs.json @@ -0,0 +1,716 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "AccountBlacklisted", + "type": "error" + }, + { + "inputs": [], + "name": "AddressesMustDiffer", + "type": "error" + }, + { + "inputs": [], + "name": "MintLimitExceed", + "type": "error" + }, + { + "inputs": [], + "name": "MintedAmountExceed", + "type": "error" + }, + { + "inputs": [], + "name": "NewCapNotGreaterThanMintedTokens", + "type": "error" + }, + { + "inputs": [], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "value", + "type": "bool" + } + ], + "name": "BlacklistUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "MintCapChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitDecreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLimit", + "type": "uint256" + } + ], + "name": "MintLimitIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "source", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "destination", + "type": "address" + } + ], + "name": "MintedTokensMigrated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "address", + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + } + ], + "name": "isBlackListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "source_", + "type": "address" + }, + { + "internalType": "address", + "name": "destination_", + "type": "address" + } + ], + "name": "migrateMinterTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToCap", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "minterToMintedAmount", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newAccessControlAddress_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "minter_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount_", + "type": "uint256" + } + ], + "name": "setMintCap", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + }, + { + "internalType": "bool", + "name": "value_", + "type": "bool" + } + ], + "name": "updateBlacklist", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/xvsBridge.json b/simulations/vip-373/abi/xvsBridge.json new file mode 100644 index 000000000..4e4dc5152 --- /dev/null +++ b/simulations/vip-373/abi/xvsBridge.json @@ -0,0 +1,807 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress_", "type": "address" }, + { "internalType": "uint8", "name": "sharedDecimals_", "type": "uint8" }, + { "internalType": "address", "name": "lzEndpoint_", "type": "address" }, + { "internalType": "address", "name": "oracle_", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "balance", "type": "uint256" } + ], + "name": "InsufficientBalance", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "indexed": false, "internalType": "bytes32", "name": "_hash", "type": "bytes32" } + ], + "name": "CallOFTReceivedSuccess", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "srcChainId", "type": "uint16" }, + { "indexed": true, "internalType": "bytes", "name": "srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "nonce", "type": "uint64" } + ], + "name": "DropFailedMessage", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "innerToken", "type": "address" }], + "name": "InnerTokenAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "indexed": false, "internalType": "bytes", "name": "_payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "_reason", "type": "bytes" } + ], + "name": "MessageFailed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "_address", "type": "address" }], + "name": "NonContractAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldOracle", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOracle", "type": "address" } + ], + "name": "OracleChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "indexed": true, "internalType": "address", "name": "_to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "ReceiveFromChain", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "indexed": false, "internalType": "bytes32", "name": "_payloadHash", "type": "bytes32" } + ], + "name": "RetryMessageSuccess", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "indexed": true, "internalType": "address", "name": "_from", "type": "address" }, + { "indexed": true, "internalType": "bytes32", "name": "_toAddress", "type": "bytes32" }, + { "indexed": false, "internalType": "uint256", "name": "_amount", "type": "uint256" } + ], + "name": "SendToChain", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyReceiveLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxSingleReceiveTransactionLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxSingleTransactionLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint16", "name": "_type", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "_minDstGas", "type": "uint256" } + ], + "name": "SetMinDstGas", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "precrime", "type": "address" }], + "name": "SetPrecrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_path", "type": "bytes" } + ], + "name": "SetTrustedRemote", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "addr", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "isWhitelist", "type": "bool" } + ], + "name": "SetWhitelist", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }], + "name": "TrustedRemoteRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "bool", "name": "enabled", "type": "bool" }], + "name": "UpdateSendAndCallEnabled", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_PAYLOAD_SIZE_LIMIT", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NO_EXTRA_GAS", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "PT_SEND", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "PT_SEND_AND_CALL", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "internalType": "bytes32", "name": "_from", "type": "bytes32" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" }, + { "internalType": "bytes", "name": "_payload", "type": "bytes" }, + { "internalType": "uint256", "name": "_gasForCall", "type": "uint256" } + ], + "name": "callOnOFTReceived", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourReceiveWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourReceived", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourTransferred", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyReceiveLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxSingleReceiveTransactionLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxSingleTransactionLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "circulatingSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "", "type": "uint16" }, + { "internalType": "bytes", "name": "", "type": "bytes" }, + { "internalType": "uint64", "name": "", "type": "uint64" } + ], + "name": "creditedPackets", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "srcAddress_", "type": "bytes" }, + { "internalType": "uint64", "name": "nonce_", "type": "uint64" } + ], + "name": "dropFailedMessage", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "internalType": "bytes32", "name": "_toAddress", "type": "bytes32" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" }, + { "internalType": "bytes", "name": "_payload", "type": "bytes" }, + { "internalType": "uint64", "name": "_dstGasForCall", "type": "uint64" }, + { "internalType": "bool", "name": "_useZro", "type": "bool" }, + { "internalType": "bytes", "name": "_adapterParams", "type": "bytes" } + ], + "name": "estimateSendAndCallFee", + "outputs": [ + { "internalType": "uint256", "name": "nativeFee", "type": "uint256" }, + { "internalType": "uint256", "name": "zroFee", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "internalType": "bytes32", "name": "_toAddress", "type": "bytes32" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" }, + { "internalType": "bool", "name": "_useZro", "type": "bool" }, + { "internalType": "bytes", "name": "_adapterParams", "type": "bytes" } + ], + "name": "estimateSendFee", + "outputs": [ + { "internalType": "uint256", "name": "nativeFee", "type": "uint256" }, + { "internalType": "uint256", "name": "zroFee", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "", "type": "uint16" }, + { "internalType": "bytes", "name": "", "type": "bytes" }, + { "internalType": "uint64", "name": "", "type": "uint64" } + ], + "name": "failedMessages", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } + ], + "name": "forceResumeReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_version", "type": "uint16" }, + { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "_configType", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }], + "name": "getTrustedRemoteAddress", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "from_", "type": "address" }, + { "internalType": "uint16", "name": "dstChainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "isEligibleToSend", + "outputs": [ + { "internalType": "bool", "name": "eligibleToSend", "type": "bool" }, + { "internalType": "uint256", "name": "maxSingleTransactionLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "maxDailyLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInUsd", "type": "uint256" }, + { "internalType": "uint256", "name": "transferredInWindow", "type": "uint256" }, + { "internalType": "uint256", "name": "last24HourWindowStart", "type": "uint256" }, + { "internalType": "bool", "name": "isWhiteListedUser", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } + ], + "name": "isTrustedRemote", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "lzEndpoint", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "internalType": "bytes", "name": "_payload", "type": "bytes" } + ], + "name": "lzReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "", "type": "uint16" }, + { "internalType": "uint16", "name": "", "type": "uint16" } + ], + "name": "minDstGasLookup", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "internalType": "bytes", "name": "_payload", "type": "bytes" } + ], + "name": "nonblockingLzReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "payloadSizeLimitLookup", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "precrime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], + "name": "removeTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "internalType": "bytes", "name": "_payload", "type": "bytes" } + ], + "name": "retryMessage", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "from_", "type": "address" }, + { "internalType": "uint16", "name": "dstChainId_", "type": "uint16" }, + { "internalType": "bytes32", "name": "toAddress_", "type": "bytes32" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "uint64", "name": "dstGasForCall_", "type": "uint64" }, + { + "components": [ + { "internalType": "address payable", "name": "refundAddress", "type": "address" }, + { "internalType": "address", "name": "zroPaymentAddress", "type": "address" }, + { "internalType": "bytes", "name": "adapterParams", "type": "bytes" } + ], + "internalType": "struct ICommonOFT.LzCallParams", + "name": "callparams_", + "type": "tuple" + } + ], + "name": "sendAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [], + "name": "sendAndCallEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_from", "type": "address" }, + { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "internalType": "bytes32", "name": "_toAddress", "type": "bytes32" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" }, + { + "components": [ + { "internalType": "address payable", "name": "refundAddress", "type": "address" }, + { "internalType": "address", "name": "zroPaymentAddress", "type": "address" }, + { "internalType": "bytes", "name": "adapterParams", "type": "bytes" } + ], + "internalType": "struct ICommonOFT.LzCallParams", + "name": "_callParams", + "type": "tuple" + } + ], + "name": "sendFrom", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_version", "type": "uint16" }, + { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, + { "internalType": "uint256", "name": "_configType", "type": "uint256" }, + { "internalType": "bytes", "name": "_config", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyReceiveLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxSingleReceiveTransactionLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxSingleTransactionLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "internalType": "uint16", "name": "_packetType", "type": "uint16" }, + { "internalType": "uint256", "name": "_minGas", "type": "uint256" } + ], + "name": "setMinDstGas", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "oracleAddress_", "type": "address" }], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "internalType": "uint256", "name": "_size", "type": "uint256" } + ], + "name": "setPayloadSizeLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_precrime", "type": "address" }], + "name": "setPrecrime", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], + "name": "setReceiveVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_path", "type": "bytes" } + ], + "name": "setTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "user_", "type": "address" }, + { "internalType": "bool", "name": "val_", "type": "bool" } + ], + "name": "setWhitelist", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "sharedDecimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], + "name": "supportsInterface", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract IERC20", "name": "token_", "type": "address" }, + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "token", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "bool", "name": "enabled_", "type": "bool" }], + "name": "updateSendAndCallEnabled", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "whitelist", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-373/abi/xvsBridgeAdmin.json b/simulations/vip-373/abi/xvsBridgeAdmin.json new file mode 100644 index 000000000..024450a40 --- /dev/null +++ b/simulations/vip-373/abi/xvsBridgeAdmin.json @@ -0,0 +1,329 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "XVSBridge_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "string", + "name": "signature", + "type": "string" + }, + { + "indexed": false, + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "name": "FunctionRegistryChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "stateMutability": "nonpayable", + "type": "fallback" + }, + { + "inputs": [], + "name": "XVSBridge", + "outputs": [ + { + "internalType": "contract IXVSProxyOFT", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "", + "type": "bytes4" + } + ], + "name": "functionRegistry", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "isTrustedRemote", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "remoteChainId_", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "remoteAddress_", + "type": "bytes" + } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner_", + "type": "address" + } + ], + "name": "transferBridgeOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "string[]", + "name": "signatures_", + "type": "string[]" + }, + { + "internalType": "bool[]", + "name": "active_", + "type": "bool[]" + } + ], + "name": "upsertSignature", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-372/arbitrumone.ts b/simulations/vip-373/arbitrumone.ts similarity index 95% rename from simulations/vip-372/arbitrumone.ts rename to simulations/vip-373/arbitrumone.ts index 449da53fe..a7863c1b3 100644 --- a/simulations/vip-372/arbitrumone.ts +++ b/simulations/vip-373/arbitrumone.ts @@ -5,7 +5,7 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; import vip014 from "../../multisig/proposals/arbitrumone/vip-014"; -import vip372, { ARBITRUM_ONE_BOUND_VALIDATOR, ARBITRUM_XVS_BRIDGE_ADMIN } from "../../vips/vip-372/bscmainnet"; +import vip373, { ARBITRUM_ONE_BOUND_VALIDATOR, ARBITRUM_XVS_BRIDGE_ADMIN } from "../../vips/vip-373/bscmainnet"; import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; @@ -36,7 +36,7 @@ forking(230362555, async () => { await pretendExecutingVip(await vip014()); }); - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip372()); + testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip373()); describe("Post-VIP behaviour", async () => { it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { diff --git a/simulations/vip-373/arbitrumsepolia.ts b/simulations/vip-373/arbitrumsepolia.ts new file mode 100644 index 000000000..8e91d5ec4 --- /dev/null +++ b/simulations/vip-373/arbitrumsepolia.ts @@ -0,0 +1,63 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip014, { ACM } from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import vip373, { + ARBITRUM_SEPOLIA_BOUND_VALIDATOR, + ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN, +} from "../../vips/vip-373/bsctestnet"; +import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; +import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; +import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; +import TREASURY_ABI from "./abi/treasury.json"; +import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; + +const XVS_BRIDGE = "0xFdC5cEC63FD167DA46cF006585b30D03B104eFD4"; +const { arbitrumsepolia } = NETWORK_ADDRESSES; + +forking(86016842, async () => { + const provider = ethers.provider; + let chainLinkOracle: Contract; + let redstoneOracle: Contract; + let resilientOracle: Contract; + let boundValidator: Contract; + let xvsBridgeAdmin: Contract; + let xvsBridge: Contract; + let treasury: Contract; + before(async () => { + chainLinkOracle = new ethers.Contract(arbitrumsepolia.CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); + redstoneOracle = new ethers.Contract(arbitrumsepolia.REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); + resilientOracle = new ethers.Contract(arbitrumsepolia.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); + boundValidator = new ethers.Contract(ARBITRUM_SEPOLIA_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); + xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN); + xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); + treasury = await ethers.getContractAt(TREASURY_ABI, arbitrumsepolia.VTREASURY); + + await pretendExecutingVip(await vip014()); + }); + + testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip373()); + + describe("Post-VIP behaviour", async () => { + it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { + expect(await xvsBridgeAdmin.owner()).to.be.equals(arbitrumsepolia.NORMAL_TIMELOCK); + }); + it("Normal Timelock should be whitelisted", async () => { + expect(await xvsBridge.whitelist(arbitrumsepolia.NORMAL_TIMELOCK)).to.be.true; + }); + it("oracles should have correct owner", async () => { + expect(await resilientOracle.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); + expect(await chainLinkOracle.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); + expect(await redstoneOracle.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); + expect(await boundValidator.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); + }); + it("Normal Timelock should be the owner of the Vtreasury", async () => { + expect(await treasury.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/simulations/vip-372/bscmainnet.ts b/simulations/vip-373/bscmainnet.ts similarity index 79% rename from simulations/vip-372/bscmainnet.ts rename to simulations/vip-373/bscmainnet.ts index cbe3143d0..3f63215f1 100644 --- a/simulations/vip-372/bscmainnet.ts +++ b/simulations/vip-373/bscmainnet.ts @@ -1,10 +1,10 @@ import { expectEvents } from "../../src/utils"; import { forking, testVip } from "../../src/vip-framework"; -import vip372 from "../../vips/vip-372/bscmainnet"; +import vip373 from "../../vips/vip-373/bscmainnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; forking(40343666, async () => { - testVip("vip372 XVS vault permission proposal", await vip372(), { + testVip("vip373 XVS vault permission proposal", await vip373(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-373/bsctestnet.ts b/simulations/vip-373/bsctestnet.ts new file mode 100644 index 000000000..bf36f1ba9 --- /dev/null +++ b/simulations/vip-373/bsctestnet.ts @@ -0,0 +1,17 @@ +import { expectEvents } from "../../src/utils"; +import { forking, testVip } from "../../src/vip-framework"; +import vip373 from "../../vips/vip-373/bsctestnet"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +forking(41938696, async () => { + testVip("vip373 XVS vault permission proposal", await vip373(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [3, 0], + ); + }, + }); +}); diff --git a/simulations/vip-372/ethereum.ts b/simulations/vip-373/ethereum.ts similarity index 96% rename from simulations/vip-372/ethereum.ts rename to simulations/vip-373/ethereum.ts index 449ea8ec3..40cff7f0d 100644 --- a/simulations/vip-372/ethereum.ts +++ b/simulations/vip-373/ethereum.ts @@ -5,11 +5,11 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; import vip061 from "../../multisig/proposals/ethereum/vip-061"; -import vip372, { +import vip373, { ETHEREUM_BOUND_VALIDATOR, ETHEREUM_XVS_BRIDGE_ADMIN, ETHEREUM_sFrxETH_ORACLE, -} from "../../vips/vip-372/bscmainnet"; +} from "../../vips/vip-373/bscmainnet"; import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; @@ -43,7 +43,7 @@ forking(20274111, async () => { await pretendExecutingVip(await vip061()); }); - testForkedNetworkVipCommands("vip372", await vip372()); + testForkedNetworkVipCommands("vip373", await vip373()); describe("Post-VIP behaviour", async () => { it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { diff --git a/simulations/vip-372/opbnbmainnet.ts b/simulations/vip-373/opbnbmainnet.ts similarity index 95% rename from simulations/vip-372/opbnbmainnet.ts rename to simulations/vip-373/opbnbmainnet.ts index 399028fa7..5e9a82acd 100644 --- a/simulations/vip-372/opbnbmainnet.ts +++ b/simulations/vip-373/opbnbmainnet.ts @@ -5,7 +5,7 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; import vip021 from "../../multisig/proposals/opbnbmainnet/vip-021"; -import vip372, { OPBNBMAINNET_BOUND_VALIDATOR, OPBNBMAINNET_XVS_BRIDGE_ADMIN } from "../../vips/vip-372/bscmainnet"; +import vip373, { OPBNBMAINNET_BOUND_VALIDATOR, OPBNBMAINNET_XVS_BRIDGE_ADMIN } from "../../vips/vip-373/bscmainnet"; import BINANCE_ORACLE_API from "./abi/binanceOracle.json"; import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; @@ -35,7 +35,7 @@ forking(28761242, async () => { await pretendExecutingVip(await vip021()); }); - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip372()); + testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip373()); describe("Post-VIP behaviour", async () => { it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { diff --git a/simulations/vip-373/opbnbtestnet.ts b/simulations/vip-373/opbnbtestnet.ts new file mode 100644 index 000000000..cf8a1608e --- /dev/null +++ b/simulations/vip-373/opbnbtestnet.ts @@ -0,0 +1,60 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip021, { ACM } from "../../multisig/proposals/opbnbtestnet/vip-021"; +import vip373, { + OPBNBTESTNET_BOUND_VALIDATOR, + OPBNBTESTNET_XVS_BRIDGE_ADMIN, +} from "../../vips/vip-373/bsctestnet"; +import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; +import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; +import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; +import TREASURY_ABI from "./abi/treasury.json"; +import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; + +const XVS_BRIDGE = "0xA03205bC635A772E533E7BE36b5701E331a70ea3"; +const { opbnbtestnet } = NETWORK_ADDRESSES; + +forking(41162234, async () => { + const provider = ethers.provider; + let binanceOracle: Contract; + let resilientOracle: Contract; + let boundValidator: Contract; + let treasury: Contract; + let xvsBridgeAdmin: Contract; + let xvsBridge: Contract; + before(async () => { + binanceOracle = new ethers.Contract(opbnbtestnet.BINANCE_ORACLE, CHAINLINK_ORACLE_ABI, provider); + resilientOracle = new ethers.Contract(opbnbtestnet.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); + boundValidator = new ethers.Contract(OPBNBTESTNET_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); + xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, OPBNBTESTNET_XVS_BRIDGE_ADMIN); + xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); + treasury = await ethers.getContractAt(TREASURY_ABI, opbnbtestnet.VTREASURY); + await pretendExecutingVip(await vip021()); + }); + + testForkedNetworkVipCommands("vip373", await vip373(), { + }); + + describe("Post-VIP behaviour", async () => { + it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { + expect(await xvsBridgeAdmin.owner()).to.be.equals(opbnbtestnet.NORMAL_TIMELOCK); + }); + it("Normal Timelock should be whitelisted", async () => { + expect(await xvsBridge.whitelist(opbnbtestnet.NORMAL_TIMELOCK)).to.be.true; + }); + it("oracles should have correct owner", async () => { + expect(await resilientOracle.owner()).equals(opbnbtestnet.NORMAL_TIMELOCK); + expect(await binanceOracle.owner()).equals(opbnbtestnet.NORMAL_TIMELOCK); + expect(await boundValidator.owner()).equals(opbnbtestnet.NORMAL_TIMELOCK); + }); + it("Normal Timelock should be the owner of the Vtreasury", async () => { + expect(await treasury.owner()).equals(opbnbtestnet.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/simulations/vip-373/sepolia.ts b/simulations/vip-373/sepolia.ts new file mode 100644 index 000000000..4b4127aa8 --- /dev/null +++ b/simulations/vip-373/sepolia.ts @@ -0,0 +1,66 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip060, { ACM } from "../../multisig/proposals/sepolia/vip-060"; +import vip373, { + SEPOLIA_BOUND_VALIDATOR, + SEPOLIA_XVS_BRIDGE_ADMIN, + SEPOLIA_sFrxETH_ORACLE, +} from "../../vips/vip-373/bsctestnet"; +import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; +import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; +import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; +import SFRAXETH_ORACLE_ABI from "./abi/sFrxETHOracle.json"; +import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; + +const XVS_BRIDGE = "0xc340b7d3406502F43dC11a988E4EC5bbE536E642"; +const { sepolia } = NETWORK_ADDRESSES; + +forking(6831661, async () => { + const provider = ethers.provider; + let chainLinkOracle: Contract; + let redstoneOracle: Contract; + let resilientOracle: Contract; + let boundValidator: Contract; + let sfraxETH: Contract; + + before(async () => { + chainLinkOracle = new ethers.Contract(sepolia.CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); + redstoneOracle = new ethers.Contract(sepolia.REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); + resilientOracle = new ethers.Contract(sepolia.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); + boundValidator = new ethers.Contract(SEPOLIA_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); + sfraxETH = new ethers.Contract(SEPOLIA_sFrxETH_ORACLE, SFRAXETH_ORACLE_ABI, provider); + + await pretendExecutingVip(await vip060()); + }); + + testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip373()); + + describe("Post-VIP behaviour", async () => { + let xvsBridgeAdmin: Contract; + let xvsBridge: Contract; + before(async () => { + xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, SEPOLIA_XVS_BRIDGE_ADMIN); + xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); + }); + + + it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { + expect(await xvsBridgeAdmin.owner()).to.be.equals(sepolia.NORMAL_TIMELOCK); + }); + it("Normal Timelock should be whitelisted", async () => { + expect(await xvsBridge.whitelist(sepolia.NORMAL_TIMELOCK)).to.be.true; + }); + it("oracles should have correct owner", async () => { + expect(await resilientOracle.owner()).equals(sepolia.NORMAL_TIMELOCK); + expect(await chainLinkOracle.owner()).equals(sepolia.NORMAL_TIMELOCK); + expect(await redstoneOracle.owner()).equals(sepolia.NORMAL_TIMELOCK); + expect(await boundValidator.owner()).equals(sepolia.NORMAL_TIMELOCK); + expect(await sfraxETH.owner()).equals(sepolia.NORMAL_TIMELOCK); + }); + }); +}); diff --git a/vips/vip-372/bsctestnet.ts b/vips/vip-372/bsctestnet.ts index 584bbf913..a0ecc95fe 100644 --- a/vips/vip-372/bsctestnet.ts +++ b/vips/vip-372/bsctestnet.ts @@ -3,36 +3,15 @@ import { LzChainId, ProposalType } from "src/types"; import { makeProposal } from "src/utils"; export const SEPOLIA_ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; -export const SEPOLIA_FASTTRACK_TIMELOCK = "0x7F043F43Adb392072a3Ba0cC9c96e894C6f7e182"; -export const SEPOLIA_CRITICAL_TIMELOCK = "0xA24A7A65b8968a749841988Bd7d05F6a94329fDe"; export const ARBITRUM_SEPOLIA_ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; export const OPBNBTESTNET_ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; -export const ARBITRUM_SEPOLIA_XVS_STORE = "0x4e909DA6693215dC630104715c035B159dDb67Dd"; -export const SEPOLIA_XVS_STORE = "0x03B868C7858F50900fecE4eBc851199e957b5d3D"; -export const OPBNBTESTNET_XVS_STORE = "0x06473fB3f7bF11e2E8EfEcC95aC55ABEFCb2e0A0"; - -export const SEPOLIA_XVS_BRIDGE_ADMIN = "0xd3c6bdeeadB2359F726aD4cF42EAa8B7102DAd9B"; -export const OPBNBTESTNET_XVS_BRIDGE_ADMIN = "0x19252AFD0B2F539C400aEab7d460CBFbf74c17ff"; -export const ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN = "0xc94578caCC89a29B044a0a1D54d20d48A645E5C8"; - -const SEPOLIA_CHAIN_ID = LzChainId.sepolia; -const OPBNBTESTNET_CHAIN_ID = LzChainId.opbnbtestnet; -const ARBITRUM_SEPOLIA_CHAIN_ID = LzChainId.arbitrumsepolia; - -export const ARBITRUM_SEPOLIA_BOUND_VALIDATOR = "0xfe6bc1545Cc14C131bacA97476D6035ffcC0b889"; -export const SEPOLIA_BOUND_VALIDATOR = "0x60c4Aa92eEb6884a76b309Dd8B3731ad514d6f9B"; -export const OPBNBTESTNET_BOUND_VALIDATOR = "0x049537Bb065e6253e9D8D08B45Bf6b753657A746"; -export const SEPOLIA_sFrxETH_ORACLE = "0x61EB836afA467677e6b403D504fe69D6940e7996"; - export const ARBITRUMSEPOLIA_ACM_AGGREGATOR = "0x4fCbfE445396f31005b3Fd2F6DE2A986d6E2dCB5"; export const OPBNBTESTNET_ACM_AGGREGATOR = "0xbDd501dB1B0D6aab299CE69ef5B86C8578947AD0"; export const SEPOLIA_ACM_AGGREGATOR = "0x0653830c55035d678e1287b2d4550519fd263d0e"; export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; -const { arbitrumsepolia, sepolia, opbnbtestnet } = NETWORK_ADDRESSES; - const vip372 = () => { const meta = { version: "v2", @@ -44,147 +23,6 @@ const vip372 = () => { }; return makeProposal( [ - { - target: arbitrumsepolia.XVS_VAULT_PROXY, - signature: "_acceptAdmin()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: sepolia.XVS_VAULT_PROXY, - signature: "_acceptAdmin()", - params: [], - dstChainId: LzChainId.sepolia, - }, - { - target: opbnbtestnet.XVS_VAULT_PROXY, - signature: "_acceptAdmin()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }, - { - target: ARBITRUM_SEPOLIA_XVS_STORE, - signature: "acceptAdmin()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: SEPOLIA_XVS_STORE, - signature: "acceptAdmin()", - params: [], - dstChainId: LzChainId.sepolia, - }, - { - target: OPBNBTESTNET_XVS_STORE, - signature: "acceptAdmin()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }, - { - target: ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN, - signature: "acceptOwnership()", - params: [], - dstChainId: ARBITRUM_SEPOLIA_CHAIN_ID, - }, - { - target: OPBNBTESTNET_XVS_BRIDGE_ADMIN, - signature: "acceptOwnership()", - params: [], - dstChainId: OPBNBTESTNET_CHAIN_ID, - }, - { - target: SEPOLIA_XVS_BRIDGE_ADMIN, - signature: "acceptOwnership()", - params: [], - dstChainId: SEPOLIA_CHAIN_ID, - }, - { - target: arbitrumsepolia.CHAINLINK_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: ARBITRUM_SEPOLIA_BOUND_VALIDATOR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: arbitrumsepolia.REDSTONE_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: arbitrumsepolia.RESILIENT_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: opbnbtestnet.BINANCE_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }, - { - target: opbnbtestnet.RESILIENT_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }, - { - target: OPBNBTESTNET_BOUND_VALIDATOR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }, - - { - target: sepolia.CHAINLINK_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }, - - { - target: sepolia.REDSTONE_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }, - { - target: sepolia.RESILIENT_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }, - { - target: SEPOLIA_BOUND_VALIDATOR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }, - { - target: SEPOLIA_sFrxETH_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }, - { - target: arbitrumsepolia.VTREASURY, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: opbnbtestnet.VTREASURY, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }, - { target: ARBITRUM_SEPOLIA_ACM, signature: "grantRole(bytes32,address)", diff --git a/vips/vip-372/bscmainnet.ts b/vips/vip-373/bscmainnet.ts similarity index 97% rename from vips/vip-372/bscmainnet.ts rename to vips/vip-373/bscmainnet.ts index 77d067ab0..3e1dcd8f4 100644 --- a/vips/vip-372/bscmainnet.ts +++ b/vips/vip-373/bscmainnet.ts @@ -16,15 +16,15 @@ const ARBITRUM_CHAIN_ID = LzChainId.arbitrumone; export const ARBITRUM_ONE_BOUND_VALIDATOR = "0x2245FA2420925Cd3C2D889Ddc5bA1aefEF0E14CF"; export const ETHEREUM_BOUND_VALIDATOR = "0x1Cd5f336A1d28Dff445619CC63d3A0329B4d8a58"; -export const OPBNBMAINNET_BOUND_VALIDATOR = "0xD1f80C372C6e2FA395A5574Db3e3B4DaF43dAdCE"; +export const OPBNBMAINNET_BOUND_VALIDATOR = "0xd1f80C371C6E2Fa395A5574DB3E3b4dAf43dadCE"; export const ETHEREUM_sFrxETH_ORACLE = "0x5E06A5f48692E4Fff376fDfCA9E4C0183AAADCD1"; const { arbitrumone, ethereum, opbnbmainnet } = NETWORK_ADDRESSES; -const vip372 = () => { +const vip373 = () => { const meta = { version: "v2", - title: "VIP-372", + title: "VIP-373", description: `### Description`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", @@ -183,4 +183,4 @@ const vip372 = () => { ProposalType.REGULAR, ); }; -export default vip372; +export default vip373; diff --git a/vips/vip-373/bsctestnet.ts b/vips/vip-373/bsctestnet.ts new file mode 100644 index 000000000..7ac657f9d --- /dev/null +++ b/vips/vip-373/bsctestnet.ts @@ -0,0 +1,192 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const SEPOLIA_ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; +export const SEPOLIA_FASTTRACK_TIMELOCK = "0x7F043F43Adb392072a3Ba0cC9c96e894C6f7e182"; +export const SEPOLIA_CRITICAL_TIMELOCK = "0xA24A7A65b8968a749841988Bd7d05F6a94329fDe"; +export const ARBITRUM_SEPOLIA_ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; +export const OPBNBTESTNET_ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; + +export const ARBITRUM_SEPOLIA_XVS_STORE = "0x4e909DA6693215dC630104715c035B159dDb67Dd"; +export const SEPOLIA_XVS_STORE = "0x03B868C7858F50900fecE4eBc851199e957b5d3D"; +export const OPBNBTESTNET_XVS_STORE = "0x06473fB3f7bF11e2E8EfEcC95aC55ABEFCb2e0A0"; + +export const SEPOLIA_XVS_BRIDGE_ADMIN = "0xd3c6bdeeadB2359F726aD4cF42EAa8B7102DAd9B"; +export const OPBNBTESTNET_XVS_BRIDGE_ADMIN = "0x19252AFD0B2F539C400aEab7d460CBFbf74c17ff"; +export const ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN = "0xc94578caCC89a29B044a0a1D54d20d48A645E5C8"; + +const SEPOLIA_CHAIN_ID = LzChainId.sepolia; +const OPBNBTESTNET_CHAIN_ID = LzChainId.opbnbtestnet; +const ARBITRUM_SEPOLIA_CHAIN_ID = LzChainId.arbitrumsepolia; + +export const ARBITRUM_SEPOLIA_BOUND_VALIDATOR = "0xfe6bc1545Cc14C131bacA97476D6035ffcC0b889"; +export const SEPOLIA_BOUND_VALIDATOR = "0x60c4Aa92eEb6884a76b309Dd8B3731ad514d6f9B"; +export const OPBNBTESTNET_BOUND_VALIDATOR = "0x049537Bb065e6253e9D8D08B45Bf6b753657A746"; +export const SEPOLIA_sFrxETH_ORACLE = "0x61EB836afA467677e6b403D504fe69D6940e7996"; + +export const ARBITRUMSEPOLIA_ACM_AGGREGATOR = "0x4fCbfE445396f31005b3Fd2F6DE2A986d6E2dCB5"; +export const OPBNBTESTNET_ACM_AGGREGATOR = "0xbDd501dB1B0D6aab299CE69ef5B86C8578947AD0"; +export const SEPOLIA_ACM_AGGREGATOR = "0x0653830c55035d678e1287b2d4550519fd263d0e"; + +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + +const { arbitrumsepolia, sepolia, opbnbtestnet } = NETWORK_ADDRESSES; + +const vip373 = () => { + const meta = { + version: "v2", + title: "VIP-332 accept ownership & give permissions to Normal Timelock", + description: `### Description`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: arbitrumsepolia.XVS_VAULT_PROXY, + signature: "_acceptAdmin()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: sepolia.XVS_VAULT_PROXY, + signature: "_acceptAdmin()", + params: [], + dstChainId: LzChainId.sepolia, + }, + { + target: opbnbtestnet.XVS_VAULT_PROXY, + signature: "_acceptAdmin()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: ARBITRUM_SEPOLIA_XVS_STORE, + signature: "acceptAdmin()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: SEPOLIA_XVS_STORE, + signature: "acceptAdmin()", + params: [], + dstChainId: LzChainId.sepolia, + }, + { + target: OPBNBTESTNET_XVS_STORE, + signature: "acceptAdmin()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN, + signature: "acceptOwnership()", + params: [], + dstChainId: ARBITRUM_SEPOLIA_CHAIN_ID, + }, + { + target: OPBNBTESTNET_XVS_BRIDGE_ADMIN, + signature: "acceptOwnership()", + params: [], + dstChainId: OPBNBTESTNET_CHAIN_ID, + }, + { + target: SEPOLIA_XVS_BRIDGE_ADMIN, + signature: "acceptOwnership()", + params: [], + dstChainId: SEPOLIA_CHAIN_ID, + }, + { + target: arbitrumsepolia.CHAINLINK_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ARBITRUM_SEPOLIA_BOUND_VALIDATOR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: arbitrumsepolia.REDSTONE_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: arbitrumsepolia.RESILIENT_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: opbnbtestnet.BINANCE_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: opbnbtestnet.RESILIENT_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: OPBNBTESTNET_BOUND_VALIDATOR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }, + + { + target: sepolia.CHAINLINK_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }, + + { + target: sepolia.REDSTONE_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }, + { + target: sepolia.RESILIENT_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }, + { + target: SEPOLIA_BOUND_VALIDATOR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }, + { + target: SEPOLIA_sFrxETH_ORACLE, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }, + { + target: arbitrumsepolia.VTREASURY, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: opbnbtestnet.VTREASURY, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip373; From bb2e2cf4ca24ea73e6929289636600fbe84ade31 Mon Sep 17 00:00:00 2001 From: web3rover Date: Thu, 10 Oct 2024 14:57:33 +0400 Subject: [PATCH 027/178] fix: reordered vips --- .../abi/binanceOracle.json | 0 .../{vip-372 => vip-371}/abi/xvsBridge.json | 0 simulations/vip-371/arbitrumsepolia.ts | 89 +++----- simulations/vip-371/opbnbtestnet.ts | 66 +++--- simulations/vip-371/sepolia.ts | 104 +++------ .../{vip-371 => vip-372}/arbitrumone.ts | 4 +- simulations/vip-372/arbitrumsepolia.ts | 93 +++++--- .../{vip-371 => vip-372}/bscmainnet.ts | 4 +- simulations/{vip-371 => vip-372}/ethereum.ts | 4 +- .../{vip-371 => vip-372}/opbnbmainnet.ts | 4 +- simulations/vip-372/opbnbtestnet.ts | 69 +++--- simulations/vip-372/sepolia.ts | 107 +++++++--- simulations/vip-373/arbitrumsepolia.ts | 3 +- simulations/vip-373/opbnbtestnet.ts | 11 +- simulations/vip-373/sepolia.ts | 3 +- vips/vip-371/bsctestnet.ts | 199 ++++++------------ vips/{vip-371 => vip-372}/bscmainnet.ts | 6 +- vips/vip-372/bsctestnet.ts | 196 +++++++++++------ 18 files changed, 473 insertions(+), 489 deletions(-) rename simulations/{vip-372 => vip-371}/abi/binanceOracle.json (100%) rename simulations/{vip-372 => vip-371}/abi/xvsBridge.json (100%) rename simulations/{vip-371 => vip-372}/arbitrumone.ts (96%) rename simulations/{vip-371 => vip-372}/bscmainnet.ts (79%) rename simulations/{vip-371 => vip-372}/ethereum.ts (97%) rename simulations/{vip-371 => vip-372}/opbnbmainnet.ts (94%) rename vips/{vip-371 => vip-372}/bscmainnet.ts (98%) diff --git a/simulations/vip-372/abi/binanceOracle.json b/simulations/vip-371/abi/binanceOracle.json similarity index 100% rename from simulations/vip-372/abi/binanceOracle.json rename to simulations/vip-371/abi/binanceOracle.json diff --git a/simulations/vip-372/abi/xvsBridge.json b/simulations/vip-371/abi/xvsBridge.json similarity index 100% rename from simulations/vip-372/abi/xvsBridge.json rename to simulations/vip-371/abi/xvsBridge.json diff --git a/simulations/vip-371/arbitrumsepolia.ts b/simulations/vip-371/arbitrumsepolia.ts index 394b300ca..c6b73d12a 100644 --- a/simulations/vip-371/arbitrumsepolia.ts +++ b/simulations/vip-371/arbitrumsepolia.ts @@ -1,81 +1,50 @@ import { expect } from "chai"; -import { Contract } from "ethers"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip014 from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import { - COMPTROLLERS, - PLP, - PRIME, - PSR, - REWARD_DISTRIBUTORS, - VTOKENS, - XVS_STORE, -} from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import vip371 from "../../vips/vip-371/bsctestnet"; -import COMPTROLLER_ABI from "./abi/Comptroller.json"; -import PRIME_ABI from "./abi/Prime.json"; -import PRIME_LIQUIDITY_PROVIDER_ABI from "./abi/PrimeLiquidityProvider.json"; -import PSR_ABI from "./abi/ProtocolShareReserve.json"; -import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistributor.json"; -import VTOKEN_ABI from "./abi/VToken.json"; -import XVS_STORE_ABI from "./abi/XVSStore.json"; -import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; +import vip014, { ACM } from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import vip371, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet"; +import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { arbitrumsepolia } = NETWORK_ADDRESSES; -forking(70004884, async () => { - const provider = ethers.provider; - let prime: Contract; - let plp: Contract; - const xvsVaultProxy = new ethers.Contract(arbitrumsepolia.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); - const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); - +forking(86016842, async () => { before(async () => { - prime = new ethers.Contract(PRIME, PRIME_ABI, provider); - plp = new ethers.Contract(PLP, PRIME_LIQUIDITY_PROVIDER_ABI, provider); await pretendExecutingVip(await vip014()); }); - testForkedNetworkVipCommands("vip371", await vip371()); - - describe("Post-VIP behavior", async () => { - it(`correct owner `, async () => { - expect(await prime.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - expect(await plp.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); + testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [84]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [35]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); + }, + }); - for (const rewardDistributor of REWARD_DISTRIBUTORS) { - it(`correct owner for ${rewardDistributor}`, async () => { - const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); - expect(await c.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - } + describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); - it(`correct owner for psr`, async () => { - const psr = new ethers.Contract(PSR, PSR_ABI, provider); - expect(await psr.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; }); - for (const comptrollerAddress of COMPTROLLERS) { - it(`correct owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - } + it("check few permissions", async () => { + const role1 = ethers.utils.solidityPack(["address", "string"], [arbitrumsepolia.RESILIENT_ORACLE, "pause()"]); + + const roleHash = ethers.utils.keccak256(role1); + expect(await acm.hasRole(roleHash, arbitrumsepolia.NORMAL_TIMELOCK)).to.be.true; - for (const vTokenAddress of VTOKENS) { - it(`correct owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - } + const role2 = ethers.utils.solidityPack( + ["address", "string"], + [arbitrumsepolia.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], + ); - it("should have the correct pending owner", async () => { - expect(await xvsVaultProxy.admin()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - expect(await xvsStore.admin()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + const roleHash2 = ethers.utils.keccak256(role2); + expect(await acm.hasRole(roleHash2, arbitrumsepolia.NORMAL_TIMELOCK)).to.be.true; }); }); }); diff --git a/simulations/vip-371/opbnbtestnet.ts b/simulations/vip-371/opbnbtestnet.ts index 7e3ecebca..3f1da96c8 100644 --- a/simulations/vip-371/opbnbtestnet.ts +++ b/simulations/vip-371/opbnbtestnet.ts @@ -1,52 +1,50 @@ import { expect } from "chai"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip021, { COMPTROLLERS, PSR, VTOKENS, XVS_STORE } from "../../multisig/proposals/opbnbtestnet/vip-021"; -import vip371 from "../../vips/vip-350/bsctestnet"; -import COMPTROLLER_ABI from "./abi/Comptroller.json"; -import PSR_ABI from "./abi/ProtocolShareReserve.json"; -import VTOKEN_ABI from "./abi/VToken.json"; -import XVS_STORE_ABI from "./abi/XVSStore.json"; -import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; +import vip021, { ACM } from "../../multisig/proposals/opbnbtestnet/vip-021"; +import vip371, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet"; +import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { opbnbtestnet } = NETWORK_ADDRESSES; -forking(36325286, async () => { - const provider = ethers.provider; - const xvsVaultProxy = new ethers.Contract(opbnbtestnet.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); - const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); - +forking(41162234, async () => { before(async () => { await pretendExecutingVip(await vip021()); }); - testForkedNetworkVipCommands("vip371", await vip371()); + testForkedNetworkVipCommands("vip371", await vip371(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [70]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [20]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); + }, + }); + + describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); - describe("Post-VIP behavior", async () => { - it(`correct owner for psr`, async () => { - const psr = new ethers.Contract(PSR, PSR_ABI, provider); - expect(await psr.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; }); - for (const comptrollerAddress of COMPTROLLERS) { - it(`correct owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`correct owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); - }); - } - - it("should have the correct pending owner", async () => { - expect(await xvsVaultProxy.admin()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); - expect(await xvsStore.admin()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + it("check few permissions", async () => { + const role1 = ethers.utils.solidityPack(["address", "string"], [opbnbtestnet.RESILIENT_ORACLE, "pause()"]); + + const roleHash = ethers.utils.keccak256(role1); + expect(await acm.hasRole(roleHash, opbnbtestnet.NORMAL_TIMELOCK)).to.be.true; + + const role2 = ethers.utils.solidityPack( + ["address", "string"], + [opbnbtestnet.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], + ); + + const roleHash2 = ethers.utils.keccak256(role2); + expect(await acm.hasRole(roleHash2, opbnbtestnet.NORMAL_TIMELOCK)).to.be.true; }); }); }); diff --git a/simulations/vip-371/sepolia.ts b/simulations/vip-371/sepolia.ts index 3e08eba5f..cd01e78c4 100644 --- a/simulations/vip-371/sepolia.ts +++ b/simulations/vip-371/sepolia.ts @@ -1,97 +1,49 @@ import { expect } from "chai"; -import { Contract } from "ethers"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip060 from "../../multisig/proposals/sepolia/vip-060"; -import { - COMPTROLLERS, - CONVERTERS, - CONVERTER_NETWORK, - PLP, - PRIME, - PSR, - REWARD_DISTRIBUTORS, - VTOKENS, - XVS_STORE, -} from "../../multisig/proposals/sepolia/vip-060"; -import vip371 from "../../vips/vip-371/bsctestnet"; -import COMPTROLLER_ABI from "./abi/Comptroller.json"; -import CONVERTER_NETWORK_ABI from "./abi/ConverterNetwork.json"; -import PRIME_ABI from "./abi/Prime.json"; -import PRIME_LIQUIDITY_PROVIDER_ABI from "./abi/PrimeLiquidityProvider.json"; -import PSR_ABI from "./abi/ProtocolShareReserve.json"; -import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistributor.json"; -import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; -import VTOKEN_ABI from "./abi/VToken.json"; -import XVS_STORE_ABI from "./abi/XVSStore.json"; -import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; +import vip060, { ACM } from "../../multisig/proposals/sepolia/vip-060"; +import vip371, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet"; +import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { sepolia } = NETWORK_ADDRESSES; -forking(6460097, async () => { - const provider = ethers.provider; - let prime: Contract; - let plp: Contract; - const xvsVaultProxy = new ethers.Contract(sepolia.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); - const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); - +forking(6831661, async () => { before(async () => { - prime = new ethers.Contract(PRIME, PRIME_ABI, provider); - plp = new ethers.Contract(PLP, PRIME_LIQUIDITY_PROVIDER_ABI, provider); await pretendExecutingVip(await vip060()); }); - testForkedNetworkVipCommands("vip350", await vip371()); - - describe("Post-VIP behavior", async () => { - for (const converter of CONVERTERS) { - it(`owner for ${converter}`, async () => { - const c = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); - expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - } - - it(`owner for converter network`, async () => { - const c = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); - expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); + testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [95]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [42]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); + }, + }); - it(`correct owner `, async () => { - expect(await prime.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - expect(await plp.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; }); - for (const rewardDistributor of REWARD_DISTRIBUTORS) { - it(`correct owner for ${rewardDistributor}`, async () => { - const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); - expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - } - - it(`correct owner for psr`, async () => { - const psr = new ethers.Contract(PSR, PSR_ABI, provider); - expect(await psr.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); + it("check few permissions", async () => { + const role1 = ethers.utils.solidityPack(["address", "string"], [sepolia.RESILIENT_ORACLE, "pause()"]); - for (const comptrollerAddress of COMPTROLLERS) { - it(`correct owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - } + const roleHash = ethers.utils.keccak256(role1); + expect(await acm.hasRole(roleHash, sepolia.NORMAL_TIMELOCK)).to.be.true; - for (const vTokenAddress of VTOKENS) { - it(`correct owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - } + const role2 = ethers.utils.solidityPack( + ["address", "string"], + [sepolia.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], + ); - it("should have the correct pending owner", async () => { - expect(await xvsVaultProxy.admin()).to.equal(sepolia.NORMAL_TIMELOCK); - expect(await xvsStore.admin()).to.equal(sepolia.NORMAL_TIMELOCK); + const roleHash2 = ethers.utils.keccak256(role2); + expect(await acm.hasRole(roleHash2, sepolia.NORMAL_TIMELOCK)).to.be.true; }); }); }); diff --git a/simulations/vip-371/arbitrumone.ts b/simulations/vip-372/arbitrumone.ts similarity index 96% rename from simulations/vip-371/arbitrumone.ts rename to simulations/vip-372/arbitrumone.ts index 7cef985d2..ac8c1a3ce 100644 --- a/simulations/vip-371/arbitrumone.ts +++ b/simulations/vip-372/arbitrumone.ts @@ -14,7 +14,7 @@ import { VTOKENS, XVS_STORE, } from "../../multisig/proposals/arbitrumone/vip-014"; -import vip371 from "../../vips/vip-371/bscmainnet"; +import vip372 from "../../vips/vip-372/bscmainnet"; import COMPTROLLER_ABI from "./abi/Comptroller.json"; import PRIME_ABI from "./abi/Prime.json"; import PRIME_LIQUIDITY_PROVIDER_ABI from "./abi/PrimeLiquidityProvider.json"; @@ -40,7 +40,7 @@ forking(241112064, async () => { await pretendExecutingVip(await vip014()); }); - testForkedNetworkVipCommands("vip350", await vip371()); + testForkedNetworkVipCommands("vip350", await vip372()); describe("Post-VIP behavior", async () => { it(`correct owner `, async () => { diff --git a/simulations/vip-372/arbitrumsepolia.ts b/simulations/vip-372/arbitrumsepolia.ts index 972bc23a6..2470caaee 100644 --- a/simulations/vip-372/arbitrumsepolia.ts +++ b/simulations/vip-372/arbitrumsepolia.ts @@ -1,52 +1,81 @@ import { expect } from "chai"; +import { Contract } from "ethers"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip014, { ACM } from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import vip372, { - DEFAULT_ADMIN_ROLE, - OPBNBTESTNET_ACM_AGGREGATOR, -} from "../../vips/vip-372/bsctestnet"; -import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; -import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; +import vip014 from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import { + COMPTROLLERS, + PLP, + PRIME, + PSR, + REWARD_DISTRIBUTORS, + VTOKENS, + XVS_STORE, +} from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import vip372 from "../../vips/vip-372/bsctestnet"; +import COMPTROLLER_ABI from "./abi/Comptroller.json"; +import PRIME_ABI from "./abi/Prime.json"; +import PRIME_LIQUIDITY_PROVIDER_ABI from "./abi/PrimeLiquidityProvider.json"; +import PSR_ABI from "./abi/ProtocolShareReserve.json"; +import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistributor.json"; +import VTOKEN_ABI from "./abi/VToken.json"; +import XVS_STORE_ABI from "./abi/XVSStore.json"; +import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; + const { arbitrumsepolia } = NETWORK_ADDRESSES; -forking(86016842, async () => { +forking(70004884, async () => { + const provider = ethers.provider; + let prime: Contract; + let plp: Contract; + const xvsVaultProxy = new ethers.Contract(arbitrumsepolia.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); + const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); + before(async () => { + prime = new ethers.Contract(PRIME, PRIME_ABI, provider); + plp = new ethers.Contract(PLP, PRIME_LIQUIDITY_PROVIDER_ABI, provider); await pretendExecutingVip(await vip014()); }); - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip372(), { - callbackAfterExecution: async txResponse => { - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [84]); - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [35]); - await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); - await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); - }, - }); - - describe("Post-VIP behaviour", async () => { - const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); + testForkedNetworkVipCommands("vip372", await vip372()); - it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { - expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; + describe("Post-VIP behavior", async () => { + it(`correct owner `, async () => { + expect(await prime.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + expect(await plp.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); }); - it("check few permissions", async () => { - const role1 = ethers.utils.solidityPack(["address", "string"], [arbitrumsepolia.RESILIENT_ORACLE, "pause()"]); + for (const rewardDistributor of REWARD_DISTRIBUTORS) { + it(`correct owner for ${rewardDistributor}`, async () => { + const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); + expect(await c.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + } + + it(`correct owner for psr`, async () => { + const psr = new ethers.Contract(PSR, PSR_ABI, provider); + expect(await psr.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); - const roleHash = ethers.utils.keccak256(role1); - expect(await acm.hasRole(roleHash, arbitrumsepolia.NORMAL_TIMELOCK)).to.be.true; + for (const comptrollerAddress of COMPTROLLERS) { + it(`correct owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + } - const role2 = ethers.utils.solidityPack( - ["address", "string"], - [arbitrumsepolia.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], - ); + for (const vTokenAddress of VTOKENS) { + it(`correct owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + }); + } - const roleHash2 = ethers.utils.keccak256(role2); - expect(await acm.hasRole(roleHash2, arbitrumsepolia.NORMAL_TIMELOCK)).to.be.true; + it("should have the correct pending owner", async () => { + expect(await xvsVaultProxy.admin()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); + expect(await xvsStore.admin()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); }); }); }); diff --git a/simulations/vip-371/bscmainnet.ts b/simulations/vip-372/bscmainnet.ts similarity index 79% rename from simulations/vip-371/bscmainnet.ts rename to simulations/vip-372/bscmainnet.ts index 77ba30c92..cbe3143d0 100644 --- a/simulations/vip-371/bscmainnet.ts +++ b/simulations/vip-372/bscmainnet.ts @@ -1,10 +1,10 @@ import { expectEvents } from "../../src/utils"; import { forking, testVip } from "../../src/vip-framework"; -import vip371 from "../../vips/vip-371/bscmainnet"; +import vip372 from "../../vips/vip-372/bscmainnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; forking(40343666, async () => { - testVip("vip371 XVS vault permission proposal", await vip371(), { + testVip("vip372 XVS vault permission proposal", await vip372(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-371/ethereum.ts b/simulations/vip-372/ethereum.ts similarity index 97% rename from simulations/vip-371/ethereum.ts rename to simulations/vip-372/ethereum.ts index 455463f58..de650a76e 100644 --- a/simulations/vip-371/ethereum.ts +++ b/simulations/vip-372/ethereum.ts @@ -16,7 +16,7 @@ import { VTOKENS, XVS_STORE, } from "../../multisig/proposals/ethereum/vip-061"; -import vip371 from "../../vips/vip-371/bscmainnet"; +import vip372 from "../../vips/vip-372/bscmainnet"; import COMPTROLLER_ABI from "./abi/Comptroller.json"; import CONVERTER_NETWORK_ABI from "./abi/ConverterNetwork.json"; import PRIME_ABI from "./abi/Prime.json"; @@ -43,7 +43,7 @@ forking(20482317, async () => { await pretendExecutingVip(await vip061()); }); - testForkedNetworkVipCommands("vip350", await vip371()); + testForkedNetworkVipCommands("vip350", await vip372()); describe("Post-VIP behavior", async () => { for (const converter of CONVERTERS) { diff --git a/simulations/vip-371/opbnbmainnet.ts b/simulations/vip-372/opbnbmainnet.ts similarity index 94% rename from simulations/vip-371/opbnbmainnet.ts rename to simulations/vip-372/opbnbmainnet.ts index 15745f5c7..2a9a60f45 100644 --- a/simulations/vip-371/opbnbmainnet.ts +++ b/simulations/vip-372/opbnbmainnet.ts @@ -5,7 +5,7 @@ import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/ import vip021 from "../../multisig/proposals/opbnbmainnet/vip-021"; import { COMPTROLLERS, PSR, VTOKENS, XVS_STORE } from "../../multisig/proposals/opbnbmainnet/vip-021"; -import vip371 from "../../vips/vip-371/bscmainnet"; +import vip372 from "../../vips/vip-372/bscmainnet"; import COMPTROLLER_ABI from "./abi/Comptroller.json"; import PSR_ABI from "./abi/ProtocolShareReserve.json"; import VTOKEN_ABI from "./abi/VToken.json"; @@ -23,7 +23,7 @@ forking(31449867, async () => { await pretendExecutingVip(await vip021()); }); - testForkedNetworkVipCommands("vip371", await vip371()); + testForkedNetworkVipCommands("vip372", await vip372()); describe("Post-VIP behavior", async () => { it(`correct owner for psr`, async () => { diff --git a/simulations/vip-372/opbnbtestnet.ts b/simulations/vip-372/opbnbtestnet.ts index a333cfb73..089ad6e02 100644 --- a/simulations/vip-372/opbnbtestnet.ts +++ b/simulations/vip-372/opbnbtestnet.ts @@ -1,53 +1,52 @@ import { expect } from "chai"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip021, { ACM } from "../../multisig/proposals/opbnbtestnet/vip-021"; -import vip372, { - DEFAULT_ADMIN_ROLE, - OPBNBTESTNET_ACM_AGGREGATOR, -} from "../../vips/vip-372/bsctestnet"; -import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; -import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; +import vip021, { COMPTROLLERS, PSR, VTOKENS, XVS_STORE } from "../../multisig/proposals/opbnbtestnet/vip-021"; +import vip372 from "../../vips/vip-350/bsctestnet"; +import COMPTROLLER_ABI from "./abi/Comptroller.json"; +import PSR_ABI from "./abi/ProtocolShareReserve.json"; +import VTOKEN_ABI from "./abi/VToken.json"; +import XVS_STORE_ABI from "./abi/XVSStore.json"; +import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; const { opbnbtestnet } = NETWORK_ADDRESSES; -forking(41162234, async () => { +forking(36325286, async () => { + const provider = ethers.provider; + const xvsVaultProxy = new ethers.Contract(opbnbtestnet.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); + const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); + before(async () => { await pretendExecutingVip(await vip021()); }); - testForkedNetworkVipCommands("vip372", await vip372(), { - callbackAfterExecution: async txResponse => { - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [70]); - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [20]); - await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); - await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); - }, - }); - - describe("Post-VIP behaviour", async () => { - const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); + testForkedNetworkVipCommands("vip372", await vip372()); - it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { - expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; + describe("Post-VIP behavior", async () => { + it(`correct owner for psr`, async () => { + const psr = new ethers.Contract(PSR, PSR_ABI, provider); + expect(await psr.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); }); - it("check few permissions", async () => { - const role1 = ethers.utils.solidityPack(["address", "string"], [opbnbtestnet.RESILIENT_ORACLE, "pause()"]); - - const roleHash = ethers.utils.keccak256(role1); - expect(await acm.hasRole(roleHash, opbnbtestnet.NORMAL_TIMELOCK)).to.be.true; - - const role2 = ethers.utils.solidityPack( - ["address", "string"], - [opbnbtestnet.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], - ); - - const roleHash2 = ethers.utils.keccak256(role2); - expect(await acm.hasRole(roleHash2, opbnbtestnet.NORMAL_TIMELOCK)).to.be.true; + for (const comptrollerAddress of COMPTROLLERS) { + it(`correct owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + }); + } + + for (const vTokenAddress of VTOKENS) { + it(`correct owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + }); + } + + it("should have the correct pending owner", async () => { + expect(await xvsVaultProxy.admin()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); + expect(await xvsStore.admin()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); }); }); }); diff --git a/simulations/vip-372/sepolia.ts b/simulations/vip-372/sepolia.ts index 592551a4c..3b1e7314a 100644 --- a/simulations/vip-372/sepolia.ts +++ b/simulations/vip-372/sepolia.ts @@ -1,52 +1,97 @@ import { expect } from "chai"; +import { Contract } from "ethers"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip060, { ACM } from "../../multisig/proposals/sepolia/vip-060"; -import vip372, { - DEFAULT_ADMIN_ROLE, - OPBNBTESTNET_ACM_AGGREGATOR, -} from "../../vips/vip-372/bsctestnet"; -import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; -import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; +import vip060 from "../../multisig/proposals/sepolia/vip-060"; +import { + COMPTROLLERS, + CONVERTERS, + CONVERTER_NETWORK, + PLP, + PRIME, + PSR, + REWARD_DISTRIBUTORS, + VTOKENS, + XVS_STORE, +} from "../../multisig/proposals/sepolia/vip-060"; +import vip372 from "../../vips/vip-372/bsctestnet"; +import COMPTROLLER_ABI from "./abi/Comptroller.json"; +import CONVERTER_NETWORK_ABI from "./abi/ConverterNetwork.json"; +import PRIME_ABI from "./abi/Prime.json"; +import PRIME_LIQUIDITY_PROVIDER_ABI from "./abi/PrimeLiquidityProvider.json"; +import PSR_ABI from "./abi/ProtocolShareReserve.json"; +import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistributor.json"; +import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; +import VTOKEN_ABI from "./abi/VToken.json"; +import XVS_STORE_ABI from "./abi/XVSStore.json"; +import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; const { sepolia } = NETWORK_ADDRESSES; -forking(6831661, async () => { +forking(6460097, async () => { + const provider = ethers.provider; + let prime: Contract; + let plp: Contract; + const xvsVaultProxy = new ethers.Contract(sepolia.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); + const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); + before(async () => { + prime = new ethers.Contract(PRIME, PRIME_ABI, provider); + plp = new ethers.Contract(PLP, PRIME_LIQUIDITY_PROVIDER_ABI, provider); await pretendExecutingVip(await vip060()); }); - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip372(), { - callbackAfterExecution: async txResponse => { - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [95]); - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [42]); - await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); - await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); - }, - }); + testForkedNetworkVipCommands("vip350", await vip372()); - describe("Post-VIP behaviour", async () => { - const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); - it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { - expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; + describe("Post-VIP behavior", async () => { + for (const converter of CONVERTERS) { + it(`owner for ${converter}`, async () => { + const c = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); + expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + } + + it(`owner for converter network`, async () => { + const c = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); + expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); }); - it("check few permissions", async () => { - const role1 = ethers.utils.solidityPack(["address", "string"], [sepolia.RESILIENT_ORACLE, "pause()"]); + it(`correct owner `, async () => { + expect(await prime.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + expect(await plp.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + + for (const rewardDistributor of REWARD_DISTRIBUTORS) { + it(`correct owner for ${rewardDistributor}`, async () => { + const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); + expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + } + + it(`correct owner for psr`, async () => { + const psr = new ethers.Contract(PSR, PSR_ABI, provider); + expect(await psr.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); - const roleHash = ethers.utils.keccak256(role1); - expect(await acm.hasRole(roleHash, sepolia.NORMAL_TIMELOCK)).to.be.true; + for (const comptrollerAddress of COMPTROLLERS) { + it(`correct owner for ${comptrollerAddress}`, async () => { + const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); + expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + } - const role2 = ethers.utils.solidityPack( - ["address", "string"], - [sepolia.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], - ); + for (const vTokenAddress of VTOKENS) { + it(`correct owner for ${vTokenAddress}`, async () => { + const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); + expect(await v.owner()).to.equal(sepolia.NORMAL_TIMELOCK); + }); + } - const roleHash2 = ethers.utils.keccak256(role2); - expect(await acm.hasRole(roleHash2, sepolia.NORMAL_TIMELOCK)).to.be.true; + it("should have the correct pending owner", async () => { + expect(await xvsVaultProxy.admin()).to.equal(sepolia.NORMAL_TIMELOCK); + expect(await xvsStore.admin()).to.equal(sepolia.NORMAL_TIMELOCK); }); }); }); diff --git a/simulations/vip-373/arbitrumsepolia.ts b/simulations/vip-373/arbitrumsepolia.ts index 8e91d5ec4..f21aba685 100644 --- a/simulations/vip-373/arbitrumsepolia.ts +++ b/simulations/vip-373/arbitrumsepolia.ts @@ -2,10 +2,9 @@ import { expect } from "chai"; import { Contract } from "ethers"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip014, { ACM } from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import vip014 from "../../multisig/proposals/arbitrumsepolia/vip-014"; import vip373, { ARBITRUM_SEPOLIA_BOUND_VALIDATOR, ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN, diff --git a/simulations/vip-373/opbnbtestnet.ts b/simulations/vip-373/opbnbtestnet.ts index cf8a1608e..656c7bfac 100644 --- a/simulations/vip-373/opbnbtestnet.ts +++ b/simulations/vip-373/opbnbtestnet.ts @@ -2,14 +2,10 @@ import { expect } from "chai"; import { Contract } from "ethers"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip021, { ACM } from "../../multisig/proposals/opbnbtestnet/vip-021"; -import vip373, { - OPBNBTESTNET_BOUND_VALIDATOR, - OPBNBTESTNET_XVS_BRIDGE_ADMIN, -} from "../../vips/vip-373/bsctestnet"; +import vip021 from "../../multisig/proposals/opbnbtestnet/vip-021"; +import vip373, { OPBNBTESTNET_BOUND_VALIDATOR, OPBNBTESTNET_XVS_BRIDGE_ADMIN } from "../../vips/vip-373/bsctestnet"; import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; @@ -38,8 +34,7 @@ forking(41162234, async () => { await pretendExecutingVip(await vip021()); }); - testForkedNetworkVipCommands("vip373", await vip373(), { - }); + testForkedNetworkVipCommands("vip373", await vip373(), {}); describe("Post-VIP behaviour", async () => { it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { diff --git a/simulations/vip-373/sepolia.ts b/simulations/vip-373/sepolia.ts index 4b4127aa8..b3bfe623e 100644 --- a/simulations/vip-373/sepolia.ts +++ b/simulations/vip-373/sepolia.ts @@ -4,7 +4,7 @@ import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip060, { ACM } from "../../multisig/proposals/sepolia/vip-060"; +import vip060 from "../../multisig/proposals/sepolia/vip-060"; import vip373, { SEPOLIA_BOUND_VALIDATOR, SEPOLIA_XVS_BRIDGE_ADMIN, @@ -48,7 +48,6 @@ forking(6831661, async () => { xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); }); - it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { expect(await xvsBridgeAdmin.owner()).to.be.equals(sepolia.NORMAL_TIMELOCK); }); diff --git a/vips/vip-371/bsctestnet.ts b/vips/vip-371/bsctestnet.ts index 4f6c0d852..e7f7d9a9a 100644 --- a/vips/vip-371/bsctestnet.ts +++ b/vips/vip-371/bsctestnet.ts @@ -1,29 +1,17 @@ import { LzChainId, ProposalType } from "src/types"; import { makeProposal } from "src/utils"; -import { - PLP as ARBITRUMSEPOLIA_PLP, - PRIME as ARBITRUMSEPOLIA_PRIME, -} from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import { REWARD_DISTRIBUTORS as ARBITRUMSEPOLIA_REWARD_DISTRIBUTORS } from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import { PSR as ARBITRUMSEPOLIA_PSR } from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import { COMPTROLLERS as ARBITRUMSEPOLIA_COMPTROLLERS } from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import { VTOKENS as ARBITRUMSEPOLIA_VTOKENS } from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import { POOL_REGISTRY as ARBITRUMSEPOLIA_POOL_REGISTRY } from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import { PSR as OPBNBTESTNET_PSR } from "../../multisig/proposals/opbnbtestnet/vip-021"; -import { COMPTROLLERS as OPBNBTESTNET_COMPTROLLERS } from "../../multisig/proposals/opbnbtestnet/vip-021"; -import { VTOKENS as OPBNBTESTNET_VTOKENS } from "../../multisig/proposals/opbnbtestnet/vip-021"; -import { POOL_REGISTRY as OPBNBTESTNET_POOL_REGISTRY } from "../../multisig/proposals/opbnbtestnet/vip-021"; -import { CONVERTERS as SEPOLIA_CONVERTERS } from "../../multisig/proposals/sepolia/vip-060"; -import { CONVERTER_NETWORK as SEPOLIA_CONVERTER_NETWORK } from "../../multisig/proposals/sepolia/vip-060"; -import { PLP as SEPOLIA_PLP, PRIME as SEPOLIA_PRIME } from "../../multisig/proposals/sepolia/vip-060"; -import { REWARD_DISTRIBUTORS as SEPOLIA_REWARD_DISTRIBUTORS } from "../../multisig/proposals/sepolia/vip-060"; -import { PSR as SEPOLIA_PSR } from "../../multisig/proposals/sepolia/vip-060"; -import { COMPTROLLERS as SEPOLIA_COMPTROLLERS } from "../../multisig/proposals/sepolia/vip-060"; -import { VTOKENS as SEPOLIA_VTOKENS } from "../../multisig/proposals/sepolia/vip-060"; -import { POOL_REGISTRY as SEPOLIA_POOL_REGISTRY } from "../../multisig/proposals/sepolia/vip-060"; +export const SEPOLIA_ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; +export const ARBITRUM_SEPOLIA_ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; +export const OPBNBTESTNET_ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; -const vip352 = () => { +export const ARBITRUMSEPOLIA_ACM_AGGREGATOR = "0x4fCbfE445396f31005b3Fd2F6DE2A986d6E2dCB5"; +export const OPBNBTESTNET_ACM_AGGREGATOR = "0xbDd501dB1B0D6aab299CE69ef5B86C8578947AD0"; +export const SEPOLIA_ACM_AGGREGATOR = "0x0653830c55035d678e1287b2d4550519fd263d0e"; + +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + +const vip371 = () => { const meta = { version: "v2", title: "VIP-332 accept ownership & give permissions to Normal Timelock", @@ -35,149 +23,82 @@ const vip352 = () => { return makeProposal( [ { - target: SEPOLIA_CONVERTER_NETWORK, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }, - ...SEPOLIA_CONVERTERS.map(converter => { - return { - target: converter, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }; - }), - { - target: SEPOLIA_PRIME, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, + target: ARBITRUM_SEPOLIA_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ARBITRUMSEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.arbitrumsepolia, }, { - target: SEPOLIA_PLP, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, + target: ARBITRUMSEPOLIA_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [1], + dstChainId: LzChainId.arbitrumsepolia, }, { - target: ARBITRUMSEPOLIA_PRIME, - signature: "acceptOwnership()", - params: [], + target: ARBITRUMSEPOLIA_ACM_AGGREGATOR, + signature: "executeRevokePermissions(uint256)", + params: [1], dstChainId: LzChainId.arbitrumsepolia, }, { - target: ARBITRUMSEPOLIA_PLP, - signature: "acceptOwnership()", - params: [], + target: ARBITRUM_SEPOLIA_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ARBITRUMSEPOLIA_ACM_AGGREGATOR], dstChainId: LzChainId.arbitrumsepolia, }, - ...SEPOLIA_REWARD_DISTRIBUTORS.map(rewardDistirbutor => { - return { - target: rewardDistirbutor, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }; - }), - ...ARBITRUMSEPOLIA_REWARD_DISTRIBUTORS.map(rewardDistirbutor => { - return { - target: rewardDistirbutor, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }; - }), { - target: SEPOLIA_PSR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, + target: OPBNBTESTNET_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR], + dstChainId: LzChainId.opbnbtestnet, }, { - target: ARBITRUMSEPOLIA_PSR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, + target: OPBNBTESTNET_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.opbnbtestnet, }, { - target: OPBNBTESTNET_PSR, - signature: "acceptOwnership()", - params: [], + target: OPBNBTESTNET_ACM_AGGREGATOR, + signature: "executeRevokePermissions(uint256)", + params: [0], dstChainId: LzChainId.opbnbtestnet, }, { - target: SEPOLIA_POOL_REGISTRY, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, + target: OPBNBTESTNET_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR], + dstChainId: LzChainId.opbnbtestnet, }, - ...SEPOLIA_COMPTROLLERS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }; - }), - ...SEPOLIA_VTOKENS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }; - }), { - target: ARBITRUMSEPOLIA_POOL_REGISTRY, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, + target: SEPOLIA_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.sepolia, }, - ...ARBITRUMSEPOLIA_COMPTROLLERS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }; - }), - ...ARBITRUMSEPOLIA_VTOKENS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }; - }), - { - target: OPBNBTESTNET_POOL_REGISTRY, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbtestnet, + target: SEPOLIA_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.sepolia, + }, + { + target: SEPOLIA_ACM_AGGREGATOR, + signature: "executeRevokePermissions(uint256)", + params: [0], + dstChainId: LzChainId.sepolia, + }, + { + target: SEPOLIA_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.sepolia, }, - ...OPBNBTESTNET_COMPTROLLERS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }; - }), - ...OPBNBTESTNET_VTOKENS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }; - }), ], meta, ProposalType.REGULAR, ); }; -export default vip352; +export default vip371; diff --git a/vips/vip-371/bscmainnet.ts b/vips/vip-372/bscmainnet.ts similarity index 98% rename from vips/vip-371/bscmainnet.ts rename to vips/vip-372/bscmainnet.ts index 12d539b44..c75db413a 100644 --- a/vips/vip-371/bscmainnet.ts +++ b/vips/vip-372/bscmainnet.ts @@ -20,10 +20,10 @@ import { VTOKENS as OPBNBMAINNET_VTOKENS } from "../../multisig/proposals/opbnbm import { POOL_REGISTRY as OPBNBMAINNET_POOL_REGISTRY } from "../../multisig/proposals/opbnbmainnet/vip-021"; import { PSR as OPBNBMAINNET_PSR } from "../../multisig/proposals/opbnbmainnet/vip-021"; -const vip371 = () => { +const vip372 = () => { const meta = { version: "v2", - title: "VIP-371", + title: "VIP-372", description: `### Description`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", @@ -177,4 +177,4 @@ const vip371 = () => { ProposalType.REGULAR, ); }; -export default vip371; +export default vip372; diff --git a/vips/vip-372/bsctestnet.ts b/vips/vip-372/bsctestnet.ts index a0ecc95fe..071c473a1 100644 --- a/vips/vip-372/bsctestnet.ts +++ b/vips/vip-372/bsctestnet.ts @@ -1,16 +1,27 @@ -import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { LzChainId, ProposalType } from "src/types"; import { makeProposal } from "src/utils"; -export const SEPOLIA_ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; -export const ARBITRUM_SEPOLIA_ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; -export const OPBNBTESTNET_ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; - -export const ARBITRUMSEPOLIA_ACM_AGGREGATOR = "0x4fCbfE445396f31005b3Fd2F6DE2A986d6E2dCB5"; -export const OPBNBTESTNET_ACM_AGGREGATOR = "0xbDd501dB1B0D6aab299CE69ef5B86C8578947AD0"; -export const SEPOLIA_ACM_AGGREGATOR = "0x0653830c55035d678e1287b2d4550519fd263d0e"; - -export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; +import { + PLP as ARBITRUMSEPOLIA_PLP, + PRIME as ARBITRUMSEPOLIA_PRIME, +} from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import { REWARD_DISTRIBUTORS as ARBITRUMSEPOLIA_REWARD_DISTRIBUTORS } from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import { PSR as ARBITRUMSEPOLIA_PSR } from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import { COMPTROLLERS as ARBITRUMSEPOLIA_COMPTROLLERS } from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import { VTOKENS as ARBITRUMSEPOLIA_VTOKENS } from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import { POOL_REGISTRY as ARBITRUMSEPOLIA_POOL_REGISTRY } from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import { PSR as OPBNBTESTNET_PSR } from "../../multisig/proposals/opbnbtestnet/vip-021"; +import { COMPTROLLERS as OPBNBTESTNET_COMPTROLLERS } from "../../multisig/proposals/opbnbtestnet/vip-021"; +import { VTOKENS as OPBNBTESTNET_VTOKENS } from "../../multisig/proposals/opbnbtestnet/vip-021"; +import { POOL_REGISTRY as OPBNBTESTNET_POOL_REGISTRY } from "../../multisig/proposals/opbnbtestnet/vip-021"; +import { CONVERTERS as SEPOLIA_CONVERTERS } from "../../multisig/proposals/sepolia/vip-060"; +import { CONVERTER_NETWORK as SEPOLIA_CONVERTER_NETWORK } from "../../multisig/proposals/sepolia/vip-060"; +import { PLP as SEPOLIA_PLP, PRIME as SEPOLIA_PRIME } from "../../multisig/proposals/sepolia/vip-060"; +import { REWARD_DISTRIBUTORS as SEPOLIA_REWARD_DISTRIBUTORS } from "../../multisig/proposals/sepolia/vip-060"; +import { PSR as SEPOLIA_PSR } from "../../multisig/proposals/sepolia/vip-060"; +import { COMPTROLLERS as SEPOLIA_COMPTROLLERS } from "../../multisig/proposals/sepolia/vip-060"; +import { VTOKENS as SEPOLIA_VTOKENS } from "../../multisig/proposals/sepolia/vip-060"; +import { POOL_REGISTRY as SEPOLIA_POOL_REGISTRY } from "../../multisig/proposals/sepolia/vip-060"; const vip372 = () => { const meta = { @@ -24,79 +35,146 @@ const vip372 = () => { return makeProposal( [ { - target: ARBITRUM_SEPOLIA_ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, ARBITRUMSEPOLIA_ACM_AGGREGATOR], - dstChainId: LzChainId.arbitrumsepolia, + target: SEPOLIA_CONVERTER_NETWORK, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, }, + ...SEPOLIA_CONVERTERS.map(converter => { + return { + target: converter, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }; + }), { - target: ARBITRUMSEPOLIA_ACM_AGGREGATOR, - signature: "executeGrantPermissions(uint256)", - params: [1], - dstChainId: LzChainId.arbitrumsepolia, + target: SEPOLIA_PRIME, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, }, { - target: ARBITRUMSEPOLIA_ACM_AGGREGATOR, - signature: "executeRevokePermissions(uint256)", - params: [1], - dstChainId: LzChainId.arbitrumsepolia, + target: SEPOLIA_PLP, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, }, { - target: ARBITRUM_SEPOLIA_ACM, - signature: "revokeRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, ARBITRUMSEPOLIA_ACM_AGGREGATOR], + target: ARBITRUMSEPOLIA_PRIME, + signature: "acceptOwnership()", + params: [], dstChainId: LzChainId.arbitrumsepolia, }, - { - target: OPBNBTESTNET_ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR], - dstChainId: LzChainId.opbnbtestnet, + target: ARBITRUMSEPOLIA_PLP, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, }, + ...SEPOLIA_REWARD_DISTRIBUTORS.map(rewardDistirbutor => { + return { + target: rewardDistirbutor, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }; + }), + + ...ARBITRUMSEPOLIA_REWARD_DISTRIBUTORS.map(rewardDistirbutor => { + return { + target: rewardDistirbutor, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }; + }), { - target: OPBNBTESTNET_ACM_AGGREGATOR, - signature: "executeGrantPermissions(uint256)", - params: [0], - dstChainId: LzChainId.opbnbtestnet, + target: SEPOLIA_PSR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, }, { - target: OPBNBTESTNET_ACM_AGGREGATOR, - signature: "executeRevokePermissions(uint256)", - params: [0], - dstChainId: LzChainId.opbnbtestnet, + target: ARBITRUMSEPOLIA_PSR, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, }, { - target: OPBNBTESTNET_ACM, - signature: "revokeRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR], + target: OPBNBTESTNET_PSR, + signature: "acceptOwnership()", + params: [], dstChainId: LzChainId.opbnbtestnet, }, - - { - target: SEPOLIA_ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR], - dstChainId: LzChainId.sepolia, - }, { - target: SEPOLIA_ACM_AGGREGATOR, - signature: "executeGrantPermissions(uint256)", - params: [0], + target: SEPOLIA_POOL_REGISTRY, + signature: "acceptOwnership()", + params: [], dstChainId: LzChainId.sepolia, }, + ...SEPOLIA_COMPTROLLERS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }; + }), + ...SEPOLIA_VTOKENS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.sepolia, + }; + }), + { - target: SEPOLIA_ACM_AGGREGATOR, - signature: "executeRevokePermissions(uint256)", - params: [0], - dstChainId: LzChainId.sepolia, + target: ARBITRUMSEPOLIA_POOL_REGISTRY, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, }, + ...ARBITRUMSEPOLIA_COMPTROLLERS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }; + }), + ...ARBITRUMSEPOLIA_VTOKENS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.arbitrumsepolia, + }; + }), + { - target: SEPOLIA_ACM, - signature: "revokeRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR], - dstChainId: LzChainId.sepolia, + target: OPBNBTESTNET_POOL_REGISTRY, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbtestnet, }, + ...OPBNBTESTNET_COMPTROLLERS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }; + }), + ...OPBNBTESTNET_VTOKENS.map(comptroller => { + return { + target: comptroller, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opbnbtestnet, + }; + }), ], meta, ProposalType.REGULAR, From 25306f8b827fac5fcdf6d582bdd9c270b53ca01d Mon Sep 17 00:00:00 2001 From: web3rover Date: Thu, 10 Oct 2024 16:24:00 +0400 Subject: [PATCH 028/178] fix: added updated indexes --- simulations/vip-371/arbitrumsepolia.ts | 2 +- simulations/vip-371/opbnbtestnet.ts | 2 +- simulations/vip-371/sepolia.ts | 2 +- simulations/vip-372/arbitrumsepolia.ts | 2 +- simulations/vip-372/opbnbtestnet.ts | 2 +- simulations/vip-372/sepolia.ts | 2 +- simulations/vip-373/arbitrumsepolia.ts | 2 +- simulations/vip-373/opbnbtestnet.ts | 2 +- simulations/vip-373/sepolia.ts | 2 +- vips/vip-371/bsctestnet.ts | 12 ++++++------ 10 files changed, 15 insertions(+), 15 deletions(-) diff --git a/simulations/vip-371/arbitrumsepolia.ts b/simulations/vip-371/arbitrumsepolia.ts index c6b73d12a..f594c9ced 100644 --- a/simulations/vip-371/arbitrumsepolia.ts +++ b/simulations/vip-371/arbitrumsepolia.ts @@ -11,7 +11,7 @@ import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { arbitrumsepolia } = NETWORK_ADDRESSES; -forking(86016842, async () => { +forking(87457288, async () => { before(async () => { await pretendExecutingVip(await vip014()); }); diff --git a/simulations/vip-371/opbnbtestnet.ts b/simulations/vip-371/opbnbtestnet.ts index 3f1da96c8..64445db23 100644 --- a/simulations/vip-371/opbnbtestnet.ts +++ b/simulations/vip-371/opbnbtestnet.ts @@ -11,7 +11,7 @@ import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { opbnbtestnet } = NETWORK_ADDRESSES; -forking(41162234, async () => { +forking(41684455, async () => { before(async () => { await pretendExecutingVip(await vip021()); }); diff --git a/simulations/vip-371/sepolia.ts b/simulations/vip-371/sepolia.ts index cd01e78c4..0f34c0522 100644 --- a/simulations/vip-371/sepolia.ts +++ b/simulations/vip-371/sepolia.ts @@ -11,7 +11,7 @@ import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { sepolia } = NETWORK_ADDRESSES; -forking(6831661, async () => { +forking(6850243, async () => { before(async () => { await pretendExecutingVip(await vip060()); }); diff --git a/simulations/vip-372/arbitrumsepolia.ts b/simulations/vip-372/arbitrumsepolia.ts index 2470caaee..d5b0e4b05 100644 --- a/simulations/vip-372/arbitrumsepolia.ts +++ b/simulations/vip-372/arbitrumsepolia.ts @@ -26,7 +26,7 @@ import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; const { arbitrumsepolia } = NETWORK_ADDRESSES; -forking(70004884, async () => { +forking(87457288, async () => { const provider = ethers.provider; let prime: Contract; let plp: Contract; diff --git a/simulations/vip-372/opbnbtestnet.ts b/simulations/vip-372/opbnbtestnet.ts index 089ad6e02..79a0ca82a 100644 --- a/simulations/vip-372/opbnbtestnet.ts +++ b/simulations/vip-372/opbnbtestnet.ts @@ -13,7 +13,7 @@ import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; const { opbnbtestnet } = NETWORK_ADDRESSES; -forking(36325286, async () => { +forking(41684455, async () => { const provider = ethers.provider; const xvsVaultProxy = new ethers.Contract(opbnbtestnet.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); diff --git a/simulations/vip-372/sepolia.ts b/simulations/vip-372/sepolia.ts index 3b1e7314a..2c8bfd75a 100644 --- a/simulations/vip-372/sepolia.ts +++ b/simulations/vip-372/sepolia.ts @@ -30,7 +30,7 @@ import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; const { sepolia } = NETWORK_ADDRESSES; -forking(6460097, async () => { +forking(6850243, async () => { const provider = ethers.provider; let prime: Contract; let plp: Contract; diff --git a/simulations/vip-373/arbitrumsepolia.ts b/simulations/vip-373/arbitrumsepolia.ts index f21aba685..ebb9a0b1f 100644 --- a/simulations/vip-373/arbitrumsepolia.ts +++ b/simulations/vip-373/arbitrumsepolia.ts @@ -19,7 +19,7 @@ import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; const XVS_BRIDGE = "0xFdC5cEC63FD167DA46cF006585b30D03B104eFD4"; const { arbitrumsepolia } = NETWORK_ADDRESSES; -forking(86016842, async () => { +forking(87457288, async () => { const provider = ethers.provider; let chainLinkOracle: Contract; let redstoneOracle: Contract; diff --git a/simulations/vip-373/opbnbtestnet.ts b/simulations/vip-373/opbnbtestnet.ts index 656c7bfac..a2f952530 100644 --- a/simulations/vip-373/opbnbtestnet.ts +++ b/simulations/vip-373/opbnbtestnet.ts @@ -16,7 +16,7 @@ import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; const XVS_BRIDGE = "0xA03205bC635A772E533E7BE36b5701E331a70ea3"; const { opbnbtestnet } = NETWORK_ADDRESSES; -forking(41162234, async () => { +forking(41684455, async () => { const provider = ethers.provider; let binanceOracle: Contract; let resilientOracle: Contract; diff --git a/simulations/vip-373/sepolia.ts b/simulations/vip-373/sepolia.ts index b3bfe623e..2436b36a9 100644 --- a/simulations/vip-373/sepolia.ts +++ b/simulations/vip-373/sepolia.ts @@ -20,7 +20,7 @@ import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; const XVS_BRIDGE = "0xc340b7d3406502F43dC11a988E4EC5bbE536E642"; const { sepolia } = NETWORK_ADDRESSES; -forking(6831661, async () => { +forking(6850243, async () => { const provider = ethers.provider; let chainLinkOracle: Contract; let redstoneOracle: Contract; diff --git a/vips/vip-371/bsctestnet.ts b/vips/vip-371/bsctestnet.ts index e7f7d9a9a..6789a96fa 100644 --- a/vips/vip-371/bsctestnet.ts +++ b/vips/vip-371/bsctestnet.ts @@ -31,13 +31,13 @@ const vip371 = () => { { target: ARBITRUMSEPOLIA_ACM_AGGREGATOR, signature: "executeGrantPermissions(uint256)", - params: [1], + params: [2], dstChainId: LzChainId.arbitrumsepolia, }, { target: ARBITRUMSEPOLIA_ACM_AGGREGATOR, signature: "executeRevokePermissions(uint256)", - params: [1], + params: [2], dstChainId: LzChainId.arbitrumsepolia, }, { @@ -56,13 +56,13 @@ const vip371 = () => { { target: OPBNBTESTNET_ACM_AGGREGATOR, signature: "executeGrantPermissions(uint256)", - params: [0], + params: [1], dstChainId: LzChainId.opbnbtestnet, }, { target: OPBNBTESTNET_ACM_AGGREGATOR, signature: "executeRevokePermissions(uint256)", - params: [0], + params: [1], dstChainId: LzChainId.opbnbtestnet, }, { @@ -81,13 +81,13 @@ const vip371 = () => { { target: SEPOLIA_ACM_AGGREGATOR, signature: "executeGrantPermissions(uint256)", - params: [0], + params: [1], dstChainId: LzChainId.sepolia, }, { target: SEPOLIA_ACM_AGGREGATOR, signature: "executeRevokePermissions(uint256)", - params: [0], + params: [1], dstChainId: LzChainId.sepolia, }, { From b2d2a40b36b112a944a969c6a814b57f1dadd2e5 Mon Sep 17 00:00:00 2001 From: web3rover Date: Thu, 10 Oct 2024 16:40:45 +0400 Subject: [PATCH 029/178] fix: updated indexes --- simulations/vip-371/arbitrumsepolia.ts | 4 ++-- simulations/vip-371/opbnbtestnet.ts | 4 ++-- simulations/vip-371/sepolia.ts | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/simulations/vip-371/arbitrumsepolia.ts b/simulations/vip-371/arbitrumsepolia.ts index f594c9ced..fc6d6761c 100644 --- a/simulations/vip-371/arbitrumsepolia.ts +++ b/simulations/vip-371/arbitrumsepolia.ts @@ -18,8 +18,8 @@ forking(87457288, async () => { testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { callbackAfterExecution: async txResponse => { - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [84]); - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [35]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [88]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [62]); await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); }, diff --git a/simulations/vip-371/opbnbtestnet.ts b/simulations/vip-371/opbnbtestnet.ts index 64445db23..387adb352 100644 --- a/simulations/vip-371/opbnbtestnet.ts +++ b/simulations/vip-371/opbnbtestnet.ts @@ -18,8 +18,8 @@ forking(41684455, async () => { testForkedNetworkVipCommands("vip371", await vip371(), { callbackAfterExecution: async txResponse => { - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [70]); - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [20]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [74]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [48]); await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); }, diff --git a/simulations/vip-371/sepolia.ts b/simulations/vip-371/sepolia.ts index 0f34c0522..444884cf2 100644 --- a/simulations/vip-371/sepolia.ts +++ b/simulations/vip-371/sepolia.ts @@ -18,8 +18,8 @@ forking(6850243, async () => { testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { callbackAfterExecution: async txResponse => { - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [95]); - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [42]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [99]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [67]); await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); }, From a02a7e93ec95d8110fa42721ff005edd32292e0b Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Mon, 14 Oct 2024 16:25:07 +0530 Subject: [PATCH 030/178] feat: add zksync vip to reduce distribution speed of the markets --- .../proposals/zksyncmainnet/vip-014/index.ts | 24 + .../vip-014/abi/rewardsDistributor.json | 1129 +++++++++++++++++ .../zksyncmainnet/vip-014/index.ts | 68 + vips/vip-382/bscmainnet.ts | 29 + 4 files changed, 1250 insertions(+) create mode 100644 multisig/proposals/zksyncmainnet/vip-014/index.ts create mode 100644 multisig/simulations/zksyncmainnet/vip-014/abi/rewardsDistributor.json create mode 100644 multisig/simulations/zksyncmainnet/vip-014/index.ts create mode 100644 vips/vip-382/bscmainnet.ts diff --git a/multisig/proposals/zksyncmainnet/vip-014/index.ts b/multisig/proposals/zksyncmainnet/vip-014/index.ts new file mode 100644 index 000000000..3eeef0765 --- /dev/null +++ b/multisig/proposals/zksyncmainnet/vip-014/index.ts @@ -0,0 +1,24 @@ +import { makeProposal } from "src/utils"; + +export const REWARD_DISTRIBUTOR_CORE_0 = "0x7C7846A74AB38A8d554Bc5f7652eCf8Efb58c894"; +export const VUSDC_E_CORE = "0x1aF23bD57c62A99C59aD48236553D0Dd11e49D2D"; +export const VUSDT_CORE = "0x69cDA960E3b20DFD480866fFfd377Ebe40bd0A46"; +export const VWBTC_CORE = "0xAF8fD83cFCbe963211FAaf1847F0F217F80B4719"; +export const VWETH_CORE = "0x1Fa916C27c7C2c4602124A14C77Dbb40a5FF1BE8"; +export const VZK_CORE = "0x697a70779C1A03Ba2BD28b7627a902BFf831b616"; + +export const vip014 = () => { + return makeProposal([ + { + target: REWARD_DISTRIBUTOR_CORE_0, + signature: "setRewardTokenSpeeds(address[],uint256[],uint256[])", + params: [ + [VWETH_CORE, VWBTC_CORE, VUSDT_CORE, VUSDC_E_CORE, VZK_CORE], + ["370370370370370", "370370370370370", "277777777777777", "555555555555555", "277777777777777"], + ["92592592592592", "92592592592592", "69444444444444", "138888888888888", "69444444444444"], + ], + }, + ]); +}; + +export default vip014; diff --git a/multisig/simulations/zksyncmainnet/vip-014/abi/rewardsDistributor.json b/multisig/simulations/zksyncmainnet/vip-014/abi/rewardsDistributor.json new file mode 100644 index 000000000..7035bb9a5 --- /dev/null +++ b/multisig/simulations/zksyncmainnet/vip-014/abi/rewardsDistributor.json @@ -0,0 +1,1129 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "previousAdmin", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAdmin", + "type": "address" + } + ], + "name": "AdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "beacon", + "type": "address" + } + ], + "name": "BeaconUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "implementation", + "type": "address" + } + ], + "name": "Upgraded", + "type": "event" + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "inputs": [], + "name": "admin", + "outputs": [ + { + "internalType": "address", + "name": "admin_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newAdmin", + "type": "address" + } + ], + "name": "changeAdmin", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [ + { + "internalType": "address", + "name": "implementation_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + } + ], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "upgradeToAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "stateMutability": "payable", + "type": "receive" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "loopsLimit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "requiredLoops", + "type": "uint256" + } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint32", + "name": "newBlock", + "type": "uint32" + } + ], + "name": "BorrowLastRewardingBlockUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "contributor", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSpeed", + "type": "uint256" + } + ], + "name": "ContributorRewardTokenSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "contributor", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "rewardAccrued", + "type": "uint256" + } + ], + "name": "ContributorRewardsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "rewardTokenDelta", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "rewardTokenTotal", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "rewardTokenBorrowIndex", + "type": "uint256" + } + ], + "name": "DistributedBorrowerRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "supplier", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "rewardTokenDelta", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "rewardTokenTotal", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "rewardTokenSupplyIndex", + "type": "uint256" + } + ], + "name": "DistributedSupplierRewardToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "MarketInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMaxLoopsLimit", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newmaxLoopsLimit", + "type": "uint256" + } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "mantissa", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "RewardTokenBorrowIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSpeed", + "type": "uint256" + } + ], + "name": "RewardTokenBorrowSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "recipient", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "RewardTokenGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "RewardTokenSupplyIndexUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSpeed", + "type": "uint256" + } + ], + "name": "RewardTokenSupplySpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint32", + "name": "newBlock", + "type": "uint32" + } + ], + "name": "SupplyLastRewardingBlockUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "INITIAL_INDEX", + "outputs": [ + { + "internalType": "uint224", + "name": "", + "type": "uint224" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "holder", + "type": "address" + }, + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + } + ], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "holder", + "type": "address" + } + ], + "name": "claimRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "mantissa", + "type": "uint256" + } + ], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "distributeBorrowerRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "supplier", + "type": "address" + } + ], + "name": "distributeSupplierRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumber", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "recipient", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "grantRewardToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract Comptroller", + "name": "comptroller_", + "type": "address" + }, + { + "internalType": "contract IERC20Upgradeable", + "name": "rewardToken_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "loopsLimit_", + "type": "uint256" + }, + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "initializeMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "lastContributorBlock", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "rewardToken", + "outputs": [ + { + "internalType": "contract IERC20Upgradeable", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "rewardTokenAccrued", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "rewardTokenBorrowSpeeds", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "rewardTokenBorrowState", + "outputs": [ + { + "internalType": "uint224", + "name": "index", + "type": "uint224" + }, + { + "internalType": "uint32", + "name": "block", + "type": "uint32" + }, + { + "internalType": "uint32", + "name": "lastRewardingBlock", + "type": "uint32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "rewardTokenBorrowerIndex", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "rewardTokenContributorSpeeds", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "rewardTokenSupplierIndex", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "rewardTokenSupplySpeeds", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "rewardTokenSupplyState", + "outputs": [ + { + "internalType": "uint224", + "name": "index", + "type": "uint224" + }, + { + "internalType": "uint32", + "name": "block", + "type": "uint32" + }, + { + "internalType": "uint32", + "name": "lastRewardingBlock", + "type": "uint32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "contributor", + "type": "address" + }, + { + "internalType": "uint256", + "name": "rewardTokenSpeed", + "type": "uint256" + } + ], + "name": "setContributorRewardTokenSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint32[]", + "name": "supplyLastRewardingBlocks", + "type": "uint32[]" + }, + { + "internalType": "uint32[]", + "name": "borrowLastRewardingBlocks", + "type": "uint32[]" + } + ], + "name": "setLastRewardingBlocks", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "limit", + "type": "uint256" + } + ], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "supplySpeeds", + "type": "uint256[]" + }, + { + "internalType": "uint256[]", + "name": "borrowSpeeds", + "type": "uint256[]" + } + ], + "name": "setRewardTokenSpeeds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "contributor", + "type": "address" + } + ], + "name": "updateContributorRewards", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "mantissa", + "type": "uint256" + } + ], + "internalType": "struct ExponentialNoError.Exp", + "name": "marketBorrowIndex", + "type": "tuple" + } + ], + "name": "updateRewardTokenBorrowIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "updateRewardTokenSupplyIndex", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_logic", + "type": "address" + }, + { + "internalType": "address", + "name": "admin_", + "type": "address" + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes" + } + ], + "stateMutability": "payable", + "type": "constructor" + } +] diff --git a/multisig/simulations/zksyncmainnet/vip-014/index.ts b/multisig/simulations/zksyncmainnet/vip-014/index.ts new file mode 100644 index 000000000..c5e80e6da --- /dev/null +++ b/multisig/simulations/zksyncmainnet/vip-014/index.ts @@ -0,0 +1,68 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip014, { + REWARD_DISTRIBUTOR_CORE_0, + VUSDC_E_CORE, + VUSDT_CORE, + VWBTC_CORE, + VWETH_CORE, + VZK_CORE, +} from "../../../proposals/zksyncmainnet/vip-014"; +import REWARD_DISTRIBUTOR_ABI from "./abi/rewardsDistributor.json"; + +type RewardConfig = { + vToken: string; + supplySpeed: string; + borrowSpeed: string; +}; + +const tokensRewardConfig: RewardConfig[] = [ + { + vToken: VUSDT_CORE, + supplySpeed: "277777777777777", + borrowSpeed: "69444444444444", + }, + { + vToken: VUSDC_E_CORE, + supplySpeed: "555555555555555", + borrowSpeed: "138888888888888", + }, + { + vToken: VWBTC_CORE, + supplySpeed: "370370370370370", + borrowSpeed: "92592592592592", + }, + { + vToken: VWETH_CORE, + supplySpeed: "370370370370370", + borrowSpeed: "92592592592592", + }, + { + vToken: VZK_CORE, + supplySpeed: "277777777777777", + borrowSpeed: "69444444444444", + }, +]; + +forking(46537669, async () => { + let rewardsDistributor: Contract; + describe("Post-VIP behavior", async () => { + before(async () => { + rewardsDistributor = await ethers.getContractAt(REWARD_DISTRIBUTOR_ABI, REWARD_DISTRIBUTOR_CORE_0); + await pretendExecutingVip(await vip014()); + }); + + tokensRewardConfig.forEach(config => { + it(`should have borrowSpeed = ${config.borrowSpeed.toString()}`, async () => { + expect(await rewardsDistributor.rewardTokenBorrowSpeeds(config.vToken)).to.equal(config.borrowSpeed); + }); + + it(`should have supplySpeed = ${config.supplySpeed.toString()}`, async () => { + expect(await rewardsDistributor.rewardTokenSupplySpeeds(config.vToken)).to.equal(config.supplySpeed); + }); + }); + }); +}); diff --git a/vips/vip-382/bscmainnet.ts b/vips/vip-382/bscmainnet.ts new file mode 100644 index 000000000..704825209 --- /dev/null +++ b/vips/vip-382/bscmainnet.ts @@ -0,0 +1,29 @@ +import { ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; +import { FAST_TRACK_TIMELOCK } from "src/vip-framework"; + +const vip382 = () => { + const meta = { + version: "v2", + title: "VIP-382 [zkSync] Reduce the distribution speeds of the markets on zkSync", + description: ``, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + + return makeProposal( + [ + { + target: FAST_TRACK_TIMELOCK, + signature: "", + params: [], + value: "1", + }, + ], + meta, + ProposalType.FAST_TRACK, + ); +}; + +export default vip382; From 792a02d54f7c43b3bd24715ebb3acd4ba35723e7 Mon Sep 17 00:00:00 2001 From: Narayan <7037606+web3rover@users.noreply.github.com> Date: Mon, 14 Oct 2024 16:04:26 +0400 Subject: [PATCH 031/178] fix: fixed address Co-authored-by: Jesus Lanchas --- simulations/vip-371/sepolia.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/simulations/vip-371/sepolia.ts b/simulations/vip-371/sepolia.ts index 444884cf2..1f7e53e66 100644 --- a/simulations/vip-371/sepolia.ts +++ b/simulations/vip-371/sepolia.ts @@ -5,7 +5,7 @@ import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; import vip060, { ACM } from "../../multisig/proposals/sepolia/vip-060"; -import vip371, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet"; +import vip371, { DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; From f3dd0262480e0f861f5f447be3a7b3fbac810401 Mon Sep 17 00:00:00 2001 From: Narayan <7037606+web3rover@users.noreply.github.com> Date: Mon, 14 Oct 2024 16:04:32 +0400 Subject: [PATCH 032/178] fix: fixed address Co-authored-by: Jesus Lanchas --- simulations/vip-371/sepolia.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/simulations/vip-371/sepolia.ts b/simulations/vip-371/sepolia.ts index 1f7e53e66..c09655138 100644 --- a/simulations/vip-371/sepolia.ts +++ b/simulations/vip-371/sepolia.ts @@ -28,7 +28,7 @@ forking(6850243, async () => { describe("Post-VIP behaviour", async () => { const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { - expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR)).to.be.false; }); it("check few permissions", async () => { From a07f44d17402f6ab565fd54d45751d30c6820de8 Mon Sep 17 00:00:00 2001 From: Narayan <7037606+web3rover@users.noreply.github.com> Date: Mon, 14 Oct 2024 16:04:39 +0400 Subject: [PATCH 033/178] fix: fixed address Co-authored-by: Jesus Lanchas --- simulations/vip-371/arbitrumsepolia.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/simulations/vip-371/arbitrumsepolia.ts b/simulations/vip-371/arbitrumsepolia.ts index fc6d6761c..a35a6e1b1 100644 --- a/simulations/vip-371/arbitrumsepolia.ts +++ b/simulations/vip-371/arbitrumsepolia.ts @@ -5,7 +5,7 @@ import { expectEvents } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; import vip014, { ACM } from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import vip371, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet"; +import vip371, { DEFAULT_ADMIN_ROLE, ARBITRUMSEPOLIA_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; From f10a4acc45ef75829ab6603a4bbdecaeb7006c13 Mon Sep 17 00:00:00 2001 From: Narayan <7037606+web3rover@users.noreply.github.com> Date: Mon, 14 Oct 2024 16:04:44 +0400 Subject: [PATCH 034/178] fix: fixed address Co-authored-by: Jesus Lanchas --- simulations/vip-371/arbitrumsepolia.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/simulations/vip-371/arbitrumsepolia.ts b/simulations/vip-371/arbitrumsepolia.ts index a35a6e1b1..91e32230f 100644 --- a/simulations/vip-371/arbitrumsepolia.ts +++ b/simulations/vip-371/arbitrumsepolia.ts @@ -29,7 +29,7 @@ forking(87457288, async () => { const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { - expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, ARBITRUMSEPOLIA_ACM_AGGREGATOR)).to.be.false; }); it("check few permissions", async () => { From f820d7bdbd75fe59289b2fb7ce8d07c963f6ccf6 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Wed, 16 Oct 2024 14:34:26 +0530 Subject: [PATCH 035/178] feat: add vip for TWT market configuration on bsctesnet --- simulations/vip-384/abi/ERC20.json | 134 + simulations/vip-384/abi/USDT_ABI.json | 139 + simulations/vip-384/abi/VBep20_ABI.json | 820 +++++ simulations/vip-384/abi/comptroller.json | 2960 +++++++++++++++++ simulations/vip-384/abi/resilientOracle.json | 608 ++++ .../vip-384/abi/singleTokenConverter.json | 1267 +++++++ simulations/vip-384/bsctestnet.ts | 153 + vips/vip-384/bsctestnet.ts | 156 + 8 files changed, 6237 insertions(+) create mode 100644 simulations/vip-384/abi/ERC20.json create mode 100644 simulations/vip-384/abi/USDT_ABI.json create mode 100644 simulations/vip-384/abi/VBep20_ABI.json create mode 100644 simulations/vip-384/abi/comptroller.json create mode 100644 simulations/vip-384/abi/resilientOracle.json create mode 100644 simulations/vip-384/abi/singleTokenConverter.json create mode 100644 simulations/vip-384/bsctestnet.ts create mode 100644 vips/vip-384/bsctestnet.ts diff --git a/simulations/vip-384/abi/ERC20.json b/simulations/vip-384/abi/ERC20.json new file mode 100644 index 000000000..3a509c9c4 --- /dev/null +++ b/simulations/vip-384/abi/ERC20.json @@ -0,0 +1,134 @@ +[ + { + "inputs": [ + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "name": "faucet", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "from", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-384/abi/USDT_ABI.json b/simulations/vip-384/abi/USDT_ABI.json new file mode 100644 index 000000000..fe8789439 --- /dev/null +++ b/simulations/vip-384/abi/USDT_ABI.json @@ -0,0 +1,139 @@ +[ + { + "inputs": [ + { "internalType": "uint256", "name": "_initialAmount", "type": "uint256" }, + { "internalType": "string", "name": "_tokenName", "type": "string" }, + { "internalType": "uint8", "name": "_decimalUnits", "type": "uint8" }, + { "internalType": "string", "name": "_tokenSymbol", "type": "string" } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_owner", "type": "address" }, + { "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "allocateTo", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "_spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-384/abi/VBep20_ABI.json b/simulations/vip-384/abi/VBep20_ABI.json new file mode 100644 index 000000000..a7ae900ba --- /dev/null +++ b/simulations/vip-384/abi/VBep20_ABI.json @@ -0,0 +1,820 @@ +[ + { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "error", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "info", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "detail", "type": "uint256" } + ], + "name": "Failure", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalSupply", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalSupply", "type": "uint256" } + ], + "name": "MintBehalf", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlAddress", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlAddress", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "NewAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ComptrollerInterface", + "name": "oldComptroller", + "type": "address" + }, + { "indexed": false, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } + ], + "name": "NewPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalSupply", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "feeAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "RedeemFee", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "constant": false, + "inputs": [], + "name": "_acceptAdmin", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "_addReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "bytes", "name": "data", "type": "bytes" }], + "name": "_becomeImplementation", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "reduceAmount_", "type": "uint256" }], + "name": "_reduceReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "_resignImplementation", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" }], + "name": "_setComptroller", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel_", "type": "address" }], + "name": "_setInterestRateModel", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address payable", "name": "newPendingAdmin", "type": "address" }], + "name": "_setPendingAdmin", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa_", "type": "uint256" }], + "name": "_setReserveFactor", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" } + ], + "name": "initialize", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" } + ], + "name": "initialize", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "receiver", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newAccessControlManagerAddress", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address payable", "name": "protcolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "newReduceReservesBlockDelta_", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-384/abi/comptroller.json b/simulations/vip-384/abi/comptroller.json new file mode 100644 index 000000000..51c53909e --- /dev/null +++ b/simulations/vip-384/abi/comptroller.json @@ -0,0 +1,2960 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "enum ComptrollerV9Storage.Action", + "name": "action", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "bool", + "name": "pauseState", + "type": "bool" + } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "bool", + "name": "state", + "type": "bool" + } + ], + "name": "ActionProtocolPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "delegate", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "allowDelegatedBorrows", + "type": "bool" + } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "facetAddress", + "type": "address" + }, + { + "internalType": "enum IDiamondCut.FacetCutAction", + "name": "action", + "type": "uint8" + }, + { + "internalType": "bytes4[]", + "name": "functionSelectors", + "type": "bytes4[]" + } + ], + "indexed": false, + "internalType": "struct IDiamondCut.FacetCut[]", + "name": "_diamondCut", + "type": "tuple[]" + } + ], + "name": "DiamondCut", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "venusDelta", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "venusBorrowIndex", + "type": "uint256" + } + ], + "name": "DistributedBorrowerVenus", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "supplier", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "venusDelta", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "venusSupplyIndex", + "type": "uint256" + } + ], + "name": "DistributedSupplierVenus", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "DistributedVAIVaultVenus", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "info", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "detail", + "type": "uint256" + } + ], + "name": "Failure", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "MarketListed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlAddress", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlAddress", + "type": "address" + } + ], + "name": "NewAccessControl", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newBorrowCap", + "type": "uint256" + } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldCloseFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldCollateralFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldComptrollerLens", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newComptrollerLens", + "type": "address" + } + ], + "name": "NewComptrollerLens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationIncentiveMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldLiquidatorContract", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newLiquidatorContract", + "type": "address" + } + ], + "name": "NewLiquidatorContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldPauseGuardian", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newPauseGuardian", + "type": "address" + } + ], + "name": "NewPauseGuardian", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSupplyCap", + "type": "uint256" + } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldTreasuryAddress", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newTreasuryAddress", + "type": "address" + } + ], + "name": "NewTreasuryAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldTreasuryGuardian", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newTreasuryGuardian", + "type": "address" + } + ], + "name": "NewTreasuryGuardian", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldTreasuryPercent", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newTreasuryPercent", + "type": "uint256" + } + ], + "name": "NewTreasuryPercent", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VAIControllerInterface", + "name": "oldVAIController", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract VAIControllerInterface", + "name": "newVAIController", + "type": "address" + } + ], + "name": "NewVAIController", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldVAIMintRate", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newVAIMintRate", + "type": "uint256" + } + ], + "name": "NewVAIMintRate", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "vault_", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "releaseStartBlock_", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "releaseInterval_", + "type": "uint256" + } + ], + "name": "NewVAIVaultInfo", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldVenusVAIVaultRate", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newVenusVAIVaultRate", + "type": "uint256" + } + ], + "name": "NewVenusVAIVaultRate", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSpeed", + "type": "uint256" + } + ], + "name": "VenusBorrowSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "recipient", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "VenusGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSpeed", + "type": "uint256" + } + ], + "name": "VenusSupplySpeedUpdated", + "type": "event" + }, + { + "payable": true, + "stateMutability": "payable", + "type": "fallback" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract Unitroller", + "name": "unitroller", + "type": "address" + } + ], + "name": "_become", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "recipient", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "_grantXVS", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "newAccessControlAddress", + "type": "address" + } + ], + "name": "_setAccessControl", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address[]", + "name": "markets_", + "type": "address[]" + }, + { + "internalType": "enum ComptrollerV9Storage.Action[]", + "name": "actions_", + "type": "uint8[]" + }, + { + "internalType": "bool", + "name": "paused_", + "type": "bool" + } + ], + "name": "_setActionsPaused", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "_setCloseFactor", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + } + ], + "name": "_setCollateralFactor", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract ComptrollerLensInterface", + "name": "comptrollerLens_", + "type": "address" + } + ], + "name": "_setComptrollerLens", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "_setForcedLiquidation", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "_setLiquidationIncentive", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "newLiquidatorContract_", + "type": "address" + } + ], + "name": "_setLiquidatorContract", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newBorrowCaps", + "type": "uint256[]" + } + ], + "name": "_setMarketBorrowCaps", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newSupplyCaps", + "type": "uint256[]" + } + ], + "name": "_setMarketSupplyCaps", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "newPauseGuardian", + "type": "address" + } + ], + "name": "_setPauseGuardian", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract PriceOracle", + "name": "newOracle", + "type": "address" + } + ], + "name": "_setPriceOracle", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "bool", + "name": "state", + "type": "bool" + } + ], + "name": "_setProtocolPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "newTreasuryGuardian", + "type": "address" + }, + { + "internalType": "address", + "name": "newTreasuryAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "newTreasuryPercent", + "type": "uint256" + } + ], + "name": "_setTreasuryData", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract VAIControllerInterface", + "name": "vaiController_", + "type": "address" + } + ], + "name": "_setVAIController", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "newVAIMintRate", + "type": "uint256" + } + ], + "name": "_setVAIMintRate", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vault_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "releaseStartBlock_", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "minReleaseAmount_", + "type": "uint256" + } + ], + "name": "_setVAIVaultInfo", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "supplySpeeds", + "type": "uint256[]" + }, + { + "internalType": "uint256[]", + "name": "borrowSpeeds", + "type": "uint256[]" + } + ], + "name": "_setVenusSpeeds", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "venusVAIVaultRate_", + "type": "uint256" + } + ], + "name": "_setVenusVAIVaultRate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "_supportMarket", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "accountAssets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerV9Storage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "actionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "allMarkets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "approvedDelegates", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "borrowAllowed", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "borrowCapGuardian", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "borrowCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "borrowVerify", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "checkMembership", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address[]", + "name": "holders", + "type": "address[]" + }, + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "bool", + "name": "borrowers", + "type": "bool" + }, + { + "internalType": "bool", + "name": "suppliers", + "type": "bool" + }, + { + "internalType": "bool", + "name": "collateral", + "type": "bool" + } + ], + "name": "claimVenus", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "holder", + "type": "address" + }, + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + } + ], + "name": "claimVenus", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "holder", + "type": "address" + } + ], + "name": "claimVenus", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address[]", + "name": "holders", + "type": "address[]" + }, + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "bool", + "name": "borrowers", + "type": "bool" + }, + { + "internalType": "bool", + "name": "suppliers", + "type": "bool" + } + ], + "name": "claimVenus", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "holder", + "type": "address" + } + ], + "name": "claimVenusAsCollateral", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "comptrollerImplementation", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "comptrollerLens", + "outputs": [ + { + "internalType": "contract ComptrollerLensInterface", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "facetAddress", + "type": "address" + }, + { + "internalType": "enum IDiamondCut.FacetCutAction", + "name": "action", + "type": "uint8" + }, + { + "internalType": "bytes4[]", + "name": "functionSelectors", + "type": "bytes4[]" + } + ], + "internalType": "struct IDiamondCut.FacetCut[]", + "name": "diamondCut_", + "type": "tuple[]" + } + ], + "name": "diamondCut", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address[]", + "name": "vTokens", + "type": "address[]" + } + ], + "name": "enterMarkets", + "outputs": [ + { + "internalType": "uint256[]", + "name": "", + "type": "uint256[]" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vTokenAddress", + "type": "address" + } + ], + "name": "exitMarket", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "bytes4", + "name": "functionSelector", + "type": "bytes4" + } + ], + "name": "facetAddress", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "facetAddress", + "type": "address" + }, + { + "internalType": "uint96", + "name": "functionSelectorPosition", + "type": "uint96" + } + ], + "internalType": "struct ComptrollerV13Storage.FacetAddressAndPosition", + "name": "", + "type": "tuple" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "facetAddresses", + "outputs": [ + { + "internalType": "address[]", + "name": "", + "type": "address[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "facet", + "type": "address" + } + ], + "name": "facetFunctionSelectors", + "outputs": [ + { + "internalType": "bytes4[]", + "name": "", + "type": "bytes4[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "facet", + "type": "address" + } + ], + "name": "facetPosition", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "facets", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "facetAddress", + "type": "address" + }, + { + "internalType": "bytes4[]", + "name": "functionSelectors", + "type": "bytes4[]" + } + ], + "internalType": "struct Diamond.Facet[]", + "name": "", + "type": "tuple[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getAllMarkets", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAssetsIn", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenModify", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getXVSAddress", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "pure", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getXVSVTokenAddress", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "pure", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isComptroller", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "pure", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "isForcedLiquidationEnabled", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "name": "liquidateBorrowAllowed", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "seizeTokens", + "type": "uint256" + } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + } + ], + "name": "liquidateVAICalculateSeizeTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "liquidatorContract", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "markets", + "outputs": [ + { + "internalType": "bool", + "name": "isListed", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "collateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "isVenus", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "maxAssets", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "minReleaseAmount", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "mintAllowed", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "mintVAIGuardianPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualMintAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "mintTokens", + "type": "uint256" + } + ], + "name": "mintVerify", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "mintedVAIs", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "oracle", + "outputs": [ + { + "internalType": "contract PriceOracle", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pauseGuardian", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingComptrollerImplementation", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "protocolPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "redeemAllowed", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "redeemVerify", + "outputs": [], + "payable": false, + "stateMutability": "pure", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "releaseStartBlock", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "payer", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "name": "repayBorrowAllowed", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "payer", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowerIndex", + "type": "uint256" + } + ], + "name": "repayBorrowVerify", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "repayVAIGuardianPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "seizeTokens", + "type": "uint256" + } + ], + "name": "seizeAllowed", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "seizeTokens", + "type": "uint256" + } + ], + "name": "seizeVerify", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "setMintedVAIOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "supplyCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "transferTokens", + "type": "uint256" + } + ], + "name": "transferAllowed", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "transferTokens", + "type": "uint256" + } + ], + "name": "transferVerify", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "treasuryAddress", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "treasuryGuardian", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "treasuryPercent", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "delegate", + "type": "address" + }, + { + "internalType": "bool", + "name": "allowBorrows", + "type": "bool" + } + ], + "name": "updateDelegate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "vaiController", + "outputs": [ + { + "internalType": "contract VAIControllerInterface", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "vaiMintRate", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "vaiVaultAddress", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "venusAccrued", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "venusBorrowSpeeds", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "venusBorrowState", + "outputs": [ + { + "internalType": "uint224", + "name": "index", + "type": "uint224" + }, + { + "internalType": "uint32", + "name": "block", + "type": "uint32" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "venusBorrowerIndex", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "venusInitialIndex", + "outputs": [ + { + "internalType": "uint224", + "name": "", + "type": "uint224" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "venusSupplierIndex", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "venusSupplySpeeds", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "venusSupplyState", + "outputs": [ + { + "internalType": "uint224", + "name": "index", + "type": "uint224" + }, + { + "internalType": "uint32", + "name": "block", + "type": "uint32" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "venusVAIVaultRate", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-384/abi/resilientOracle.json b/simulations/vip-384/abi/resilientOracle.json new file mode 100644 index 000000000..a6a0da2ba --- /dev/null +++ b/simulations/vip-384/abi/resilientOracle.json @@ -0,0 +1,608 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "vBnbAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "mainOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "pivotOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "fallbackOracle", + "type": "address" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManager", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [ + { + "internalType": "contract BoundValidatorInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "getOracle", + "outputs": [ + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "bool", + "name": "enabled", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract BoundValidatorInterface", + "name": "_boundValidator", + "type": "address" + }, + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-384/abi/singleTokenConverter.json b/simulations/vip-384/abi/singleTokenConverter.json new file mode 100644 index 000000000..1c8e0f8ec --- /dev/null +++ b/simulations/vip-384/abi/singleTokenConverter.json @@ -0,0 +1,1267 @@ +[ + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { + "inputs": [], + "name": "AmountInMismatched", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { + "inputs": [], + "name": "AmountOutMismatched", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionConfigNotEnabled", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionEnabledOnlyForPrivateConversions", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionTokensActive", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionTokensPaused", + "type": "error" + }, + { + "inputs": [], + "name": "DeflationaryTokenNotSupported", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxIncentive", + "type": "uint256" + } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { + "inputs": [], + "name": "InputLengthMisMatch", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientInputAmount", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientOutputAmount", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientPoolLiquidity", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidConverterNetwork", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidMinimumAmountToConvert", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidToAddress", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidTokenConfigAddresses", + "type": "error" + }, + { + "inputs": [], + "name": "NonZeroIncentiveForPrivateConversion", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroValueNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldIncentive", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newIncentive", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + } + ], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + } + ], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldConverterNetwork", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "converterNetwork", + "type": "address" + } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldDestinationAddress", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "destinationAddress", + "type": "address" + } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMinAmountToConvert", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMinAmountToConvert", + "type": "uint256" + } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract ResilientOracle", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract ResilientOracle", + "name": "priceOracle", + "type": "address" + } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "token", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "token", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "tokenBalance", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "conversionConfigurations", + "outputs": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertExactTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertForExactTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [ + { + "internalType": "contract IConverterNetwork", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getAmountIn", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getAmountOut", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pauseConversion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [ + { + "internalType": "contract ResilientOracle", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "resumeConversion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address[]", + "name": "tokenAddressesOut", + "type": "address[]" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract IConverterNetwork", + "name": "converterNetwork_", + "type": "address" + } + ], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "destinationAddress_", + "type": "address" + } + ], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "minAmountToConvert_", + "type": "uint256" + } + ], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract ResilientOracle", + "name": "priceOracle_", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-384/bsctestnet.ts b/simulations/vip-384/bsctestnet.ts new file mode 100644 index 000000000..3b2a0c3ac --- /dev/null +++ b/simulations/vip-384/bsctestnet.ts @@ -0,0 +1,153 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; +import { forking, testVip } from "src/vip-framework"; +import { checkVToken } from "src/vip-framework/checks/checkVToken"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; + +import { + ACCESS_CONTROL_MANAGER, + AMOUNT_TO_REFUND, + COMMUNITY_WALLET, + COMPTROLLER, + EXPECTED_CONVERSION_INCENTIVE, + INITIAL_VTOKENS, + PROTOCOL_SHARE_RESERVE, + TWT, + USDT, + VTWT, + converterBaseAssets, + vip384, +} from "../../vips/vip-384/bsctestnet"; +import ERC20_ABI from "./abi/ERC20.json"; +import VBEP20_ABI from "./abi/VBep20_ABI.json"; +import COMPTROLLER_ABI from "./abi/comptroller.json"; +import PRICE_ORACLE_ABI from "./abi/resilientOracle.json"; +import SINGLE_TOKEN_CONVERTER_ABI from "./abi/singleTokenConverter.json"; + +const BORROW_CAP = parseUnits("1000000", 18); +const SUPPLY_CAP = parseUnits("3000000", 18); +const COLLATERAL_FACTOR = parseUnits("0.5", 18); +const RESERVES_BLOCK_DELTA = 100; +const RESERVE_FACTOR = parseUnits("0.25", 18); +const RATE_MODEL = "0x8542d63414754e2D81566C129E79325C67A3a0a3"; + +const { bsctestnet } = NETWORK_ADDRESSES; + +forking(44781175, async () => { + let comptroller: Contract; + let vtwt: Contract; + let oracle: Contract; + let usdt: Contract; + let communityBalanceBefore: any; + const provider = ethers.provider; + + before(async () => { + comptroller = new ethers.Contract(COMPTROLLER, COMPTROLLER_ABI, provider); + vtwt = new ethers.Contract(VTWT, VBEP20_ABI, provider); + oracle = new ethers.Contract(await comptroller.oracle(), PRICE_ORACLE_ABI, provider); + usdt = new ethers.Contract(USDT, ERC20_ABI, provider); + communityBalanceBefore = await usdt.balanceOf(COMMUNITY_WALLET); + }); + describe("Pre-VIP behaviour", async () => { + it("should have 25 markets in the core pool", async () => { + const markets = await comptroller.getAllMarkets(); + expect(markets).to.have.lengthOf(25); + }); + }); + + testVip("VIP-384-testnet Add TWT Market", await vip384(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [COMPTROLLER_ABI, VBEP20_ABI], + [ + "MarketListed", + "NewSupplyCap", + "NewBorrowCap", + "NewReserveFactor", + "NewProtocolShareReserve", + "NewReduceReservesBlockDelta", + "NewCollateralFactor", + "Mint", + "Failure", + ], + [1, 1, 1, 1, 1, 1, 1, 1, 0], + ); + }, + }); + + describe("Post-VIP behavior", async () => { + it("should have 26 markets in the core pool", async () => { + const markets = await comptroller.getAllMarkets(); + expect(markets).to.have.lengthOf(26); + }); + it("has correct owner", async () => { + expect(await vtwt.admin()).to.equal(bsctestnet.NORMAL_TIMELOCK); + }); + + it("has correct ACM", async () => { + expect(await vtwt.accessControlManager()).to.equal(ACCESS_CONTROL_MANAGER); + }); + it("adds a new TWT market and set collateral factor to 50%", async () => { + const market = await comptroller.markets(VTWT); + expect(market.isListed).to.equal(true); + expect(market.collateralFactorMantissa).to.equal(COLLATERAL_FACTOR); + }); + it("reserves factor equals 25%", async () => { + const reserveFactor = await vtwt.reserveFactorMantissa(); + expect(reserveFactor).to.equal(RESERVE_FACTOR); + }); + it("sets protocol share reserve", async () => { + expect(await vtwt.protocolShareReserve()).to.equal(PROTOCOL_SHARE_RESERVE); + }); + it("sets Reduce Reserves Block Delta to 100", async () => { + expect(await vtwt.reduceReservesBlockDelta()).to.equal(RESERVES_BLOCK_DELTA); + }); + it("sets the supply cap to 3,000,000 TWT", async () => { + const newCap = await comptroller.supplyCaps(VTWT); + expect(newCap).to.equal(SUPPLY_CAP); + }); + it("sets the borrow cap to 1,000,000 TWT", async () => { + const newCap = await comptroller.borrowCaps(VTWT); + expect(newCap).to.equal(BORROW_CAP); + }); + it("does not leave vTWT balance on the address of the timelock", async () => { + const timelockBalance = await vtwt.balanceOf(bsctestnet.NORMAL_TIMELOCK); + expect(timelockBalance).to.equal(0); + }); + it("moves INITIAL_VTOKENS vTWT to VENUS_TREASURY", async () => { + const vTokenReceiverBalance = await vtwt.balanceOf(bsctestnet.VTREASURY); + expect(vTokenReceiverBalance).to.equal(INITIAL_VTOKENS); + }); + it("get correct price from oracle ", async () => { + const price = await oracle.getUnderlyingPrice(VTWT); + expect(price).to.equal(parseUnits("0.8512", 18)); + }); + it("Community wallet balance should be increased by 5,000 USDT", async () => { + expect(await usdt.balanceOf(COMMUNITY_WALLET)).to.equal(communityBalanceBefore.add(AMOUNT_TO_REFUND)); + }); + await checkInterestRate(RATE_MODEL, "TWT", { base: "0", kink: "0.5", multiplier: "0.2", jump: "3" }); + await checkVToken(VTWT, { + name: "Venus TWT", + symbol: "vTWT", + decimals: 8, + underlying: TWT, + exchangeRate: parseUnits("1", 28), + comptroller: COMPTROLLER, + }); + describe("Converters", () => { + for (const [converterAddress, baseAsset] of Object.entries(converterBaseAssets)) { + const converterContract = new ethers.Contract(converterAddress, SINGLE_TOKEN_CONVERTER_ABI, ethers.provider); + const asset = TWT; + it(`should set ${EXPECTED_CONVERSION_INCENTIVE} as incentive in converter ${converterAddress}, for asset ${asset}`, async () => { + const result = await converterContract.conversionConfigurations(baseAsset, asset); + expect(result.incentive).to.equal(EXPECTED_CONVERSION_INCENTIVE); + }); + } + }); + }); +}); diff --git a/vips/vip-384/bsctestnet.ts b/vips/vip-384/bsctestnet.ts new file mode 100644 index 000000000..4f0f2d789 --- /dev/null +++ b/vips/vip-384/bsctestnet.ts @@ -0,0 +1,156 @@ +import { BigNumberish } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const COMPTROLLER = "0x94d1820b2D1c7c7452A163983Dc888CEC546b77D"; +export const TWT = "0xb99C6B26Fdf3678c6e2aff8466E3625a0e7182f8"; +export const VTWT = "0x53BAA8aAeb673D72A8C516CDA45a6d07b39850B4"; +export const PROTOCOL_SHARE_RESERVE = "0x25c7c7D6Bf710949fD7f03364E9BA19a1b3c10E3"; +export const ACCESS_CONTROL_MANAGER = "0x45f8a08F534f34A97187626E05d4b6648Eeaa9AA"; +export const COMMUNITY_WALLET = "0xc444949e0054A23c44Fc45789738bdF64aed2391"; +export const USDT = "0xA11c8D9DC9b66E209Ef60F0C8D969D3CD988782c"; +const USDC = "0x16227D60f7a0e586C66B005219dfc887D13C9531"; +const BTCB = "0xA808e341e8e723DC6BA0Bb5204Bafc2330d7B8e4"; +const XVS = "0xB9e0E753630434d7863528cc73CB7AC638a7c8ff"; +const ETH = "0x98f7A83361F7Ac8765CcEBAB1425da6b341958a7"; +const RISK_FUND_CONVERTER = "0x32Fbf7bBbd79355B86741E3181ef8c1D9bD309Bb"; +const USDT_PRIME_CONVERTER = "0xf1FA230D25fC5D6CAfe87C5A6F9e1B17Bc6F194E"; +const USDC_PRIME_CONVERTER = "0x2ecEdE6989d8646c992344fF6C97c72a3f811A13"; +const BTCB_PRIME_CONVERTER = "0x989A1993C023a45DA141928921C0dE8fD123b7d1"; +const ETH_PRIME_CONVERTER = "0xf358650A007aa12ecC8dac08CF8929Be7f72A4D9"; +const XVS_VAULT_CONVERTER = "0x258f49254C758a0E37DAb148ADDAEA851F4b02a2"; + +export const EXPECTED_CONVERSION_INCENTIVE = 1e14; +export const converterBaseAssets = { + [RISK_FUND_CONVERTER]: USDT, + [USDT_PRIME_CONVERTER]: USDT, + [USDC_PRIME_CONVERTER]: USDC, + [BTCB_PRIME_CONVERTER]: BTCB, + [ETH_PRIME_CONVERTER]: ETH, + [XVS_VAULT_CONVERTER]: XVS, +}; +export const AMOUNT_TO_REFUND = parseUnits("5000", 18); +export const INITIAL_FUNDING = parseUnits("100", 18); +export const INITIAL_VTOKENS = parseUnits("100", 8); + +const configureConverters = (fromAssets: string[], incentive: BigNumberish = EXPECTED_CONVERSION_INCENTIVE) => { + enum ConversionAccessibility { + NONE = 0, + ALL = 1, + ONLY_FOR_CONVERTERS = 2, + ONLY_FOR_USERS = 3, + } + + return Object.entries(converterBaseAssets).map(([converter, baseAsset]: [string, string]) => { + const conversionConfigs = fromAssets.map(() => [incentive, ConversionAccessibility.ALL]); + return { + target: converter, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [baseAsset, fromAssets, conversionConfigs], + }; + }); +}; +const { bsctestnet } = NETWORK_ADDRESSES; + +export const vip384 = () => { + const meta = { + version: "v2", + title: "VIP-384 Add TWT Market to core pool on BNB", + description: ``, + forDescription: "I agree that Venus Protocol should proceed with the Add TWT Market", + againstDescription: "I do not think that Venus Protocol should proceed with the Add TWT Market", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds with the Add TWT Market or not", + }; + + return makeProposal( + [ + { + target: COMPTROLLER, + signature: "_supportMarket(address)", + params: [VTWT], + }, + + { + target: COMPTROLLER, + signature: "_setMarketSupplyCaps(address[],uint256[])", + params: [[VTWT], [parseUnits("3000000", 18)]], + }, + + { + target: COMPTROLLER, + signature: "_setMarketBorrowCaps(address[],uint256[])", + params: [[VTWT], [parseUnits("1000000", 18)]], + }, + { + target: COMPTROLLER, + signature: "_setCollateralFactor(address,uint256)", + params: [VTWT, parseUnits("0.5", 18)], + }, + { + target: VTWT, + signature: "setAccessControlManager(address)", + params: [ACCESS_CONTROL_MANAGER], + }, + { + target: VTWT, + signature: "setProtocolShareReserve(address)", + params: [PROTOCOL_SHARE_RESERVE], + }, + { + target: VTWT, + signature: "setReduceReservesBlockDelta(uint256)", + params: [100], + }, + { + target: VTWT, + signature: "_setReserveFactor(uint256)", + params: ["250000000000000000"], + }, + { + target: TWT, + signature: "faucet(uint256)", + params: [INITIAL_FUNDING], + }, + + { + target: TWT, + signature: "approve(address,uint256)", + params: [VTWT, 0], + }, + + { + target: TWT, + signature: "approve(address,uint256)", + params: [VTWT, INITIAL_FUNDING], + }, + { + target: VTWT, + signature: "mint(uint256)", + params: [INITIAL_FUNDING], + }, + + { + target: VTWT, + signature: "transfer(address,uint256)", + params: [bsctestnet.VTREASURY, INITIAL_VTOKENS], + }, + + { + target: USDT, + signature: "allocateTo(address,uint256)", + params: [bsctestnet.VTREASURY, AMOUNT_TO_REFUND], + }, + + { + target: bsctestnet.VTREASURY, + signature: "withdrawTreasuryBEP20(address,uint256,address)", + params: [USDT, AMOUNT_TO_REFUND, COMMUNITY_WALLET], + }, + ...configureConverters([TWT]), + ], + meta, + ProposalType.REGULAR, + ); +}; From 60fdac67c93f408ba3516c604446fdb89486450e Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Wed, 16 Oct 2024 17:01:44 +0530 Subject: [PATCH 036/178] fix: address and base rate --- simulations/vip-384/bsctestnet.ts | 6 +++--- vips/vip-384/bsctestnet.ts | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/simulations/vip-384/bsctestnet.ts b/simulations/vip-384/bsctestnet.ts index 3b2a0c3ac..e37041313 100644 --- a/simulations/vip-384/bsctestnet.ts +++ b/simulations/vip-384/bsctestnet.ts @@ -33,11 +33,11 @@ const SUPPLY_CAP = parseUnits("3000000", 18); const COLLATERAL_FACTOR = parseUnits("0.5", 18); const RESERVES_BLOCK_DELTA = 100; const RESERVE_FACTOR = parseUnits("0.25", 18); -const RATE_MODEL = "0x8542d63414754e2D81566C129E79325C67A3a0a3"; +const RATE_MODEL = "0xF1A8B40CA68d08EFfa31a16a83f4fd9b5c174872"; const { bsctestnet } = NETWORK_ADDRESSES; -forking(44781175, async () => { +forking(44785576, async () => { let comptroller: Contract; let vtwt: Contract; let oracle: Contract; @@ -130,7 +130,7 @@ forking(44781175, async () => { it("Community wallet balance should be increased by 5,000 USDT", async () => { expect(await usdt.balanceOf(COMMUNITY_WALLET)).to.equal(communityBalanceBefore.add(AMOUNT_TO_REFUND)); }); - await checkInterestRate(RATE_MODEL, "TWT", { base: "0", kink: "0.5", multiplier: "0.2", jump: "3" }); + await checkInterestRate(RATE_MODEL, "TWT", { base: "0.02", kink: "0.5", multiplier: "0.2", jump: "3" }); await checkVToken(VTWT, { name: "Venus TWT", symbol: "vTWT", diff --git a/vips/vip-384/bsctestnet.ts b/vips/vip-384/bsctestnet.ts index 4f0f2d789..9ec0b18a5 100644 --- a/vips/vip-384/bsctestnet.ts +++ b/vips/vip-384/bsctestnet.ts @@ -6,7 +6,7 @@ import { makeProposal } from "src/utils"; export const COMPTROLLER = "0x94d1820b2D1c7c7452A163983Dc888CEC546b77D"; export const TWT = "0xb99C6B26Fdf3678c6e2aff8466E3625a0e7182f8"; -export const VTWT = "0x53BAA8aAeb673D72A8C516CDA45a6d07b39850B4"; +export const VTWT = "0x95DaED37fdD3F557b3A5cCEb7D50Be65b36721DF"; export const PROTOCOL_SHARE_RESERVE = "0x25c7c7D6Bf710949fD7f03364E9BA19a1b3c10E3"; export const ACCESS_CONTROL_MANAGER = "0x45f8a08F534f34A97187626E05d4b6648Eeaa9AA"; export const COMMUNITY_WALLET = "0xc444949e0054A23c44Fc45789738bdF64aed2391"; From 080cad73638b05098fd2fbb3406005a515796dd0 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Wed, 16 Oct 2024 17:03:56 +0530 Subject: [PATCH 037/178] refactor: update initial supply --- vips/vip-384/bsctestnet.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vips/vip-384/bsctestnet.ts b/vips/vip-384/bsctestnet.ts index 9ec0b18a5..369e773b4 100644 --- a/vips/vip-384/bsctestnet.ts +++ b/vips/vip-384/bsctestnet.ts @@ -32,8 +32,8 @@ export const converterBaseAssets = { [XVS_VAULT_CONVERTER]: XVS, }; export const AMOUNT_TO_REFUND = parseUnits("5000", 18); -export const INITIAL_FUNDING = parseUnits("100", 18); -export const INITIAL_VTOKENS = parseUnits("100", 8); +export const INITIAL_FUNDING = parseUnits("5000", 18); +export const INITIAL_VTOKENS = parseUnits("5000", 8); const configureConverters = (fromAssets: string[], incentive: BigNumberish = EXPECTED_CONVERSION_INCENTIVE) => { enum ConversionAccessibility { From cc451dcbe772ae6c07e4372a897dd3950fd29430 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Wed, 16 Oct 2024 18:02:54 +0530 Subject: [PATCH 038/178] fix: USDT decimal --- vips/vip-384/bsctestnet.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vips/vip-384/bsctestnet.ts b/vips/vip-384/bsctestnet.ts index 369e773b4..b6b91fff3 100644 --- a/vips/vip-384/bsctestnet.ts +++ b/vips/vip-384/bsctestnet.ts @@ -31,7 +31,7 @@ export const converterBaseAssets = { [ETH_PRIME_CONVERTER]: ETH, [XVS_VAULT_CONVERTER]: XVS, }; -export const AMOUNT_TO_REFUND = parseUnits("5000", 18); +export const AMOUNT_TO_REFUND = parseUnits("5000", 6); export const INITIAL_FUNDING = parseUnits("5000", 18); export const INITIAL_VTOKENS = parseUnits("5000", 8); From 03068ac98df13f41a5c2c2daac9dfa013ea9f257 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Wed, 16 Oct 2024 19:38:20 +0530 Subject: [PATCH 039/178] feat: add mainnet vip for TWT market --- simulations/vip-384/bscmainnet.ts | 154 ++++++++++++++++++++++++++++++ simulations/vip-384/bsctestnet.ts | 4 +- vips/vip-384/bscmainnet.ts | 148 ++++++++++++++++++++++++++++ vips/vip-384/bsctestnet.ts | 2 +- 4 files changed, 305 insertions(+), 3 deletions(-) create mode 100644 simulations/vip-384/bscmainnet.ts create mode 100644 vips/vip-384/bscmainnet.ts diff --git a/simulations/vip-384/bscmainnet.ts b/simulations/vip-384/bscmainnet.ts new file mode 100644 index 000000000..116c70221 --- /dev/null +++ b/simulations/vip-384/bscmainnet.ts @@ -0,0 +1,154 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents, setMaxStalePeriodInBinanceOracle } from "src/utils"; +import { forking, testVip } from "src/vip-framework"; +import { checkVToken } from "src/vip-framework/checks/checkVToken"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; + +import { + ACCESS_CONTROL_MANAGER, + AMOUNT_TO_REFUND, + COMMUNITY_WALLET, + COMPTROLLER, + EXPECTED_CONVERSION_INCENTIVE, + INITIAL_VTOKENS, + PROTOCOL_SHARE_RESERVE, + TWT, + USDT, + VTWT, + converterBaseAssets, + vip384, +} from "../../vips/vip-384/bscmainnet"; +import ERC20_ABI from "./abi/ERC20.json"; +import VBEP20_ABI from "./abi/VBep20_ABI.json"; +import COMPTROLLER_ABI from "./abi/comptroller.json"; +import PRICE_ORACLE_ABI from "./abi/resilientOracle.json"; +import SINGLE_TOKEN_CONVERTER_ABI from "./abi/singleTokenConverter.json"; + +const BORROW_CAP = parseUnits("1000000", 18); +const SUPPLY_CAP = parseUnits("2000000", 18); +const COLLATERAL_FACTOR = parseUnits("0.5", 18); +const RESERVES_BLOCK_DELTA = 28800; +const RESERVE_FACTOR = parseUnits("0.25", 18); +const RATE_MODEL = "0x2dE4739a9C68B02B54C0d8323752551d724b3cc2"; + +const { bscmainnet } = NETWORK_ADDRESSES; + +forking(43168547, async () => { + let comptroller: Contract; + let vtwt: Contract; + let oracle: Contract; + let usdt: Contract; + let communityBalanceBefore: any; + const provider = ethers.provider; + + before(async () => { + comptroller = new ethers.Contract(COMPTROLLER, COMPTROLLER_ABI, provider); + vtwt = new ethers.Contract(VTWT, VBEP20_ABI, provider); + oracle = new ethers.Contract(await comptroller.oracle(), PRICE_ORACLE_ABI, provider); + usdt = new ethers.Contract(USDT, ERC20_ABI, provider); + communityBalanceBefore = await usdt.balanceOf(COMMUNITY_WALLET); + await setMaxStalePeriodInBinanceOracle("0x594810b741d136f1960141C0d8Fb4a91bE78A820", "TWT"); + }); + describe("Pre-VIP behaviour", async () => { + it("should have 31 markets in the core pool", async () => { + const markets = await comptroller.getAllMarkets(); + expect(markets).to.have.lengthOf(31); + }); + }); + + testVip("VIP-384 Add TWT Market", await vip384(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [COMPTROLLER_ABI, VBEP20_ABI], + [ + "MarketListed", + "NewSupplyCap", + "NewBorrowCap", + "NewReserveFactor", + "NewProtocolShareReserve", + "NewReduceReservesBlockDelta", + "NewCollateralFactor", + "Mint", + "Failure", + ], + [1, 1, 1, 1, 1, 1, 1, 1, 0], + ); + }, + }); + + describe("Post-VIP behavior", async () => { + it("should have 32 markets in the core pool", async () => { + const markets = await comptroller.getAllMarkets(); + expect(markets).to.have.lengthOf(32); + }); + it("has correct owner", async () => { + expect(await vtwt.admin()).to.equal(bscmainnet.NORMAL_TIMELOCK); + }); + + it("has correct ACM", async () => { + expect(await vtwt.accessControlManager()).to.equal(ACCESS_CONTROL_MANAGER); + }); + it("adds a new TWT market and set collateral factor to 50%", async () => { + const market = await comptroller.markets(VTWT); + expect(market.isListed).to.equal(true); + expect(market.collateralFactorMantissa).to.equal(COLLATERAL_FACTOR); + }); + it("reserves factor equals 25%", async () => { + const reserveFactor = await vtwt.reserveFactorMantissa(); + expect(reserveFactor).to.equal(RESERVE_FACTOR); + }); + it("sets protocol share reserve", async () => { + expect(await vtwt.protocolShareReserve()).to.equal(PROTOCOL_SHARE_RESERVE); + }); + it("sets Reduce Reserves Block Delta to 28800", async () => { + expect(await vtwt.reduceReservesBlockDelta()).to.equal(RESERVES_BLOCK_DELTA); + }); + it("sets the supply cap to 2,000,000 TWT", async () => { + const newCap = await comptroller.supplyCaps(VTWT); + expect(newCap).to.equal(SUPPLY_CAP); + }); + it("sets the borrow cap to 1,000,000 TWT", async () => { + const newCap = await comptroller.borrowCaps(VTWT); + expect(newCap).to.equal(BORROW_CAP); + }); + it("does not leave vTWT balance on the address of the timelock", async () => { + const timelockBalance = await vtwt.balanceOf(bscmainnet.NORMAL_TIMELOCK); + expect(timelockBalance).to.equal(0); + }); + it("moves INITIAL_VTOKENS vTWT to VENUS_TREASURY", async () => { + const vTokenReceiverBalance = await vtwt.balanceOf(bscmainnet.VTREASURY); + expect(vTokenReceiverBalance).to.equal(INITIAL_VTOKENS); + }); + it("get correct price from oracle ", async () => { + const price = await oracle.getUnderlyingPrice(VTWT); + expect(price).to.equal(parseUnits("1.11355466", 18)); + }); + it("Community wallet balance should be increased by 5,000 USDT", async () => { + expect(await usdt.balanceOf(COMMUNITY_WALLET)).to.equal(communityBalanceBefore.add(AMOUNT_TO_REFUND)); + }); + await checkInterestRate(RATE_MODEL, "TWT", { base: "0.02", kink: "0.5", multiplier: "0.2", jump: "3" }); + await checkVToken(VTWT, { + name: "Venus TWT", + symbol: "vTWT", + decimals: 8, + underlying: TWT, + exchangeRate: parseUnits("1", 28), + comptroller: COMPTROLLER, + }); + describe("Converters", () => { + for (const [converterAddress, baseAsset] of Object.entries(converterBaseAssets)) { + const converterContract = new ethers.Contract(converterAddress, SINGLE_TOKEN_CONVERTER_ABI, ethers.provider); + const asset = TWT; + it(`should set ${EXPECTED_CONVERSION_INCENTIVE} as incentive in converter ${converterAddress}, for asset ${asset}`, async () => { + const result = await converterContract.conversionConfigurations(baseAsset, asset); + expect(result.incentive).to.equal(EXPECTED_CONVERSION_INCENTIVE); + }); + } + }); + }); +}); diff --git a/simulations/vip-384/bsctestnet.ts b/simulations/vip-384/bsctestnet.ts index e37041313..adf84b128 100644 --- a/simulations/vip-384/bsctestnet.ts +++ b/simulations/vip-384/bsctestnet.ts @@ -29,7 +29,7 @@ import PRICE_ORACLE_ABI from "./abi/resilientOracle.json"; import SINGLE_TOKEN_CONVERTER_ABI from "./abi/singleTokenConverter.json"; const BORROW_CAP = parseUnits("1000000", 18); -const SUPPLY_CAP = parseUnits("3000000", 18); +const SUPPLY_CAP = parseUnits("2000000", 18); const COLLATERAL_FACTOR = parseUnits("0.5", 18); const RESERVES_BLOCK_DELTA = 100; const RESERVE_FACTOR = parseUnits("0.25", 18); @@ -107,7 +107,7 @@ forking(44785576, async () => { it("sets Reduce Reserves Block Delta to 100", async () => { expect(await vtwt.reduceReservesBlockDelta()).to.equal(RESERVES_BLOCK_DELTA); }); - it("sets the supply cap to 3,000,000 TWT", async () => { + it("sets the supply cap to 2,000,000 TWT", async () => { const newCap = await comptroller.supplyCaps(VTWT); expect(newCap).to.equal(SUPPLY_CAP); }); diff --git a/vips/vip-384/bscmainnet.ts b/vips/vip-384/bscmainnet.ts new file mode 100644 index 000000000..270e56226 --- /dev/null +++ b/vips/vip-384/bscmainnet.ts @@ -0,0 +1,148 @@ +import { BigNumberish } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const COMPTROLLER = "0xfD36E2c2a6789Db23113685031d7F16329158384"; +export const TWT = "0x4B0F1812e5Df2A09796481Ff14017e6005508003"; +export const VTWT = "0x4d41a36D04D97785bcEA57b057C412b278e6Edcc"; +export const PROTOCOL_SHARE_RESERVE = "0xCa01D5A9A248a830E9D93231e791B1afFed7c446"; +export const ACCESS_CONTROL_MANAGER = "0x4788629ABc6cFCA10F9f969efdEAa1cF70c23555"; +export const COMMUNITY_WALLET = "0xc444949e0054A23c44Fc45789738bdF64aed2391"; +export const USDT = "0x55d398326f99059fF775485246999027B3197955"; +const USDC = "0x8AC76a51cc950d9822D68b83fE1Ad97B32Cd580d"; +const BTCB = "0x7130d2A12B9BCbFAe4f2634d864A1Ee1Ce3Ead9c"; +const XVS = "0xcF6BB5389c92Bdda8a3747Ddb454cB7a64626C63"; +const ETH = "0x2170Ed0880ac9A755fd29B2688956BD959F933F8"; +const RISK_FUND_CONVERTER = "0xA5622D276CcbB8d9BBE3D1ffd1BB11a0032E53F0"; +const USDT_PRIME_CONVERTER = "0xD9f101AA67F3D72662609a2703387242452078C3"; +const USDC_PRIME_CONVERTER = "0xa758c9C215B6c4198F0a0e3FA46395Fa15Db691b"; +const BTCB_PRIME_CONVERTER = "0xE8CeAa79f082768f99266dFd208d665d2Dd18f53"; +const ETH_PRIME_CONVERTER = "0xca430B8A97Ea918fF634162acb0b731445B8195E"; +const XVS_VAULT_CONVERTER = "0xd5b9AE835F4C59272032B3B954417179573331E0"; + +export const EXPECTED_CONVERSION_INCENTIVE = 1e14; +export const converterBaseAssets = { + [RISK_FUND_CONVERTER]: USDT, + [USDT_PRIME_CONVERTER]: USDT, + [USDC_PRIME_CONVERTER]: USDC, + [BTCB_PRIME_CONVERTER]: BTCB, + [ETH_PRIME_CONVERTER]: ETH, + [XVS_VAULT_CONVERTER]: XVS, +}; +export const AMOUNT_TO_REFUND = parseUnits("5000", 18); +export const INITIAL_FUNDING = parseUnits("4401.074", 18); +export const INITIAL_VTOKENS = parseUnits("4401.074", 8); + +const configureConverters = (fromAssets: string[], incentive: BigNumberish = EXPECTED_CONVERSION_INCENTIVE) => { + enum ConversionAccessibility { + NONE = 0, + ALL = 1, + ONLY_FOR_CONVERTERS = 2, + ONLY_FOR_USERS = 3, + } + + return Object.entries(converterBaseAssets).map(([converter, baseAsset]: [string, string]) => { + const conversionConfigs = fromAssets.map(() => [incentive, ConversionAccessibility.ALL]); + return { + target: converter, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [baseAsset, fromAssets, conversionConfigs], + }; + }); +}; +const { bscmainnet } = NETWORK_ADDRESSES; + +export const vip384 = () => { + const meta = { + version: "v2", + title: "VIP-384 Add TWT Market to core pool on BNB", + description: ``, + forDescription: "I agree that Venus Protocol should proceed with the Add TWT Market", + againstDescription: "I do not think that Venus Protocol should proceed with the Add TWT Market", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds with the Add TWT Market or not", + }; + + return makeProposal( + [ + { + target: COMPTROLLER, + signature: "_supportMarket(address)", + params: [VTWT], + }, + + { + target: COMPTROLLER, + signature: "_setMarketSupplyCaps(address[],uint256[])", + params: [[VTWT], [parseUnits("2000000", 18)]], + }, + + { + target: COMPTROLLER, + signature: "_setMarketBorrowCaps(address[],uint256[])", + params: [[VTWT], [parseUnits("1000000", 18)]], + }, + { + target: COMPTROLLER, + signature: "_setCollateralFactor(address,uint256)", + params: [VTWT, parseUnits("0.5", 18)], + }, + { + target: VTWT, + signature: "setAccessControlManager(address)", + params: [ACCESS_CONTROL_MANAGER], + }, + { + target: VTWT, + signature: "setProtocolShareReserve(address)", + params: [PROTOCOL_SHARE_RESERVE], + }, + { + target: VTWT, + signature: "setReduceReservesBlockDelta(uint256)", + params: [28800], + }, + { + target: VTWT, + signature: "_setReserveFactor(uint256)", + params: ["250000000000000000"], + }, + { + target: bscmainnet.VTREASURY, + signature: "withdrawTreasuryBEP20(address,uint256,address)", + params: [TWT, INITIAL_FUNDING, bscmainnet.NORMAL_TIMELOCK], + }, + { + target: TWT, + signature: "approve(address,uint256)", + params: [VTWT, 0], + }, + + { + target: TWT, + signature: "approve(address,uint256)", + params: [VTWT, INITIAL_FUNDING], + }, + { + target: VTWT, + signature: "mint(uint256)", + params: [INITIAL_FUNDING], + }, + + { + target: VTWT, + signature: "transfer(address,uint256)", + params: [bscmainnet.VTREASURY, INITIAL_VTOKENS], + }, + { + target: bscmainnet.VTREASURY, + signature: "withdrawTreasuryBEP20(address,uint256,address)", + params: [USDT, AMOUNT_TO_REFUND, COMMUNITY_WALLET], + }, + ...configureConverters([TWT]), + ], + meta, + ProposalType.REGULAR, + ); +}; diff --git a/vips/vip-384/bsctestnet.ts b/vips/vip-384/bsctestnet.ts index b6b91fff3..43a49c8fe 100644 --- a/vips/vip-384/bsctestnet.ts +++ b/vips/vip-384/bsctestnet.ts @@ -75,7 +75,7 @@ export const vip384 = () => { { target: COMPTROLLER, signature: "_setMarketSupplyCaps(address[],uint256[])", - params: [[VTWT], [parseUnits("3000000", 18)]], + params: [[VTWT], [parseUnits("2000000", 18)]], }, { From 25f1ff12e47844115d318b40db129262afe33e94 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Wed, 16 Oct 2024 17:53:24 +0200 Subject: [PATCH 040/178] feat: add description of VIP 384 --- vips/vip-384/bscmainnet.ts | 56 ++++++++++++++++++++++++++++++++++---- vips/vip-384/bsctestnet.ts | 2 ++ 2 files changed, 53 insertions(+), 5 deletions(-) diff --git a/vips/vip-384/bscmainnet.ts b/vips/vip-384/bscmainnet.ts index 270e56226..e606510d0 100644 --- a/vips/vip-384/bscmainnet.ts +++ b/vips/vip-384/bscmainnet.ts @@ -57,11 +57,55 @@ const { bscmainnet } = NETWORK_ADDRESSES; export const vip384 = () => { const meta = { version: "v2", - title: "VIP-384 Add TWT Market to core pool on BNB", - description: ``, - forDescription: "I agree that Venus Protocol should proceed with the Add TWT Market", - againstDescription: "I do not think that Venus Protocol should proceed with the Add TWT Market", - abstainDescription: "I am indifferent to whether Venus Protocol proceeds with the Add TWT Market or not", + title: "VIP-384 [BNB Chain] Add support for TWT on Venus Core Pool", + description: `#### Summary + +If passed, this VIP will add a new market for the [TWT token](https://bscscan.com/address/0x4B0F1812e5Df2A09796481Ff14017e6005508003) on Venus Core Pool. Moreover, it will transfer 5,000 USDT to the [Community wallet](https://bscscan.com/address/0xc444949e0054A23c44Fc45789738bdF64aed2391) to compensate for the [provision of the bootstrap liquidity for the market](https://bscscan.com/tx/0x11eefc53948862dd2f1888f6531de87451956c4c998a256181690c782d476641). + +#### Description + +Following [Chaos Labs recommendations](https://community.venus.io/t/chaos-labs-risk-parameter-updates-10-08-24/4606), the risk parameters for the new markets are: + +- Underlying token: [TWT](https://bscscan.com/address/0x4B0F1812e5Df2A09796481Ff14017e6005508003) +- Borrow cap: 1,000,000 TWT +- Supply cap: 2,000,000 TWT +- Collateral factor: 50% +- Reserve factor: 25% + +Bootstrap liquidity: 4,401 TWT - provided by the [Venus Treasury](https://bscscan.com/address/0xf322942f644a996a617bd29c16bd7d231d9f35e9). + +Interest rate curve for the new market: + +- kink: 50% +- base (yearly): 2% +- multiplier (yearly): 20% +- jump multiplier (yearly): 300% + +Oracle configuration: + +- Main oracle: [Binance oracle](https://oracle.binance.com/data-feeds/detail/bsc/TWT-USD) + +#### Security and additional considerations + +No changes in the code are involved in this VIP. We applied the following security procedures for this upgrade: + +- **VIP execution simulation**: in a simulation environment, validating the new market is properly added to the core pool with the right parameters and the expected bootstrap liquidity +- **Deployment on testnet**: the same market has been deployed to testnet, and used in the Venus Protocol testnet deployment + +#### Deployed contracts + +- Mainnet TWT market (vTWT): [0x4d41a36D04D97785bcEA57b057C412b278e6Edcc](https://bscscan.com/address/0x4d41a36D04D97785bcEA57b057C412b278e6Edcc) +- Testnet TWT market (vTWT): [0x95DaED37fdD3F557b3A5cCEb7D50Be65b36721DF](https://testnet.bscscan.com/address/0x95DaED37fdD3F557b3A5cCEb7D50Be65b36721DF) + +#### References + +- [VIP simulation](https://github.com/VenusProtocol/vips/pull/410) +- [Testnet deployment](https://testnet.bscscan.com/tx/0x5af480c14229d75b13cff75901e00090c78dfae8f997f645be84990b36528977) +- Snapshot “[[BNB Chain] Add support for Trust Wallet (TWT) on Venus Core pool](https://snapshot.org/#/venus-xvs.eth/proposal/0xe58d6379604c1b27527d16dccf81ac66a1aba8c963e322dcaf79f2deb62c680e)” +- [Documentation](https://docs-v4.venus.io/)`, + forDescription: "Process to configure and launch the new market", + againstDescription: "Defer configuration and launch of the new market", + abstainDescription: "No opinion on the matter", }; return makeProposal( @@ -146,3 +190,5 @@ export const vip384 = () => { ProposalType.REGULAR, ); }; + +export default vip384; diff --git a/vips/vip-384/bsctestnet.ts b/vips/vip-384/bsctestnet.ts index 43a49c8fe..253a3f962 100644 --- a/vips/vip-384/bsctestnet.ts +++ b/vips/vip-384/bsctestnet.ts @@ -154,3 +154,5 @@ export const vip384 = () => { ProposalType.REGULAR, ); }; + +export default vip384; From 0b159bee7a5e957a70de408fcd9d308819abd106 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Thu, 17 Oct 2024 13:39:07 +0530 Subject: [PATCH 041/178] fix: PR comment Co-authored-by: Debugger022 <104391977+Debugger022@users.noreply.github.com> --- vips/vip-384/bsctestnet.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vips/vip-384/bsctestnet.ts b/vips/vip-384/bsctestnet.ts index 253a3f962..e5ebe5e8d 100644 --- a/vips/vip-384/bsctestnet.ts +++ b/vips/vip-384/bsctestnet.ts @@ -106,7 +106,7 @@ export const vip384 = () => { { target: VTWT, signature: "_setReserveFactor(uint256)", - params: ["250000000000000000"], + params: [parseUnits("0.25", 18)], }, { target: TWT, From 9c3b209aee694d0141d659c467fdb5817d2608e0 Mon Sep 17 00:00:00 2001 From: web3rover Date: Thu, 17 Oct 2024 13:55:11 +0400 Subject: [PATCH 042/178] fix: updated IRM address --- simulations/vip-381/bscmainnet.ts | 8 ++++---- simulations/vip-381/bsctestnet.ts | 10 +++++----- vips/vip-381/bscmainnet.ts | 2 +- vips/vip-381/bsctestnet.ts | 2 +- 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/simulations/vip-381/bscmainnet.ts b/simulations/vip-381/bscmainnet.ts index ff9c5b5c5..d1e6d4c39 100644 --- a/simulations/vip-381/bscmainnet.ts +++ b/simulations/vip-381/bscmainnet.ts @@ -11,7 +11,7 @@ import VTOKEN_CORE_POOL_ABI from "./abi/VTokenCorePool.json"; const OLD_IRM = "0xDb8347b96c94Be24B9c077A4CDDAAD074F6480cf"; const VBNB = "0xA07c5b74C9B40447a954e1466938b865b6BBea36"; -forking(42904608, async () => { +forking(43192903, async () => { const provider = ethers.provider; const vBNB = new ethers.Contract(VBNB, VTOKEN_CORE_POOL_ABI, provider); @@ -47,10 +47,10 @@ forking(42904608, async () => { base: "0", multiplier: "0.225", kink1: "0.4", - multiplier2: "0.5", - base2: "0.1", + multiplier2: "0.35", + base2: "0.21", kink2: "0.7", - jump: "6.8", + jump: "5", }); }); }); diff --git a/simulations/vip-381/bsctestnet.ts b/simulations/vip-381/bsctestnet.ts index e6ea467d8..84ed905e7 100644 --- a/simulations/vip-381/bsctestnet.ts +++ b/simulations/vip-381/bsctestnet.ts @@ -8,10 +8,10 @@ import { checkTwoKinksInterestRate } from "src/vip-framework/checks/interestRate import vip381, { IRM } from "../../vips/vip-381/bsctestnet"; import VTOKEN_CORE_POOL_ABI from "./abi/VTokenCorePool.json"; -const OLD_IRM = "0x597F1eFCC8DD59598eD1944304814f60230BAe76"; +const OLD_IRM = "0x752B56f94c8dF2c3804c0Dd213Cf607FAa9D11b1"; const VBNB = "0x2E7222e51c0f6e98610A1543Aa3836E092CDe62c"; -forking(44524703, async () => { +forking(44812630, async () => { const provider = ethers.provider; const vBNB = new ethers.Contract(VBNB, VTOKEN_CORE_POOL_ABI, provider); @@ -38,10 +38,10 @@ forking(44524703, async () => { base: "0", multiplier: "0.225", kink1: "0.4", - multiplier2: "0.5", - base2: "0.1", + multiplier2: "0.35", + base2: "0.21", kink2: "0.7", - jump: "6.8", + jump: "5", }); }); }); diff --git a/vips/vip-381/bscmainnet.ts b/vips/vip-381/bscmainnet.ts index 7c942423c..0f9e0291f 100644 --- a/vips/vip-381/bscmainnet.ts +++ b/vips/vip-381/bscmainnet.ts @@ -1,7 +1,7 @@ import { ProposalType } from "src/types"; import { makeProposal } from "src/utils"; -export const IRM = "0xc9Be85a8851348f40A6f4773E0fAbC5459E38611"; +export const IRM = "0xC682145a767ca98B743B895f1Bd2D4696bC9C2eC"; export const VBNB_ADMIN = "0x9A7890534d9d91d473F28cB97962d176e2B65f1d"; const vip381 = () => { diff --git a/vips/vip-381/bsctestnet.ts b/vips/vip-381/bsctestnet.ts index a9a0078e2..548a66c27 100644 --- a/vips/vip-381/bsctestnet.ts +++ b/vips/vip-381/bsctestnet.ts @@ -1,7 +1,7 @@ import { ProposalType } from "src/types"; import { makeProposal } from "src/utils"; -export const IRM = "0x752B56f94c8dF2c3804c0Dd213Cf607FAa9D11b1"; +export const IRM = "0x86954c6fCA6B464269Aa7011B143c4D93Dfa1146"; export const VBNB_ADMIN = "0x04109575c1dbB4ac2e59e60c783800ea10441BBe"; const vip381 = () => { From 00614461c83614ee285cab681bf32ff067a76b57 Mon Sep 17 00:00:00 2001 From: Narayan <7037606+web3rover@users.noreply.github.com> Date: Fri, 18 Oct 2024 15:00:05 +0400 Subject: [PATCH 043/178] fix: remove unused vars Co-authored-by: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> --- multisig/proposals/arbitrumsepolia/vip-014/index.ts | 1 - multisig/proposals/ethereum/vip-061/index.ts | 1 - 2 files changed, 2 deletions(-) diff --git a/multisig/proposals/arbitrumsepolia/vip-014/index.ts b/multisig/proposals/arbitrumsepolia/vip-014/index.ts index 3154ab36d..a9db903e4 100644 --- a/multisig/proposals/arbitrumsepolia/vip-014/index.ts +++ b/multisig/proposals/arbitrumsepolia/vip-014/index.ts @@ -29,7 +29,6 @@ export const VTOKENS = [ ]; export const BOUND_VALIDATOR = "0xfe6bc1545Cc14C131bacA97476D6035ffcC0b889"; -export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; const vip014 = () => { return makeProposal([ diff --git a/multisig/proposals/ethereum/vip-061/index.ts b/multisig/proposals/ethereum/vip-061/index.ts index ffe05ed09..9114aee80 100644 --- a/multisig/proposals/ethereum/vip-061/index.ts +++ b/multisig/proposals/ethereum/vip-061/index.ts @@ -67,7 +67,6 @@ export const XVS = "0xd3CC9d8f3689B83c91b7B59cAB4946B063EB894A"; export const BOUND_VALIDATOR = "0x1Cd5f336A1d28Dff445619CC63d3A0329B4d8a58"; export const SFrxETHOracle = "0x5E06A5f48692E4Fff376fDfCA9E4C0183AAADCD1"; -export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; const vip061 = () => { return makeProposal([ From ee45ab5a99da1734bd97baecdee23a218a66d6b1 Mon Sep 17 00:00:00 2001 From: Narayan <7037606+web3rover@users.noreply.github.com> Date: Fri, 18 Oct 2024 15:00:51 +0400 Subject: [PATCH 044/178] fix: fixed title Co-authored-by: Jesus Lanchas --- vips/vip-371/bsctestnet.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vips/vip-371/bsctestnet.ts b/vips/vip-371/bsctestnet.ts index 6789a96fa..a873d5171 100644 --- a/vips/vip-371/bsctestnet.ts +++ b/vips/vip-371/bsctestnet.ts @@ -14,7 +14,7 @@ export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000 const vip371 = () => { const meta = { version: "v2", - title: "VIP-332 accept ownership & give permissions to Normal Timelock", + title: "VIP-371 grant Timelocks and revoke permissions for Guardian in Arbitrum, opBNB and Ethereum", description: `### Description`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", From 4bb5b9a95186fe000a4ad1d5ac23473f5e91dd25 Mon Sep 17 00:00:00 2001 From: web3rover Date: Fri, 18 Oct 2024 15:09:58 +0400 Subject: [PATCH 045/178] fix: removed unused imports --- multisig/proposals/arbitrumsepolia/vip-014/index.ts | 1 - multisig/proposals/ethereum/vip-061/index.ts | 1 - simulations/vip-371/arbitrumsepolia.ts | 10 +++------- simulations/vip-371/opbnbtestnet.ts | 8 ++------ simulations/vip-371/sepolia.ts | 8 ++------ 5 files changed, 7 insertions(+), 21 deletions(-) diff --git a/multisig/proposals/arbitrumsepolia/vip-014/index.ts b/multisig/proposals/arbitrumsepolia/vip-014/index.ts index a9db903e4..b88778ac3 100644 --- a/multisig/proposals/arbitrumsepolia/vip-014/index.ts +++ b/multisig/proposals/arbitrumsepolia/vip-014/index.ts @@ -29,7 +29,6 @@ export const VTOKENS = [ ]; export const BOUND_VALIDATOR = "0xfe6bc1545Cc14C131bacA97476D6035ffcC0b889"; - const vip014 = () => { return makeProposal([ { diff --git a/multisig/proposals/ethereum/vip-061/index.ts b/multisig/proposals/ethereum/vip-061/index.ts index 9114aee80..9392f6f72 100644 --- a/multisig/proposals/ethereum/vip-061/index.ts +++ b/multisig/proposals/ethereum/vip-061/index.ts @@ -67,7 +67,6 @@ export const XVS = "0xd3CC9d8f3689B83c91b7B59cAB4946B063EB894A"; export const BOUND_VALIDATOR = "0x1Cd5f336A1d28Dff445619CC63d3A0329B4d8a58"; export const SFrxETHOracle = "0x5E06A5f48692E4Fff376fDfCA9E4C0183AAADCD1"; - const vip061 = () => { return makeProposal([ { diff --git a/simulations/vip-371/arbitrumsepolia.ts b/simulations/vip-371/arbitrumsepolia.ts index 91e32230f..f92e66d3f 100644 --- a/simulations/vip-371/arbitrumsepolia.ts +++ b/simulations/vip-371/arbitrumsepolia.ts @@ -2,20 +2,16 @@ import { expect } from "chai"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; +import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip014, { ACM } from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import vip371, { DEFAULT_ADMIN_ROLE, ARBITRUMSEPOLIA_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet"; +import { ACM } from "../../multisig/proposals/arbitrumsepolia/vip-014"; +import vip371, { ARBITRUMSEPOLIA_ACM_AGGREGATOR, DEFAULT_ADMIN_ROLE } from "../../vips/vip-371/bsctestnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { arbitrumsepolia } = NETWORK_ADDRESSES; forking(87457288, async () => { - before(async () => { - await pretendExecutingVip(await vip014()); - }); - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [88]); diff --git a/simulations/vip-371/opbnbtestnet.ts b/simulations/vip-371/opbnbtestnet.ts index 387adb352..d9d2939c1 100644 --- a/simulations/vip-371/opbnbtestnet.ts +++ b/simulations/vip-371/opbnbtestnet.ts @@ -2,9 +2,9 @@ import { expect } from "chai"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; +import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip021, { ACM } from "../../multisig/proposals/opbnbtestnet/vip-021"; +import { ACM } from "../../multisig/proposals/opbnbtestnet/vip-021"; import vip371, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; @@ -12,10 +12,6 @@ import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { opbnbtestnet } = NETWORK_ADDRESSES; forking(41684455, async () => { - before(async () => { - await pretendExecutingVip(await vip021()); - }); - testForkedNetworkVipCommands("vip371", await vip371(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [74]); diff --git a/simulations/vip-371/sepolia.ts b/simulations/vip-371/sepolia.ts index c09655138..b6606e0a4 100644 --- a/simulations/vip-371/sepolia.ts +++ b/simulations/vip-371/sepolia.ts @@ -2,9 +2,9 @@ import { expect } from "chai"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; +import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip060, { ACM } from "../../multisig/proposals/sepolia/vip-060"; +import { ACM } from "../../multisig/proposals/sepolia/vip-060"; import vip371, { DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; @@ -12,10 +12,6 @@ import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { sepolia } = NETWORK_ADDRESSES; forking(6850243, async () => { - before(async () => { - await pretendExecutingVip(await vip060()); - }); - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [99]); From 347e73f822a1d29e65b8a1f2e780337206b72753 Mon Sep 17 00:00:00 2001 From: web3rover Date: Fri, 18 Oct 2024 15:18:16 +0400 Subject: [PATCH 046/178] fix: removed vips for ownership transfers --- .../proposals/arbitrumone/vip-014/index.ts | 145 --- .../arbitrumsepolia/vip-014/index.ts | 143 --- multisig/proposals/ethereum/vip-061/index.ts | 203 ---- .../proposals/opbnbmainnet/vip-021/index.ts | 117 --- .../proposals/opbnbtestnet/vip-021/index.ts | 116 --- multisig/proposals/sepolia/vip-060/index.ts | 196 ---- .../arbitrumone/vip-014/abi/Comptroller.json | 929 ------------------ .../vip-014/abi/ComptrollerBeacon.json | 51 - .../vip-014/abi/DefaultProxyAdmin.json | 76 -- .../arbitrumone/vip-014/abi/PoolRegistry.json | 379 ------- .../arbitrumone/vip-014/abi/Prime.json | 763 -------------- .../vip-014/abi/PrimeLiquidityProvider.json | 385 -------- .../vip-014/abi/ProtocolShareReserve.json | 356 ------- .../vip-014/abi/RewardDistrbutor.json | 532 ---------- .../arbitrumone/vip-014/abi/VToken.json | 861 ---------------- .../arbitrumone/vip-014/abi/VTokenBeacon.json | 51 - .../arbitrumone/vip-014/abi/XVSStore.json | 130 --- .../arbitrumone/vip-014/abi/XVSVault.json | 787 --------------- .../vip-014/abi/boundValidator.json | 498 ---------- .../vip-014/abi/chainlinkOracle.json | 459 --------- .../vip-014/abi/resilientOracle.json | 640 ------------ .../arbitrumone/vip-014/abi/treasury.json | 86 -- .../arbitrumone/vip-014/abi/xvs.json | 716 -------------- .../vip-014/abi/xvsBridgeAdmin.json | 329 ------- .../simulations/arbitrumone/vip-014/index.ts | 225 ----- .../vip-014/abi/Comptroller.json | 929 ------------------ .../vip-014/abi/ComptrollerBeacon.json | 51 - .../vip-014/abi/DefaultProxyAdmin.json | 76 -- .../vip-014/abi/PoolRegistry.json | 379 ------- .../arbitrumsepolia/vip-014/abi/Prime.json | 763 -------------- .../vip-014/abi/PrimeLiquidityProvider.json | 385 -------- .../vip-014/abi/ProtocolShareReserve.json | 356 ------- .../vip-014/abi/RewardDistrbutor.json | 532 ---------- .../arbitrumsepolia/vip-014/abi/VToken.json | 861 ---------------- .../vip-014/abi/VTokenBeacon.json | 51 - .../arbitrumsepolia/vip-014/abi/XVSStore.json | 130 --- .../arbitrumsepolia/vip-014/abi/XVSVault.json | 787 --------------- .../vip-014/abi/boundValidator.json | 498 ---------- .../vip-014/abi/chainlinkOracle.json | 459 --------- .../vip-014/abi/resilientOracle.json | 640 ------------ .../arbitrumsepolia/vip-014/abi/treasury.json | 86 -- .../arbitrumsepolia/vip-014/abi/xvs.json | 716 -------------- .../vip-014/abi/xvsBridgeAdmin.json | 329 ------- .../arbitrumsepolia/vip-014/index.ts | 225 ----- .../ethereum/vip-061/abi/Comptroller.json | 929 ------------------ .../vip-061/abi/ComptrollerBeacon.json | 51 - .../vip-061/abi/ConverterNetwork.json | 205 ---- .../vip-061/abi/DefaultProxyAdmin.json | 76 -- .../ethereum/vip-061/abi/PoolRegistry.json | 379 ------- .../ethereum/vip-061/abi/Prime.json | 763 -------------- .../vip-061/abi/PrimeLiquidityProvider.json | 385 -------- .../vip-061/abi/ProtocolShareReserve.json | 356 ------- .../vip-061/abi/RewardDistrbutor.json | 532 ---------- .../vip-061/abi/SingleTokenConverter.json | 587 ----------- .../abi/SingleTokenConverterBeacon.json | 51 - .../ethereum/vip-061/abi/VToken.json | 861 ---------------- .../ethereum/vip-061/abi/VTokenBeacon.json | 51 - .../ethereum/vip-061/abi/XVSStore.json | 130 --- .../ethereum/vip-061/abi/XVSVault.json | 787 --------------- .../ethereum/vip-061/abi/boundValidator.json | 498 ---------- .../ethereum/vip-061/abi/chainlinkOracle.json | 459 --------- .../ethereum/vip-061/abi/resilientOracle.json | 640 ------------ .../ethereum/vip-061/abi/sFrxETHOracle.json | 148 --- .../ethereum/vip-061/abi/treasury.json | 86 -- .../simulations/ethereum/vip-061/abi/xvs.json | 716 -------------- .../ethereum/vip-061/abi/xvsBridgeAdmin.json | 329 ------- .../simulations/ethereum/vip-061/index.ts | 277 ------ .../opbnbmainnet/vip-021/abi/Comptroller.json | 929 ------------------ .../vip-021/abi/ComptrollerBeacon.json | 51 - .../vip-021/abi/ConverterNetwork.json | 205 ---- .../vip-021/abi/DefaultProxyAdmin.json | 76 -- .../vip-021/abi/PoolRegistry.json | 379 ------- .../opbnbmainnet/vip-021/abi/Prime.json | 763 -------------- .../vip-021/abi/PrimeLiquidityProvider.json | 385 -------- .../vip-021/abi/ProtocolShareReserve.json | 356 ------- .../vip-021/abi/RewardDistrbutor.json | 532 ---------- .../vip-021/abi/SingleTokenConverter.json | 587 ----------- .../abi/SingleTokenConverterBeacon.json | 51 - .../opbnbmainnet/vip-021/abi/VToken.json | 861 ---------------- .../vip-021/abi/VTokenBeacon.json | 51 - .../opbnbmainnet/vip-021/abi/XVSStore.json | 130 --- .../opbnbmainnet/vip-021/abi/XVSVault.json | 787 --------------- .../vip-021/abi/boundValidator.json | 498 ---------- .../vip-021/abi/chainlinkOracle.json | 459 --------- .../vip-021/abi/resilientOracle.json | 640 ------------ .../vip-021/abi/sFrxETHOracle.json | 148 --- .../opbnbmainnet/vip-021/abi/treasury.json | 86 -- .../opbnbmainnet/vip-021/abi/xvs.json | 716 -------------- .../vip-021/abi/xvsBridgeAdmin.json | 329 ------- .../simulations/opbnbmainnet/vip-021/index.ts | 181 ---- .../opbnbtestnet/vip-021/abi/Comptroller.json | 929 ------------------ .../vip-021/abi/ComptrollerBeacon.json | 51 - .../vip-021/abi/ConverterNetwork.json | 205 ---- .../vip-021/abi/DefaultProxyAdmin.json | 76 -- .../vip-021/abi/PoolRegistry.json | 379 ------- .../opbnbtestnet/vip-021/abi/Prime.json | 763 -------------- .../vip-021/abi/PrimeLiquidityProvider.json | 385 -------- .../vip-021/abi/ProtocolShareReserve.json | 356 ------- .../vip-021/abi/RewardDistrbutor.json | 532 ---------- .../vip-021/abi/SingleTokenConverter.json | 587 ----------- .../abi/SingleTokenConverterBeacon.json | 51 - .../opbnbtestnet/vip-021/abi/VToken.json | 861 ---------------- .../vip-021/abi/VTokenBeacon.json | 51 - .../opbnbtestnet/vip-021/abi/XVSStore.json | 130 --- .../opbnbtestnet/vip-021/abi/XVSVault.json | 787 --------------- .../vip-021/abi/boundValidator.json | 498 ---------- .../vip-021/abi/chainlinkOracle.json | 459 --------- .../vip-021/abi/resilientOracle.json | 640 ------------ .../vip-021/abi/sFrxETHOracle.json | 148 --- .../opbnbtestnet/vip-021/abi/treasury.json | 86 -- .../opbnbtestnet/vip-021/abi/xvs.json | 716 -------------- .../vip-021/abi/xvsBridgeAdmin.json | 329 ------- .../simulations/opbnbtestnet/vip-021/index.ts | 181 ---- .../sepolia/vip-060/abi/Comptroller.json | 929 ------------------ .../vip-060/abi/ComptrollerBeacon.json | 51 - .../sepolia/vip-060/abi/ConverterNetwork.json | 205 ---- .../vip-060/abi/DefaultProxyAdmin.json | 76 -- .../sepolia/vip-060/abi/PoolRegistry.json | 379 ------- .../sepolia/vip-060/abi/Prime.json | 763 -------------- .../vip-060/abi/PrimeLiquidityProvider.json | 385 -------- .../vip-060/abi/ProtocolShareReserve.json | 356 ------- .../sepolia/vip-060/abi/RewardDistrbutor.json | 532 ---------- .../vip-060/abi/SingleTokenConverter.json | 587 ----------- .../abi/SingleTokenConverterBeacon.json | 51 - .../sepolia/vip-060/abi/VToken.json | 861 ---------------- .../sepolia/vip-060/abi/VTokenBeacon.json | 51 - .../sepolia/vip-060/abi/XVSStore.json | 130 --- .../sepolia/vip-060/abi/XVSVault.json | 787 --------------- .../sepolia/vip-060/abi/boundValidator.json | 498 ---------- .../sepolia/vip-060/abi/chainlinkOracle.json | 459 --------- .../sepolia/vip-060/abi/resilientOracle.json | 640 ------------ .../sepolia/vip-060/abi/sFrxETHOracle.json | 148 --- .../sepolia/vip-060/abi/treasury.json | 86 -- .../simulations/sepolia/vip-060/abi/xvs.json | 716 -------------- .../sepolia/vip-060/abi/xvsBridgeAdmin.json | 329 ------- multisig/simulations/sepolia/vip-060/index.ts | 270 ----- .../vip-372/abi/ACMCommandsAggregator.json | 242 ----- .../vip-372/abi/AccessControlManager.json | 157 --- simulations/vip-372/abi/Comptroller.json | 929 ------------------ .../vip-372/abi/ComptrollerBeacon.json | 51 - simulations/vip-372/abi/ConverterNetwork.json | 205 ---- .../vip-372/abi/DefaultProxyAdmin.json | 76 -- .../vip-372/abi/OmnichainProposalSender.json | 314 ------ simulations/vip-372/abi/PoolRegistry.json | 379 ------- simulations/vip-372/abi/Prime.json | 763 -------------- .../vip-372/abi/PrimeLiquidityProvider.json | 385 -------- .../vip-372/abi/ProtocolShareReserve.json | 356 ------- .../vip-372/abi/RewardDistributor.json | 532 ---------- .../vip-372/abi/SingleTokenConverter.json | 587 ----------- .../abi/SingleTokenConverterBeacon.json | 51 - simulations/vip-372/abi/VToken.json | 861 ---------------- simulations/vip-372/abi/VTokenBeacon.json | 51 - simulations/vip-372/abi/XVSStore.json | 130 --- simulations/vip-372/abi/XVSVault.json | 787 --------------- simulations/vip-372/abi/XVSVaultProxy.json | 122 --- simulations/vip-372/abi/boundValidator.json | 498 ---------- simulations/vip-372/abi/chainlinkOracle.json | 459 --------- simulations/vip-372/abi/resilientOracle.json | 640 ------------ simulations/vip-372/abi/sFrxETHOracle.json | 148 --- simulations/vip-372/abi/treasury.json | 86 -- simulations/vip-372/abi/xvs.json | 716 -------------- simulations/vip-372/abi/xvsBridgeAdmin.json | 329 ------- simulations/vip-372/arbitrumone.ts | 82 -- simulations/vip-372/arbitrumsepolia.ts | 81 -- simulations/vip-372/bscmainnet.ts | 17 - simulations/vip-372/bsctestnet.ts | 17 - simulations/vip-372/ethereum.ts | 97 -- simulations/vip-372/opbnbmainnet.ts | 53 - simulations/vip-372/opbnbtestnet.ts | 52 - simulations/vip-372/sepolia.ts | 97 -- .../vip-373/abi/ACMCommandsAggregator.json | 242 ----- .../vip-373/abi/AccessControlManager.json | 157 --- simulations/vip-373/abi/Comptroller.json | 929 ------------------ .../vip-373/abi/ComptrollerBeacon.json | 51 - simulations/vip-373/abi/ConverterNetwork.json | 205 ---- .../vip-373/abi/DefaultProxyAdmin.json | 76 -- .../vip-373/abi/OmnichainProposalSender.json | 314 ------ simulations/vip-373/abi/PoolRegistry.json | 379 ------- simulations/vip-373/abi/Prime.json | 763 -------------- .../vip-373/abi/PrimeLiquidityProvider.json | 385 -------- .../vip-373/abi/ProtocolShareReserve.json | 356 ------- .../vip-373/abi/RewardDistributor.json | 532 ---------- .../vip-373/abi/SingleTokenConverter.json | 587 ----------- .../abi/SingleTokenConverterBeacon.json | 51 - simulations/vip-373/abi/VToken.json | 861 ---------------- simulations/vip-373/abi/VTokenBeacon.json | 51 - simulations/vip-373/abi/XVSStore.json | 130 --- simulations/vip-373/abi/XVSVault.json | 787 --------------- simulations/vip-373/abi/XVSVaultProxy.json | 122 --- simulations/vip-373/abi/binanceOracle.json | 284 ------ simulations/vip-373/abi/boundValidator.json | 498 ---------- simulations/vip-373/abi/chainlinkOracle.json | 459 --------- simulations/vip-373/abi/resilientOracle.json | 640 ------------ simulations/vip-373/abi/sFrxETHOracle.json | 148 --- simulations/vip-373/abi/treasury.json | 86 -- simulations/vip-373/abi/xvs.json | 716 -------------- simulations/vip-373/abi/xvsBridge.json | 807 --------------- simulations/vip-373/abi/xvsBridgeAdmin.json | 329 ------- simulations/vip-373/arbitrumone.ts | 58 -- simulations/vip-373/arbitrumsepolia.ts | 62 -- simulations/vip-373/bscmainnet.ts | 17 - simulations/vip-373/bsctestnet.ts | 17 - simulations/vip-373/ethereum.ts | 66 -- simulations/vip-373/opbnbmainnet.ts | 58 -- simulations/vip-373/opbnbtestnet.ts | 55 -- simulations/vip-373/sepolia.ts | 65 -- vips/vip-372/bscmainnet.ts | 180 ---- vips/vip-372/bsctestnet.ts | 183 ---- vips/vip-373/bscmainnet.ts | 186 ---- vips/vip-373/bsctestnet.ts | 192 ---- 210 files changed, 76845 deletions(-) delete mode 100644 multisig/proposals/arbitrumone/vip-014/index.ts delete mode 100644 multisig/proposals/arbitrumsepolia/vip-014/index.ts delete mode 100644 multisig/proposals/ethereum/vip-061/index.ts delete mode 100644 multisig/proposals/opbnbmainnet/vip-021/index.ts delete mode 100644 multisig/proposals/opbnbtestnet/vip-021/index.ts delete mode 100644 multisig/proposals/sepolia/vip-060/index.ts delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/Comptroller.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/ComptrollerBeacon.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/DefaultProxyAdmin.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/PoolRegistry.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/Prime.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/PrimeLiquidityProvider.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/ProtocolShareReserve.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/RewardDistrbutor.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/VToken.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/VTokenBeacon.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/XVSStore.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/XVSVault.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/boundValidator.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/chainlinkOracle.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/resilientOracle.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/treasury.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/xvs.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/abi/xvsBridgeAdmin.json delete mode 100644 multisig/simulations/arbitrumone/vip-014/index.ts delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/Comptroller.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/ComptrollerBeacon.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/DefaultProxyAdmin.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/PoolRegistry.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/Prime.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/PrimeLiquidityProvider.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/ProtocolShareReserve.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/RewardDistrbutor.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/VToken.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/VTokenBeacon.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/XVSStore.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/XVSVault.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/boundValidator.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/chainlinkOracle.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/resilientOracle.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/treasury.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/xvs.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/abi/xvsBridgeAdmin.json delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/index.ts delete mode 100644 multisig/simulations/ethereum/vip-061/abi/Comptroller.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/ComptrollerBeacon.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/ConverterNetwork.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/DefaultProxyAdmin.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/PoolRegistry.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/Prime.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/PrimeLiquidityProvider.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/ProtocolShareReserve.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/RewardDistrbutor.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/SingleTokenConverter.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/SingleTokenConverterBeacon.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/VToken.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/VTokenBeacon.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/XVSStore.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/XVSVault.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/boundValidator.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/chainlinkOracle.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/resilientOracle.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/sFrxETHOracle.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/treasury.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/xvs.json delete mode 100644 multisig/simulations/ethereum/vip-061/abi/xvsBridgeAdmin.json delete mode 100644 multisig/simulations/ethereum/vip-061/index.ts delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/Comptroller.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/ComptrollerBeacon.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/ConverterNetwork.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/DefaultProxyAdmin.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/PoolRegistry.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/Prime.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/PrimeLiquidityProvider.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/ProtocolShareReserve.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/RewardDistrbutor.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/SingleTokenConverter.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/SingleTokenConverterBeacon.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/VToken.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/VTokenBeacon.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/XVSStore.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/XVSVault.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/boundValidator.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/chainlinkOracle.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/resilientOracle.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/sFrxETHOracle.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/treasury.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/xvs.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/abi/xvsBridgeAdmin.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-021/index.ts delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/Comptroller.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/ComptrollerBeacon.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/ConverterNetwork.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/DefaultProxyAdmin.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/PoolRegistry.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/Prime.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/PrimeLiquidityProvider.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/ProtocolShareReserve.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/RewardDistrbutor.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/SingleTokenConverter.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/SingleTokenConverterBeacon.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/VToken.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/VTokenBeacon.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/XVSStore.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/XVSVault.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/boundValidator.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/chainlinkOracle.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/resilientOracle.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/sFrxETHOracle.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/treasury.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/xvs.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/abi/xvsBridgeAdmin.json delete mode 100644 multisig/simulations/opbnbtestnet/vip-021/index.ts delete mode 100644 multisig/simulations/sepolia/vip-060/abi/Comptroller.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/ComptrollerBeacon.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/ConverterNetwork.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/DefaultProxyAdmin.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/PoolRegistry.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/Prime.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/PrimeLiquidityProvider.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/ProtocolShareReserve.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/RewardDistrbutor.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/SingleTokenConverter.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/SingleTokenConverterBeacon.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/VToken.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/VTokenBeacon.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/XVSStore.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/XVSVault.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/boundValidator.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/chainlinkOracle.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/resilientOracle.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/sFrxETHOracle.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/treasury.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/xvs.json delete mode 100644 multisig/simulations/sepolia/vip-060/abi/xvsBridgeAdmin.json delete mode 100644 multisig/simulations/sepolia/vip-060/index.ts delete mode 100644 simulations/vip-372/abi/ACMCommandsAggregator.json delete mode 100644 simulations/vip-372/abi/AccessControlManager.json delete mode 100644 simulations/vip-372/abi/Comptroller.json delete mode 100644 simulations/vip-372/abi/ComptrollerBeacon.json delete mode 100644 simulations/vip-372/abi/ConverterNetwork.json delete mode 100644 simulations/vip-372/abi/DefaultProxyAdmin.json delete mode 100644 simulations/vip-372/abi/OmnichainProposalSender.json delete mode 100644 simulations/vip-372/abi/PoolRegistry.json delete mode 100644 simulations/vip-372/abi/Prime.json delete mode 100644 simulations/vip-372/abi/PrimeLiquidityProvider.json delete mode 100644 simulations/vip-372/abi/ProtocolShareReserve.json delete mode 100644 simulations/vip-372/abi/RewardDistributor.json delete mode 100644 simulations/vip-372/abi/SingleTokenConverter.json delete mode 100644 simulations/vip-372/abi/SingleTokenConverterBeacon.json delete mode 100644 simulations/vip-372/abi/VToken.json delete mode 100644 simulations/vip-372/abi/VTokenBeacon.json delete mode 100644 simulations/vip-372/abi/XVSStore.json delete mode 100644 simulations/vip-372/abi/XVSVault.json delete mode 100644 simulations/vip-372/abi/XVSVaultProxy.json delete mode 100644 simulations/vip-372/abi/boundValidator.json delete mode 100644 simulations/vip-372/abi/chainlinkOracle.json delete mode 100644 simulations/vip-372/abi/resilientOracle.json delete mode 100644 simulations/vip-372/abi/sFrxETHOracle.json delete mode 100644 simulations/vip-372/abi/treasury.json delete mode 100644 simulations/vip-372/abi/xvs.json delete mode 100644 simulations/vip-372/abi/xvsBridgeAdmin.json delete mode 100644 simulations/vip-372/arbitrumone.ts delete mode 100644 simulations/vip-372/arbitrumsepolia.ts delete mode 100644 simulations/vip-372/bscmainnet.ts delete mode 100644 simulations/vip-372/bsctestnet.ts delete mode 100644 simulations/vip-372/ethereum.ts delete mode 100644 simulations/vip-372/opbnbmainnet.ts delete mode 100644 simulations/vip-372/opbnbtestnet.ts delete mode 100644 simulations/vip-372/sepolia.ts delete mode 100644 simulations/vip-373/abi/ACMCommandsAggregator.json delete mode 100644 simulations/vip-373/abi/AccessControlManager.json delete mode 100644 simulations/vip-373/abi/Comptroller.json delete mode 100644 simulations/vip-373/abi/ComptrollerBeacon.json delete mode 100644 simulations/vip-373/abi/ConverterNetwork.json delete mode 100644 simulations/vip-373/abi/DefaultProxyAdmin.json delete mode 100644 simulations/vip-373/abi/OmnichainProposalSender.json delete mode 100644 simulations/vip-373/abi/PoolRegistry.json delete mode 100644 simulations/vip-373/abi/Prime.json delete mode 100644 simulations/vip-373/abi/PrimeLiquidityProvider.json delete mode 100644 simulations/vip-373/abi/ProtocolShareReserve.json delete mode 100644 simulations/vip-373/abi/RewardDistributor.json delete mode 100644 simulations/vip-373/abi/SingleTokenConverter.json delete mode 100644 simulations/vip-373/abi/SingleTokenConverterBeacon.json delete mode 100644 simulations/vip-373/abi/VToken.json delete mode 100644 simulations/vip-373/abi/VTokenBeacon.json delete mode 100644 simulations/vip-373/abi/XVSStore.json delete mode 100644 simulations/vip-373/abi/XVSVault.json delete mode 100644 simulations/vip-373/abi/XVSVaultProxy.json delete mode 100644 simulations/vip-373/abi/binanceOracle.json delete mode 100644 simulations/vip-373/abi/boundValidator.json delete mode 100644 simulations/vip-373/abi/chainlinkOracle.json delete mode 100644 simulations/vip-373/abi/resilientOracle.json delete mode 100644 simulations/vip-373/abi/sFrxETHOracle.json delete mode 100644 simulations/vip-373/abi/treasury.json delete mode 100644 simulations/vip-373/abi/xvs.json delete mode 100644 simulations/vip-373/abi/xvsBridge.json delete mode 100644 simulations/vip-373/abi/xvsBridgeAdmin.json delete mode 100644 simulations/vip-373/arbitrumone.ts delete mode 100644 simulations/vip-373/arbitrumsepolia.ts delete mode 100644 simulations/vip-373/bscmainnet.ts delete mode 100644 simulations/vip-373/bsctestnet.ts delete mode 100644 simulations/vip-373/ethereum.ts delete mode 100644 simulations/vip-373/opbnbmainnet.ts delete mode 100644 simulations/vip-373/opbnbtestnet.ts delete mode 100644 simulations/vip-373/sepolia.ts delete mode 100644 vips/vip-372/bscmainnet.ts delete mode 100644 vips/vip-372/bsctestnet.ts delete mode 100644 vips/vip-373/bscmainnet.ts delete mode 100644 vips/vip-373/bsctestnet.ts diff --git a/multisig/proposals/arbitrumone/vip-014/index.ts b/multisig/proposals/arbitrumone/vip-014/index.ts deleted file mode 100644 index dcf0d7af2..000000000 --- a/multisig/proposals/arbitrumone/vip-014/index.ts +++ /dev/null @@ -1,145 +0,0 @@ -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { makeProposal } from "src/utils"; - -const { arbitrumone } = NETWORK_ADDRESSES; - -export const DEFAULT_PROXY_ADMIN = "0xF6fF3e9459227f0cDE8B102b90bE25960317b216"; -export const ACM = "0xD9dD18EB0cf10CbA837677f28A8F9Bda4bc2b157"; -export const PRIME = "0xFE69720424C954A2da05648a0FAC84f9bf11Ef49"; -export const PLP = "0x86bf21dB200f29F21253080942Be8af61046Ec29"; -export const REWARD_DISTRIBUTORS = ["0x53b488baA4052094495b6De9E5505FE1Ee3EAc7a"]; -export const PSR = "0xF9263eaF7eB50815194f26aCcAB6765820B13D41"; -export const COMPTROLLER_BEACON = "0x8b6c2E8672504523Ca3a29a5527EcF47fC7d43FC"; -export const VTOKEN_BEACON = "0xE9381D8CA7006c12Ae9eB97890575E705996fa66"; -export const POOL_REGISTRY = "0x382238f07Bc4Fe4aA99e561adE8A4164b5f815DA"; -export const XVS_STORE = "0x507D9923c954AAD8eC530ed8Dedb75bFc893Ec5e"; -export const COMPTROLLERS = ["0x317c1A5739F39046E20b08ac9BeEa3f10fD43326"]; -export const XVS_BRIDGE_ADMIN_PROXY = "0xf5d81C6F7DAA3F97A6265C8441f92eFda22Ad784"; -export const XVS = "0xc1Eb7689147C81aC840d4FF0D298489fc7986d52"; -export const BOUND_VALIDATOR = "0x2245FA2420925Cd3C2D889Ddc5bA1aefEF0E14CF"; - -export const VTOKENS = [ - "0xaDa57840B372D4c28623E87FC175dE8490792811", - "0x68a34332983f4Bf866768DD6D6E638b02eF5e1f0", - "0xB9F9117d4200dC296F9AcD1e8bE1937df834a2fD", - "0x7D8609f8da70fF9027E9bc5229Af4F6727662707", - "0xAeB0FEd69354f34831fe1D16475D9A83ddaCaDA6", - "0x39D6d13Ea59548637104E40e729E4aABE27FE106", - "0x246a35E79a3a0618535A469aDaF5091cAA9f7E88", - "0x9df6B5132135f14719696bBAe3C54BAb272fDb16", -]; - -export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; - -const vip014 = () => { - return makeProposal([ - { - target: DEFAULT_PROXY_ADMIN, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }, - { - target: PRIME, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }, - { - target: PLP, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }, - ...REWARD_DISTRIBUTORS.map(rewardDistributor => { - return { - target: rewardDistributor, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }; - }), - { - target: PSR, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }, - { - target: COMPTROLLER_BEACON, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }, - { - target: VTOKEN_BEACON, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }, - { - target: POOL_REGISTRY, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }, - ...COMPTROLLERS.map(comptroller => { - return { - target: comptroller, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }; - }), - ...VTOKENS.map(comptroller => { - return { - target: comptroller, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }; - }), - { - target: arbitrumone.XVS_VAULT_PROXY, - signature: "_setPendingAdmin(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }, - { - target: XVS_STORE, - signature: "setPendingAdmin(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }, - { - target: XVS_BRIDGE_ADMIN_PROXY, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }, - { - target: XVS, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }, - { - target: arbitrumone.RESILIENT_ORACLE, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }, - { - target: arbitrumone.CHAINLINK_ORACLE, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }, - { - target: arbitrumone.REDSTONE_ORACLE, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }, - { - target: BOUND_VALIDATOR, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }, - { - target: arbitrumone.VTREASURY, - signature: "transferOwnership(address)", - params: [arbitrumone.NORMAL_TIMELOCK], - }, - { - target: XVS_BRIDGE_ADMIN_PROXY, - signature: "setWhitelist(address,bool)", - params: [arbitrumone.NORMAL_TIMELOCK, true], - }, - ]); -}; - -export default vip014; diff --git a/multisig/proposals/arbitrumsepolia/vip-014/index.ts b/multisig/proposals/arbitrumsepolia/vip-014/index.ts deleted file mode 100644 index b88778ac3..000000000 --- a/multisig/proposals/arbitrumsepolia/vip-014/index.ts +++ /dev/null @@ -1,143 +0,0 @@ -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { makeProposal } from "src/utils"; - -const { arbitrumsepolia } = NETWORK_ADDRESSES; -export const DEFAULT_PROXY_ADMIN = "0xA78A1Df376c3CEeBC5Fab574fe6EdDbbF76fd03e"; -export const PRIME = "0xadb04ac4942683bc41e27d18234c8dc884786e89"; -export const PLP = "0xe82c2c10f55d3268126c29ec813dc6f086904694"; -export const REWARD_DISTRIBUTORS = ["0x6c65135d102e2Dfa1b0852351cF9b2cbc1788972"]; -export const PSR = "0x09267d30798B59c581ce54E861A084C6FC298666"; -export const COMPTROLLER_BEACON = "0x12Dcb8D9F1eE7Ad7410F5B36B07bcC7891ab4cEf"; -export const VTOKEN_BEACON = "0x74ae9919F5866cE148c81331a5FCdE71b81c4056"; -export const ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; -export const POOL_REGISTRY = "0xf93Df3135e0D555185c0BC888073374cA551C5fE"; - -export const COMPTROLLERS = ["0x006D44b6f5927b3eD83bD0c1C36Fb1A3BaCaC208"]; -export const XVS_STORE = "0x4e909DA6693215dC630104715c035B159dDb67Dd"; -export const XVS_BRIDGE_ADMIN_PROXY = "0xc94578caCC89a29B044a0a1D54d20d48A645E5C8"; -export const XVS = "0x877Dc896e7b13096D3827872e396927BbE704407"; - -export const VTOKENS = [ - "0x49FB90A5815904649C44B87001a160C1301D6a2C", - "0x807dCB6946dDF4C5C6446B1B07ACd248B08F45e2", - "0xdEFbf0F9Ab6CdDd0a1FdDC894b358D0c0a39B052", - "0xd9d1e754464eFc7493B177d2c7be04816E089b4C", - "0x292Ec2b45C549Bc2c6B31937dBd511beaAEabea8", - "0xd7057250b439c0849377bB6C3263eb8f9cf49d98", - "0x75f841b14305935D8D7E806f249D9FA52EF1550B", - "0x253515E19e8b888a4CA5a0a3363B712402ce4046", -]; -export const BOUND_VALIDATOR = "0xfe6bc1545Cc14C131bacA97476D6035ffcC0b889"; - -const vip014 = () => { - return makeProposal([ - { - target: DEFAULT_PROXY_ADMIN, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }, - { - target: PRIME, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }, - { - target: PLP, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }, - ...REWARD_DISTRIBUTORS.map(rewardDistributor => { - return { - target: rewardDistributor, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }; - }), - { - target: PSR, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }, - { - target: COMPTROLLER_BEACON, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }, - { - target: VTOKEN_BEACON, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }, - { - target: POOL_REGISTRY, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }, - ...COMPTROLLERS.map(comptroller => { - return { - target: comptroller, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }; - }), - ...VTOKENS.map(comptroller => { - return { - target: comptroller, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }; - }), - { - target: arbitrumsepolia.XVS_VAULT_PROXY, - signature: "_setPendingAdmin(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }, - { - target: XVS_STORE, - signature: "setPendingAdmin(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }, - { - target: XVS_BRIDGE_ADMIN_PROXY, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }, - { - target: XVS, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }, - { - target: arbitrumsepolia.RESILIENT_ORACLE, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }, - { - target: arbitrumsepolia.CHAINLINK_ORACLE, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }, - { - target: arbitrumsepolia.REDSTONE_ORACLE, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }, - { - target: BOUND_VALIDATOR, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }, - { - target: arbitrumsepolia.VTREASURY, - signature: "transferOwnership(address)", - params: [arbitrumsepolia.NORMAL_TIMELOCK], - }, - { - target: XVS_BRIDGE_ADMIN_PROXY, - signature: "setWhitelist(address,bool)", - params: [arbitrumsepolia.NORMAL_TIMELOCK, true], - }, - ]); -}; - -export default vip014; diff --git a/multisig/proposals/ethereum/vip-061/index.ts b/multisig/proposals/ethereum/vip-061/index.ts deleted file mode 100644 index 9392f6f72..000000000 --- a/multisig/proposals/ethereum/vip-061/index.ts +++ /dev/null @@ -1,203 +0,0 @@ -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { makeProposal } from "src/utils"; - -const { ethereum } = NETWORK_ADDRESSES; -export const DEFAULT_PROXY_ADMIN = "0x567e4cc5e085d09f66f836fa8279f38b4e5866b9"; -export const CONVERTERS = [ - "0xaE39C38AF957338b3cEE2b3E5d825ea88df02EfE", - "0x4f55cb0a24D5542a3478B0E284259A6B850B06BD", - "0xcEB9503f10B781E30213c0b320bCf3b3cE54216E", - "0xDcCDE673Cd8988745dA384A7083B0bd22085dEA0", - "0xb8fD67f215117FADeF06447Af31590309750529D", - "0x1FD30e761C3296fE36D9067b1e398FD97B4C0407", -]; -export const SINGLE_TOKEN_CONVERTER_BEACON = "0x5C0b5D09388F2BA6441E74D40666C4d96e4527D1"; -export const CONVERTER_NETWORK = "0x232CC47AECCC55C2CAcE4372f5B268b27ef7cac8"; -export const PRIME = "0x14C4525f47A7f7C984474979c57a2Dccb8EACB39"; -export const PLP = "0x8ba6aFfd0e7Bcd0028D1639225C84DdCf53D8872"; -export const REWARD_DISTRIBUTORS = [ - "0x134bfDEa7e68733921Bc6A87159FB0d68aBc6Cf8", - "0x76611EEA26aF8842281B56Bb742129E77133592F", - "0x886767B62C7ACD601672607373048FFD96Cf27B2", - "0x8473B767F68250F5309bae939337136a899E43F9", - "0x5f65A7b60b4F91229B8484F80bc2EEc52758EAf9", - "0x461dE281c453F447200D67C9Dd31b3046c8f49f8", - "0x7A91bEd36D96E4e644d3A181c287E0fcf9E9cc98", - "0xe72Aa7BaB160eaa2605964D2379AA56Cb4b9A1BB", - "0xDCB0CfA130496c749738Acbe2d6aA06C7C320f06", - "0x1e25CF968f12850003Db17E0Dba32108509C4359", -]; -export const PSR = "0x8c8c8530464f7D95552A11eC31Adbd4dC4AC4d3E"; -export const COMPTROLLER_BEACON = "0xAE2C3F21896c02510aA187BdA0791cDA77083708"; -export const VTOKEN_BEACON = "0xfc08aADC7a1A93857f6296C3fb78aBA1d286533a"; -export const ETHEREUM_ACM = "0x230058da2D23eb8836EC5DB7037ef7250c56E25E"; -export const POOL_REGISTRY = "0x61CAff113CCaf05FFc6540302c37adcf077C5179"; -export const ACM = "0x230058da2D23eb8836EC5DB7037ef7250c56E25E"; - -export const COMPTROLLERS = [ - "0x687a01ecF6d3907658f7A7c714749fAC32336D1B", - "0x67aA3eCc5831a65A5Ba7be76BED3B5dc7DB60796", - "0xF522cd0360EF8c2FF48B648d53EA1717Ec0F3Ac3", -]; - -export const VTOKENS = [ - "0x672208C10aaAA2F9A6719F449C4C8227bc0BC202", - "0xd8AdD9B41D4E1cd64Edad8722AB0bA8D35536657", - "0x4fAfbDc4F2a9876Bd1764827b26fb8dc4FD1dB95", - "0x17142a05fe678e9584FA1d88EfAC1bF181bF7ABe", - "0x13eB80FDBe5C5f4a7039728E258A6f05fb3B912b", - "0x17C07e0c232f2f80DfDbd7a95b942D893A4C5ACb", - "0x8C3e3821259B82fFb32B2450A95d2dcbf161C24E", - "0x8716554364f20BCA783cb2BAA744d39361fd1D8d", - "0x7c8ff7d2A1372433726f879BD945fFb250B94c65", - "0x2d499800239C4CD3012473Cb1EAE33562F0A6933", - "0x30aD10Bd5Be62CAb37863C2BfcC6E8fb4fD85BDa", - "0xA854D35664c658280fFf27B6eDC6C4195c3229B3", - "0x76697f8eaeA4bE01C678376aAb97498Ee8f80D5C", - "0xDB6C345f864883a8F4cae87852Ac342589E76D1B", - "0xF9E9Fe17C00a8B96a8ac20c4E344C8688D7b947E", - "0xc82780Db1257C788F262FBbDA960B3706Dfdcaf2", - "0x4a240F0ee138697726C8a3E43eFE6Ac3593432CB", - "0xb4933AF59868986316Ed37fa865C829Eba2df0C7", - "0xEF26C64bC06A8dE4CA5D31f119835f9A1d9433b9", -]; -export const XVS_STORE = "0x1Db646E1Ab05571AF99e47e8F909801e5C99d37B"; -export const XVS_BRIDGE_ADMIN_PROXY = "0x9C6C95632A8FB3A74f2fB4B7FfC50B003c992b96"; -export const XVS = "0xd3CC9d8f3689B83c91b7B59cAB4946B063EB894A"; -export const BOUND_VALIDATOR = "0x1Cd5f336A1d28Dff445619CC63d3A0329B4d8a58"; -export const SFrxETHOracle = "0x5E06A5f48692E4Fff376fDfCA9E4C0183AAADCD1"; - -const vip061 = () => { - return makeProposal([ - { - target: DEFAULT_PROXY_ADMIN, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - { - target: SINGLE_TOKEN_CONVERTER_BEACON, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - { - target: CONVERTER_NETWORK, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - ...CONVERTERS.map(converter => { - return { - target: converter, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }; - }), - { - target: PRIME, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - { - target: PLP, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - ...REWARD_DISTRIBUTORS.map(rewardDistributor => { - return { - target: rewardDistributor, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }; - }), - { - target: PSR, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - { - target: COMPTROLLER_BEACON, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - { - target: VTOKEN_BEACON, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - { - target: POOL_REGISTRY, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - ...COMPTROLLERS.map(comptroller => { - return { - target: comptroller, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }; - }), - ...VTOKENS.map(comptroller => { - return { - target: comptroller, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }; - }), - { - target: ethereum.XVS_VAULT_PROXY, - signature: "_setPendingAdmin(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - { - target: XVS_STORE, - signature: "setPendingAdmin(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - { - target: XVS_BRIDGE_ADMIN_PROXY, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - { - target: XVS, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - { - target: ethereum.RESILIENT_ORACLE, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - { - target: ethereum.CHAINLINK_ORACLE, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - { - target: ethereum.REDSTONE_ORACLE, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - { - target: BOUND_VALIDATOR, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - { - target: SFrxETHOracle, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - { - target: ethereum.VTREASURY, - signature: "transferOwnership(address)", - params: [ethereum.NORMAL_TIMELOCK], - }, - { - target: XVS_BRIDGE_ADMIN_PROXY, - signature: "setWhitelist(address,bool)", - params: [ethereum.NORMAL_TIMELOCK, true], - }, - ]); -}; - -export default vip061; diff --git a/multisig/proposals/opbnbmainnet/vip-021/index.ts b/multisig/proposals/opbnbmainnet/vip-021/index.ts deleted file mode 100644 index c1b81a2bd..000000000 --- a/multisig/proposals/opbnbmainnet/vip-021/index.ts +++ /dev/null @@ -1,117 +0,0 @@ -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { makeProposal } from "src/utils"; - -const { opbnbmainnet } = NETWORK_ADDRESSES; -export const DEFAULT_PROXY_ADMIN = "0xF77bD1D893F67b3EB2Cd256239c98Ba3F238fb52"; -export const PSR = "0xA2EDD515B75aBD009161B15909C19959484B0C1e"; -export const COMPTROLLER_BEACON = "0x11C3e19236ce17729FC66b74B537de00C54d44e7"; -export const VTOKEN_BEACON = "0xfeD1d3a13597c5aBc893Af41ED5cb17e64c847c7"; -export const ACM = "0xA60Deae5344F1152426cA440fb6552eA0e3005D6"; -export const POOL_REGISTRY = "0x345a030Ad22e2317ac52811AC41C1A63cfa13aEe"; - -export const COMPTROLLERS = ["0xD6e3E2A1d8d95caE355D15b3b9f8E5c2511874dd"]; - -export const VTOKENS = [ - "0xED827b80Bd838192EA95002C01B5c6dA8354219a", - "0x509e81eF638D489936FA85BC58F52Df01190d26C", - "0x13B492B8A03d072Bab5C54AC91Dba5b830a50917", - "0xb7a01Ba126830692238521a1aA7E7A7509410b8e", - "0x53d11cB8A0e5320Cd7229C3acc80d1A0707F2672", -]; -export const XVS_STORE = "0xc3279442a5aCaCF0A2EcB015d1cDDBb3E0f3F775"; -export const XVS_BRIDGE_ADMIN_PROXY = "0x52fcE05aDbf6103d71ed2BA8Be7A317282731831"; -export const XVS = "0x3E2e61F1c075881F3fB8dd568043d8c221fd5c61"; -export const BOUND_VALIDATOR = "0xd1f80C371C6E2Fa395A5574DB3E3b4dAf43dadCE"; - -export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; - -const vip021 = () => { - return makeProposal([ - { - target: DEFAULT_PROXY_ADMIN, - signature: "transferOwnership(address)", - params: [opbnbmainnet.NORMAL_TIMELOCK], - }, - { - target: PSR, - signature: "transferOwnership(address)", - params: [opbnbmainnet.NORMAL_TIMELOCK], - }, - { - target: COMPTROLLER_BEACON, - signature: "transferOwnership(address)", - params: [opbnbmainnet.NORMAL_TIMELOCK], - }, - { - target: VTOKEN_BEACON, - signature: "transferOwnership(address)", - params: [opbnbmainnet.NORMAL_TIMELOCK], - }, - { - target: POOL_REGISTRY, - signature: "transferOwnership(address)", - params: [opbnbmainnet.NORMAL_TIMELOCK], - }, - ...COMPTROLLERS.map(comptroller => { - return { - target: comptroller, - signature: "transferOwnership(address)", - params: [opbnbmainnet.NORMAL_TIMELOCK], - }; - }), - ...VTOKENS.map(comptroller => { - return { - target: comptroller, - signature: "transferOwnership(address)", - params: [opbnbmainnet.NORMAL_TIMELOCK], - }; - }), - { - target: opbnbmainnet.XVS_VAULT_PROXY, - signature: "_setPendingAdmin(address)", - params: [opbnbmainnet.NORMAL_TIMELOCK], - }, - { - target: XVS_STORE, - signature: "setPendingAdmin(address)", - params: [opbnbmainnet.NORMAL_TIMELOCK], - }, - { - target: XVS_BRIDGE_ADMIN_PROXY, - signature: "transferOwnership(address)", - params: [opbnbmainnet.NORMAL_TIMELOCK], - }, - { - target: XVS, - signature: "transferOwnership(address)", - params: [opbnbmainnet.NORMAL_TIMELOCK], - }, - { - target: opbnbmainnet.RESILIENT_ORACLE, - signature: "transferOwnership(address)", - params: [opbnbmainnet.NORMAL_TIMELOCK], - }, - { - target: opbnbmainnet.BINANCE_ORACLE, - signature: "transferOwnership(address)", - params: [opbnbmainnet.NORMAL_TIMELOCK], - }, - { - target: BOUND_VALIDATOR, - signature: "transferOwnership(address)", - params: [opbnbmainnet.NORMAL_TIMELOCK], - }, - { - target: opbnbmainnet.VTREASURY, - signature: "transferOwnership(address)", - params: [opbnbmainnet.NORMAL_TIMELOCK], - }, - { - target: XVS_BRIDGE_ADMIN_PROXY, - signature: "setWhitelist(address,bool)", - params: [opbnbmainnet.NORMAL_TIMELOCK, true], - }, - ]); -}; - -export default vip021; diff --git a/multisig/proposals/opbnbtestnet/vip-021/index.ts b/multisig/proposals/opbnbtestnet/vip-021/index.ts deleted file mode 100644 index 9ccf7a7b2..000000000 --- a/multisig/proposals/opbnbtestnet/vip-021/index.ts +++ /dev/null @@ -1,116 +0,0 @@ -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { makeProposal } from "src/utils"; - -const { opbnbtestnet } = NETWORK_ADDRESSES; -export const DEFAULT_PROXY_ADMIN = "0xB1281ADC816fba7df64B798D7A0BC4bd2a6d42f4"; -export const PSR = "0xc355dEb1A9289f8C58CFAa076EEdBf51F3A8Da7F"; -export const COMPTROLLER_BEACON = "0x2020BDa1F931E07B14C9d346E2f6D5943b4cd56D"; -export const VTOKEN_BEACON = "0xcc633492097078Ae590C0d11924e82A23f3Ab3E2"; -export const ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; -export const POOL_REGISTRY = "0x560eA4e1cC42591E9f5F5D83Ad2fd65F30128951"; - -export const COMPTROLLERS = ["0x2FCABb31E57F010D623D8d68e1E18Aed11d5A388"]; - -export const VTOKENS = [ - "0x86F82bca79774fc04859966917D2291A68b870A9", - "0x034Cc5097379B13d3Ed5F6c85c8FAf20F48aE480", - "0xe3923805f6E117E51f5387421240a86EF1570abC", - "0xD36a31AcD3d901AeD998da6E24e848798378474e", -]; -export const XVS_STORE = "0x06473fB3f7bF11e2E8EfEcC95aC55ABEFCb2e0A0"; -export const XVS_BRIDGE_ADMIN_PROXY = "0x19252AFD0B2F539C400aEab7d460CBFbf74c17ff"; -export const XVS = "0xc2931B1fEa69b6D6dA65a50363A8D75d285e4da9"; -export const BOUND_VALIDATOR = "0x049537Bb065e6253e9D8D08B45Bf6b753657A746"; - -export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; - -const vip021 = () => { - return makeProposal([ - { - target: DEFAULT_PROXY_ADMIN, - signature: "transferOwnership(address)", - params: [opbnbtestnet.NORMAL_TIMELOCK], - }, - { - target: PSR, - signature: "transferOwnership(address)", - params: [opbnbtestnet.NORMAL_TIMELOCK], - }, - { - target: COMPTROLLER_BEACON, - signature: "transferOwnership(address)", - params: [opbnbtestnet.NORMAL_TIMELOCK], - }, - { - target: VTOKEN_BEACON, - signature: "transferOwnership(address)", - params: [opbnbtestnet.NORMAL_TIMELOCK], - }, - { - target: POOL_REGISTRY, - signature: "transferOwnership(address)", - params: [opbnbtestnet.NORMAL_TIMELOCK], - }, - ...COMPTROLLERS.map(comptroller => { - return { - target: comptroller, - signature: "transferOwnership(address)", - params: [opbnbtestnet.NORMAL_TIMELOCK], - }; - }), - ...VTOKENS.map(comptroller => { - return { - target: comptroller, - signature: "transferOwnership(address)", - params: [opbnbtestnet.NORMAL_TIMELOCK], - }; - }), - { - target: opbnbtestnet.XVS_VAULT_PROXY, - signature: "_setPendingAdmin(address)", - params: [opbnbtestnet.NORMAL_TIMELOCK], - }, - { - target: XVS_STORE, - signature: "setPendingAdmin(address)", - params: [opbnbtestnet.NORMAL_TIMELOCK], - }, - { - target: XVS_BRIDGE_ADMIN_PROXY, - signature: "transferOwnership(address)", - params: [opbnbtestnet.NORMAL_TIMELOCK], - }, - { - target: XVS, - signature: "transferOwnership(address)", - params: [opbnbtestnet.NORMAL_TIMELOCK], - }, - { - target: opbnbtestnet.RESILIENT_ORACLE, - signature: "transferOwnership(address)", - params: [opbnbtestnet.NORMAL_TIMELOCK], - }, - { - target: opbnbtestnet.BINANCE_ORACLE, - signature: "transferOwnership(address)", - params: [opbnbtestnet.NORMAL_TIMELOCK], - }, - { - target: BOUND_VALIDATOR, - signature: "transferOwnership(address)", - params: [opbnbtestnet.NORMAL_TIMELOCK], - }, - { - target: opbnbtestnet.VTREASURY, - signature: "transferOwnership(address)", - params: [opbnbtestnet.NORMAL_TIMELOCK], - }, - { - target: XVS_BRIDGE_ADMIN_PROXY, - signature: "setWhitelist(address,bool)", - params: [opbnbtestnet.NORMAL_TIMELOCK, true], - }, - ]); -}; - -export default vip021; diff --git a/multisig/proposals/sepolia/vip-060/index.ts b/multisig/proposals/sepolia/vip-060/index.ts deleted file mode 100644 index d7861599a..000000000 --- a/multisig/proposals/sepolia/vip-060/index.ts +++ /dev/null @@ -1,196 +0,0 @@ -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { makeProposal } from "src/utils"; - -const { sepolia } = NETWORK_ADDRESSES; -export const DEFAULT_PROXY_ADMIN = "0xe98a3110929c6650c73031756288Ec518f65e846"; -export const CONVERTERS = [ - "0xCCB08e5107b406E67Ad8356023dd489CEbc79B40", - "0x3716C24EA86A67cAf890d7C9e4C4505cDDC2F8A2", - "0x511a559a699cBd665546a1F75908f7E9454Bfc67", - "0x8a3937F27921e859db3FDA05729CbCea8cfd82AE", - "0x274a834eFFA8D5479502dD6e78925Bc04ae82B46", - "0xc203bfA9dCB0B5fEC510Db644A494Ff7f4968ed2", -]; -export const SINGLE_TOKEN_CONVERTER_BEACON = "0xb86e532a5333d413A1c35d86cCdF1484B40219eF"; -export const CONVERTER_NETWORK = "0xB5A4208bFC4cC2C4670744849B8fC35B21A690Fa"; -export const PRIME = "0x2Ec432F123FEbb114e6fbf9f4F14baF0B1F14AbC"; -export const PLP = "0x15242a55Ad1842A1aEa09c59cf8366bD2f3CE9B4"; -export const REWARD_DISTRIBUTORS = [ - "0xB60666395bEFeE02a28938b75ea620c7191cA77a", - "0x341f52BfecC10115087e46eB94AA06E384b8925E", - "0x67dA6435b35d43081c7c27685fAbb2662b7f1290", - "0xF6D57F8e37b1cb627470b5254fAb08dE07B49A0F", - "0x4597B9287fE0DF3c5513D66886706E0719bD270f", - "0xec594364d2B7eB3678f351Ac632cC71E718E0F89", - "0x92e8E3C202093A495e98C10f9fcaa5Abe288F74A", -]; -export const PSR = "0xbea70755cc3555708ca11219adB0db4C80F6721B"; -export const COMPTROLLER_BEACON = "0x6cE54143a88CC22500D49D744fb6535D66a8294F"; -export const VTOKEN_BEACON = "0x0463a7E5221EAE1990cEddB51A5821a68cdA6008"; -export const ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; -export const POOL_REGISTRY = "0x758f5715d817e02857Ba40889251201A5aE3E186"; - -export const COMPTROLLERS = ["0x7Aa39ab4BcA897F403425C9C6FDbd0f882Be0D70"]; - -export const VTOKENS = [ - "0xA09cFAd2e138fe6d8FF62df803892cbCb79ED082", - "0x121E3be152F283319310D807ed847E8b98319C1e", - "0xfe050f628bF5278aCfA1e7B13b59fF207e769235", - "0xE23A1fC1545F1b072308c846a38447b23d322Ee2", - "0xF87bceab8DD37489015B426bA931e08A4D787616", - "0x19252AFD0B2F539C400aEab7d460CBFbf74c17ff", - "0x74E708A7F5486ed73CCCAe54B63e71B1988F1383", - "0xc2931B1fEa69b6D6dA65a50363A8D75d285e4da9", - "0x33942B932159A67E3274f54bC4082cbA4A704340", - "0x18995825f033F33fa30CF59c117aD21ff6BdB48c", - "0xc7be132027e191636172798B933202E0f9CAD548", - "0x9Db62c5BBc6fb79416545FcCBDB2204099217b78", - "0xF4C1B7528f8B266D8ADf1a85c91d93114FeDbA2A", - "0x3AF2bE7AbEF0f840b196D99d79F4B803a5dB14a1", - "0x20a83DE526F2CF2fCec2131E07b11F956d8f3Cdf", - "0x83F63118dcAAdAACBFF36D78ffB88dd474309e70", - "0x9f6213dFa9069a5426Fe8fAE73857712E1259Ed4", - "0x0a95088403229331FeF1EB26a11F9d6C8E73f23D", - "0x30c31bA6f4652B548fe7a142A949987c3f3Bf80b", - "0x9C5e7a3B4db931F07A6534f9e44100DDDc78c408", - "0xD5f83FCbb4a62779D0B37b9E603CD19Ad84884F0", - "0x93dff2053D4B08823d8B39F1dCdf8497f15200f4", - "0xB3A201887396F57bad3fF50DFd02022fE1Fd1774", -]; -export const XVS_STORE = "0x03B868C7858F50900fecE4eBc851199e957b5d3D"; -export const XVS_BRIDGE_ADMIN_PROXY = "0xd3c6bdeeadB2359F726aD4cF42EAa8B7102DAd9B"; -export const XVS = "0x66ebd019E86e0af5f228a0439EBB33f045CBe63E"; -export const BOUND_VALIDATOR = "0x60c4Aa92eEb6884a76b309Dd8B3731ad514d6f9B"; -export const SFrxETHOracle = "0x61EB836afA467677e6b403D504fe69D6940e7996"; - -export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; - -const vip060 = () => { - return makeProposal([ - { - target: DEFAULT_PROXY_ADMIN, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - { - target: SINGLE_TOKEN_CONVERTER_BEACON, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - { - target: CONVERTER_NETWORK, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - ...CONVERTERS.map(converter => { - return { - target: converter, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }; - }), - { - target: PRIME, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - { - target: PLP, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - ...REWARD_DISTRIBUTORS.map(rewardDistributor => { - return { - target: rewardDistributor, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }; - }), - { - target: PSR, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - { - target: COMPTROLLER_BEACON, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - { - target: VTOKEN_BEACON, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - { - target: POOL_REGISTRY, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - ...COMPTROLLERS.map(comptroller => { - return { - target: comptroller, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }; - }), - ...VTOKENS.map(comptroller => { - return { - target: comptroller, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }; - }), - { - target: sepolia.XVS_VAULT_PROXY, - signature: "_setPendingAdmin(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - { - target: XVS_STORE, - signature: "setPendingAdmin(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - { - target: XVS_BRIDGE_ADMIN_PROXY, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - { - target: XVS, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - { - target: sepolia.RESILIENT_ORACLE, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - { - target: sepolia.CHAINLINK_ORACLE, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - { - target: sepolia.REDSTONE_ORACLE, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - { - target: BOUND_VALIDATOR, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - { - target: SFrxETHOracle, - signature: "transferOwnership(address)", - params: [sepolia.NORMAL_TIMELOCK], - }, - { - target: XVS_BRIDGE_ADMIN_PROXY, - signature: "setWhitelist(address,bool)", - params: [sepolia.NORMAL_TIMELOCK, true], - }, - ]); -}; - -export default vip060; diff --git a/multisig/simulations/arbitrumone/vip-014/abi/Comptroller.json b/multisig/simulations/arbitrumone/vip-014/abi/Comptroller.json deleted file mode 100644 index f3b2445ac..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/Comptroller.json +++ /dev/null @@ -1,929 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "ActionPaused", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "BorrowCapExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "CollateralExceedsThreshold", - "type": "error" - }, - { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, - { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, - { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } - ], - "name": "InsufficientCollateral", - "type": "error" - }, - { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, - { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, - { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, - { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketAlreadyListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "MarketNotCollateral", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketNotListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "MinimalCollateralViolated", - "type": "error" - }, - { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "PriceError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "SnapshotError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "SupplyCapExceeded", - "type": "error" - }, - { "inputs": [], "name": "TooMuchRepay", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "expectedSender", "type": "address" }, - { "internalType": "address", "name": "actualSender", "type": "address" } - ], - "name": "UnexpectedSender", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, - { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } - ], - "name": "ActionPausedMarket", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "DelegateUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "IsForcedLiquidationEnabledUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketEntered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketExited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "MarketSupported", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } - ], - "name": "NewBorrowCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } - ], - "name": "NewCloseFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } - ], - "name": "NewCollateralFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } - ], - "name": "NewLiquidationIncentive", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "NewLiquidationThreshold", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } - ], - "name": "NewMinLiquidatableCollateral", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "oldPriceOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "newPriceOracle", - "type": "address" - } - ], - "name": "NewPriceOracle", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } - ], - "name": "NewRewardsDistributor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } - ], - "name": "NewSupplyCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "accountAssets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "actionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], - "name": "addRewardsDistributor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "allMarkets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "approvedDelegates", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "borrowCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "contract VToken", "name": "vToken", "type": "address" } - ], - "name": "checkMembership", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "closeFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], - "name": "enterMarkets", - "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], - "name": "exitMarket", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAssetsIn", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getBorrowingPower", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "address", "name": "vTokenModify", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "getHypotheticalAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getRewardDistributors", - "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "getRewardsByMarket", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.RewardSpeeds[]", - "name": "rewardSpeeds", - "type": "tuple[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "healAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isComptroller", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isForcedLiquidationEnabled", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "isMarketListed", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [ - { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.LiquidationOrder[]", - "name": "orders", - "type": "tuple[]" - } - ], - "name": "liquidateAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "liquidateBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } - ], - "name": "liquidateCalculateSeizeTokens", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "liquidationIncentiveMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "bool", "name": "isListed", "type": "bool" }, - { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "minLiquidatableCollateral", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } - ], - "name": "mintVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "preBorrowHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "preLiquidateHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "preMintHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "preRedeemHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preRepayHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "seizerContract", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preSeizeHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "preTransferHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } - ], - "name": "repayBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seizeVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, - { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, - { "internalType": "bool", "name": "paused", "type": "bool" } - ], - "name": "setActionsPaused", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], - "name": "setCloseFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "setCollateralFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "setForcedLiquidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], - "name": "setLiquidationIncentive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } - ], - "name": "setMarketBorrowCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } - ], - "name": "setMarketSupplyCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], - "name": "setMinLiquidatableCollateral", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "supplyCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "supportMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "transferVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "delegate", "type": "address" }, - { "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "updateDelegate", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "updatePrices", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/ComptrollerBeacon.json b/multisig/simulations/arbitrumone/vip-014/abi/ComptrollerBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/ComptrollerBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/DefaultProxyAdmin.json b/multisig/simulations/arbitrumone/vip-014/abi/DefaultProxyAdmin.json deleted file mode 100644 index 9801cfcc7..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/DefaultProxyAdmin.json +++ /dev/null @@ -1,76 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "changeProxyAdmin", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" } - ], - "name": "upgrade", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" }, - { "internalType": "bytes", "name": "data", "type": "bytes" } - ], - "name": "upgradeAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/PoolRegistry.json b/multisig/simulations/arbitrumone/vip-014/abi/PoolRegistry.json deleted file mode 100644 index 31b1e2a17..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/PoolRegistry.json +++ /dev/null @@ -1,379 +0,0 @@ -[ - { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, - { - "name": "Unauthorized", - "type": "error", - "inputs": [ - { "name": "sender", "type": "address", "internalType": "address" }, - { "name": "calledContract", "type": "address", "internalType": "address" }, - { "name": "methodSignature", "type": "string", "internalType": "string" } - ] - }, - { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, - { - "name": "Initialized", - "type": "event", - "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], - "anonymous": false, - "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" - }, - { - "name": "MarketAdded", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" - }, - { - "name": "NewAccessControlManager", - "type": "event", - "inputs": [ - { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, - { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" - }, - { - "name": "OwnershipTransferStarted", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" - }, - { - "name": "OwnershipTransferred", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" - }, - { - "name": "PoolMetadataUpdated", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "oldMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - }, - { - "name": "newMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "anonymous": false, - "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" - }, - { - "name": "PoolNameSet", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, - { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } - ], - "anonymous": false, - "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" - }, - { - "name": "PoolRegistered", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "pool", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "anonymous": false, - "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" - }, - { - "name": "acceptOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x79ba5097", - "stateMutability": "nonpayable" - }, - { - "name": "accessControlManager", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "contract IAccessControlManagerV8" - } - ], - "constant": true, - "signature": "0xb4a0bdf3", - "stateMutability": "view" - }, - { - "name": "addMarket", - "type": "function", - "inputs": [ - { - "name": "input", - "type": "tuple", - "components": [ - { "name": "vToken", "type": "address", "internalType": "contract VToken" }, - { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, - { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, - { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, - { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, - { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistry.AddMarketInput" - } - ], - "outputs": [], - "signature": "0x23dc8d64", - "stateMutability": "nonpayable" - }, - { - "name": "addPool", - "type": "function", - "inputs": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, - { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, - { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } - ], - "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], - "signature": "0xeed873c2", - "stateMutability": "nonpayable" - }, - { - "name": "getAllPools", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "tuple[]", - "value": [], - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool[]" - } - ], - "constant": true, - "signature": "0xd88ff1f4", - "stateMutability": "view" - }, - { - "name": "getPoolByComptroller", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "constant": true, - "signature": "0x7aee632d", - "stateMutability": "view" - }, - { - "name": "getPoolsSupportedByAsset", - "type": "function", - "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], - "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], - "constant": true, - "signature": "0xf36dba38", - "stateMutability": "view" - }, - { - "name": "getVTokenForAsset", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "asset", "type": "address", "internalType": "address" } - ], - "outputs": [{ "name": "", "type": "address", "internalType": "address" }], - "constant": true, - "signature": "0x266e0a7f", - "stateMutability": "view" - }, - { - "name": "getVenusPoolMetadata", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "constant": true, - "signature": "0xa3aefa2c", - "stateMutability": "view" - }, - { - "name": "initialize", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xc4d66de8", - "stateMutability": "nonpayable" - }, - { - "name": "metadata", - "type": "function", - "inputs": [{ "name": "", "type": "address", "internalType": "address" }], - "outputs": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "constant": true, - "signature": "0x2ba21572", - "stateMutability": "view" - }, - { - "name": "owner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x8da5cb5b", - "stateMutability": "view" - }, - { - "name": "pendingOwner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0xe30c3978", - "stateMutability": "view" - }, - { - "name": "renounceOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x715018a6", - "stateMutability": "nonpayable" - }, - { - "name": "setAccessControlManager", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0x0e32cb86", - "stateMutability": "nonpayable" - }, - { - "name": "setPoolName", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "name", "type": "string", "internalType": "string" } - ], - "outputs": [], - "signature": "0x1cb6bb7e", - "stateMutability": "nonpayable" - }, - { - "name": "transferOwnership", - "type": "function", - "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xf2fde38b", - "stateMutability": "nonpayable" - }, - { - "name": "updatePoolMetadata", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { - "name": "metadata_", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "outputs": [], - "signature": "0xff94d958", - "stateMutability": "nonpayable" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/Prime.json b/multisig/simulations/arbitrumone/vip-014/abi/Prime.json deleted file mode 100644 index e8bfa99ff..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/Prime.json +++ /dev/null @@ -1,763 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, - { "internalType": "address", "name": "_nativeMarket", "type": "address" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, - { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, - { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, - { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, - { "internalType": "bool", "name": "_timeBased", "type": "bool" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, - { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidComptroller", "type": "error" }, - { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "n", "type": "uint256" }, - { "internalType": "uint256", "name": "d", "type": "uint256" } - ], - "name": "InvalidFraction", - "type": "error" - }, - { "inputs": [], "name": "InvalidLength", "type": "error" }, - { "inputs": [], "name": "InvalidLimit", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, - { "inputs": [], "name": "InvalidVToken", "type": "error" }, - { - "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], - "name": "LnNonRealResult", - "type": "error" - }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, - { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, - { "inputs": [], "name": "MarketNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, - { "inputs": [], "name": "WaitMoreTime", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, - { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } - ], - "name": "AlphaUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "Burn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "InterestClaimed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "MarketAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } - ], - "name": "MintLimitsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } - ], - "name": "MultiplierUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } - ], - "name": "StakedAtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "TokenUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "UserScoreUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "MAXIMUM_XVS_CAP", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MINIMUM_STAKED_XVS", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_MARKET", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "STAKING_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WRAPPED_NATIVE_TOKEN", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "accrueInterest", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" } - ], - "name": "accrueInterestAndUpdateScore", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "addMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "alphaDenominator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "alphaNumerator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "calculateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "claimTimeRemaining", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "uint256", "name": "borrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supply", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } - ], - "name": "estimateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "getInterestAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "getPendingRewards", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "internalType": "struct PrimeStorageV1.PendingReward[]", - "name": "pendingRewards", - "type": "tuple[]" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "incomeDistributionYearly", - "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "xvsVault_", "type": "address" }, - { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, - { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, - { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, - { "internalType": "address", "name": "comptroller_", "type": "address" }, - { "internalType": "address", "name": "oracle_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "name": "initializeV2", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "interests", - "outputs": [ - { "internalType": "uint256", "name": "accrued", "type": "uint256" }, - { "internalType": "uint256", "name": "score", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "irrevocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "", "type": "uint256" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "isScoreUpdated", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "isUserPrimeHolder", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, - { "internalType": "address[]", "name": "users", "type": "address[]" } - ], - "name": "issue", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, - { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, - { "internalType": "bool", "name": "exists", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "nextScoreUpdateRoundId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingScoreUpdates", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "primeLiquidityProvider", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "revocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } - ], - "name": "setLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "users", "type": "address[]" }, - { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } - ], - "name": "setStakedAt", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "stakedAt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokens", - "outputs": [ - { "internalType": "bool", "name": "exists", "type": "bool" }, - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalIrrevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalRevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalScoreUpdatesRequired", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "unreleasedPLPIncome", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, - { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } - ], - "name": "updateAlpha", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "updateMultipliers", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], - "name": "updateScores", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "vTokenForAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "xvsUpdated", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVault", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultPoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/PrimeLiquidityProvider.json b/multisig/simulations/arbitrumone/vip-014/abi/PrimeLiquidityProvider.json deleted file mode 100644 index 02ca8e0bf..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/PrimeLiquidityProvider.json +++ /dev/null @@ -1,385 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "_timeBased", "type": "bool" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, - { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "balance", "type": "uint256" } - ], - "name": "InsufficientBalance", - "type": "error" - }, - { "inputs": [], "name": "InvalidArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidCaller", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "speed", "type": "uint256" }, - { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } - ], - "name": "InvalidDistributionSpeed", - "type": "error" - }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenAlreadyInitialized", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "TokenNotInitialized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "MaxTokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } - ], - "name": "PrimeTokenUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenDistributionInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "TokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokenTransferredToPrime", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokensAccrued", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "accrueTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "getEffectiveDistributionSpeed", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], - "name": "initializeTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "lastAccruedBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastAccruedBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "maxTokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } - ], - "name": "setMaxTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } - ], - "name": "setTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, - { "internalType": "address", "name": "to_", "type": "address" }, - { "internalType": "uint256", "name": "amount_", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "tokenAmountAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/ProtocolShareReserve.json b/multisig/simulations/arbitrumone/vip-014/abi/ProtocolShareReserve.json deleted file mode 100644 index b33d7c495..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/ProtocolShareReserve.json +++ /dev/null @@ -1,356 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, - { "internalType": "address", "name": "_wbnb", "type": "address" }, - { "internalType": "address", "name": "_vbnb", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetReleased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IProtocolShareReserve.IncomeType", - "name": "incomeType", - "type": "uint8" - }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "AssetsReservesUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } - ], - "name": "PoolRegistryUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "ReservesUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "CORE_POOL_COMPTROLLER", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MAX_PERCENT", - "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "internalType": "struct ProtocolShareReserve.DistributionConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "addOrUpdateDistributionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } - ], - "name": "assetsReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "distributionTargets", - "outputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "getPercentageDistribution", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "getUnreleasedFunds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address[]", "name": "assets", "type": "address[]" } - ], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "name": "removeDistributionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], - "name": "setPoolRegistry", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAssetReserve", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalDistributions", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/RewardDistrbutor.json b/multisig/simulations/arbitrumone/vip-014/abi/RewardDistrbutor.json deleted file mode 100644 index 249fdd111..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/RewardDistrbutor.json +++ /dev/null @@ -1,532 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "BorrowLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "BorrowLastRewardingBlockUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "ContributorRewardTokenSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } - ], - "name": "ContributorRewardsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } - ], - "name": "DistributedBorrowerRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } - ], - "name": "DistributedSupplierRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "MarketInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "indexed": false, - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "RewardTokenBorrowIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenBorrowSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RewardTokenGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "RewardTokenSupplyIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenSupplySpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "SupplyLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "SupplyLastRewardingBlockUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "INITIAL_INDEX", - "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "holder", "type": "address" }, - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } - ], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "distributeBorrowerRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "supplier", "type": "address" } - ], - "name": "distributeSupplierRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "recipient", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "grantRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, - { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "initializeMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastContributorBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "rewardToken", - "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenBorrowerIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenContributorSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenSupplierIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplySpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contributor", "type": "address" }, - { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } - ], - "name": "setContributorRewardTokenSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } - ], - "name": "setLastRewardingBlockTimestamps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, - { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } - ], - "name": "setLastRewardingBlocks", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } - ], - "name": "setRewardTokenSpeeds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], - "name": "updateContributorRewards", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "updateRewardTokenBorrowIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "updateRewardTokenSupplyIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/VToken.json b/multisig/simulations/arbitrumone/vip-014/abi/VToken.json deleted file mode 100644 index d8cc1aae4..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/VToken.json +++ /dev/null @@ -1,861 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], - "name": "AddReservesFactorFreshCheck", - "type": "error" - }, - { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, - { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, - { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], - "name": "LiquidateAccrueCollateralInterestFailed", - "type": "error" - }, - { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, - { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, - { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, - { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, - { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, - { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, - { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "AccrueInterest", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtRecovered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "Borrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "HealBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "LiquidateBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } - ], - "name": "NewComptroller", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "oldInterestRateModel", - "type": "address" - }, - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "newInterestRateModel", - "type": "address" - } - ], - "name": "NewMarketInterestRateModel", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } - ], - "name": "NewProtocolSeizeShare", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } - ], - "name": "NewProtocolShareReserve", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } - ], - "name": "NewReduceReservesBlockDelta", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } - ], - "name": "NewReserveFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } - ], - "name": "NewShortfallContract", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ProtocolSeize", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Redeem", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "RepayBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "ReservesAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "SpreadReservesReduced", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Transfer", - "type": "event" - }, - { - "inputs": [], - "name": "NO_ERROR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrualBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrueInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], - "name": "addReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "owner", "type": "address" }, - { "internalType": "address", "name": "spender", "type": "address" } - ], - "name": "allowance", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "approve", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "badDebt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], - "name": "badDebtRecovered", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOfUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], - "name": "borrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "borrowIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "borrowRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } - ], - "name": "decreaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "forceLiquidateBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountSnapshot", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCash", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "healBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "addedValue", "type": "uint256" } - ], - "name": "increaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "underlying_", "type": "address" }, - { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, - { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, - { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, - { "internalType": "string", "name": "name_", "type": "string" }, - { "internalType": "string", "name": "symbol_", "type": "string" }, - { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, - { "internalType": "address", "name": "admin_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { - "components": [ - { "internalType": "address", "name": "shortfall", "type": "address" }, - { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } - ], - "internalType": "struct VTokenInterface.RiskManagementInit", - "name": "riskManagement", - "type": "tuple" - }, - { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "interestRateModel", - "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isVToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } - ], - "name": "liquidateBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], - "name": "mint", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "mintBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolSeizeShareMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolShareReserve", - "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], - "name": "redeem", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], - "name": "redeemUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } - ], - "name": "redeemUnderlyingBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], - "name": "reduceReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockDelta", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], - "name": "repayBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "repayBorrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reserveFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], - "name": "setInterestRateModel", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], - "name": "setProtocolSeizeShare", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], - "name": "setProtocolShareReserve", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], - "name": "setReduceReservesBlockDelta", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], - "name": "setReserveFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], - "name": "setShortfallContract", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "shortfall", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "supplyRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrows", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrowsCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "totalReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transfer", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transferFrom", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "underlying", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/VTokenBeacon.json b/multisig/simulations/arbitrumone/vip-014/abi/VTokenBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/VTokenBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/XVSStore.json b/multisig/simulations/arbitrumone/vip-014/abi/XVSStore.json deleted file mode 100644 index 2d9ea2bb2..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/XVSStore.json +++ /dev/null @@ -1,130 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "AdminTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } - ], - "name": "NewPendingAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnerTransferred", - "type": "event" - }, - { - "constant": false, - "inputs": [], - "name": "acceptAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "emergencyRewardWithdraw", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokens", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "token", "type": "address" }, - { "internalType": "address", "name": "_to", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "safeRewardTransfer", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], - "name": "setNewOwner", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], - "name": "setPendingAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "bool", "name": "status", "type": "bool" } - ], - "name": "setRewardToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/XVSVault.json b/multisig/simulations/arbitrumone/vip-014/abi/XVSVault.json deleted file mode 100644 index 51d8d540c..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/XVSVault.json +++ /dev/null @@ -1,787 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Claim", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } - ], - "name": "DelegateChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "DelegateVotesChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Deposit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ExecutedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "name": "PoolAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } - ], - "name": "PoolUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RequestedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } - ], - "name": "RewardAmountUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } - ], - "name": "StoreUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } - ], - "name": "VaultDebtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } - ], - "name": "WithdrawalLockingPeriodUpdated", - "type": "event" - }, - { - "constant": true, - "inputs": [], - "name": "DELEGATION_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "DOMAIN_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "MAX_LOCK_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "SECONDS_PER_YEAR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], - "name": "_become", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, - { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, - { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } - ], - "name": "add", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint32", "name": "", "type": "uint32" } - ], - "name": "checkpoints", - "outputs": [ - { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, - { "internalType": "uint96", "name": "votes", "type": "uint96" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_account", "type": "address" }, - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "claim", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], - "name": "delegate", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "delegatee", "type": "address" }, - { "internalType": "uint256", "name": "nonce", "type": "uint256" }, - { "internalType": "uint256", "name": "expiry", "type": "uint256" }, - { "internalType": "uint8", "name": "v", "type": "uint8" }, - { "internalType": "bytes32", "name": "r", "type": "bytes32" }, - { "internalType": "bytes32", "name": "s", "type": "bytes32" } - ], - "name": "delegateBySig", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "delegates", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "deposit", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "executeWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getCurrentVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getEligibleWithdrawalAmount", - "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } - ], - "name": "getPriorVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getRequestedAmount", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getUserInfo", - "outputs": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, - { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getWithdrawalRequests", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, - { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } - ], - "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", - "name": "", - "type": "tuple[]" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "name": "initializeTimeManager", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isStakedToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "nonces", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "numCheckpoints", - "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "pause", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingReward", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "pendingRewardTransfers", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingWithdrawalsBeforeUpgrade", - "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingXVSVaultImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "poolInfos", - "outputs": [ - { "internalType": "contract IBEP20", "name": "token", "type": "address" }, - { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, - { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], - "name": "poolLength", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primePoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeToken", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "requestWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "resume", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], - "name": "rewardTokenAmountsPerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAmountsPerBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } - ], - "name": "set", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], - "name": "setAccessControl", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, - { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } - ], - "name": "setPrimeToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } - ], - "name": "setRewardAmountPerBlockOrSecond", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } - ], - "name": "setWithdrawalLockingPeriod", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_xvs", "type": "address" }, - { "internalType": "address", "name": "_xvsStore", "type": "address" } - ], - "name": "setXvsStore", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAllocPoints", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "totalPendingWithdrawals", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "updatePool", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "vaultPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsStore", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/boundValidator.json b/multisig/simulations/arbitrumone/vip-014/abi/boundValidator.json deleted file mode 100644 index d16c8fb08..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/boundValidator.json +++ /dev/null @@ -1,498 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "previousAdmin", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAdmin", - "type": "address" - } - ], - "name": "AdminChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "beacon", - "type": "address" - } - ], - "name": "BeaconUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "implementation", - "type": "address" - } - ], - "name": "Upgraded", - "type": "event" - }, - { - "stateMutability": "payable", - "type": "fallback" - }, - { - "inputs": [], - "name": "admin", - "outputs": [ - { - "internalType": "address", - "name": "admin_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [ - { - "internalType": "address", - "name": "implementation_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - } - ], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - }, - { - "internalType": "bytes", - "name": "data", - "type": "bytes" - } - ], - "name": "upgradeToAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "upperBound", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "lowerBound", - "type": "uint256" - } - ], - "name": "ValidateConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig", - "name": "config", - "type": "tuple" - } - ], - "name": "setValidateConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "setValidateConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "validateConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "reportedPrice", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "anchorPrice", - "type": "uint256" - } - ], - "name": "validatePriceWithAnchorPrice", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_logic", - "type": "address" - }, - { - "internalType": "address", - "name": "admin_", - "type": "address" - }, - { - "internalType": "bytes", - "name": "_data", - "type": "bytes" - } - ], - "stateMutability": "payable", - "type": "constructor" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/chainlinkOracle.json b/multisig/simulations/arbitrumone/vip-014/abi/chainlinkOracle.json deleted file mode 100644 index cdd689acb..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/chainlinkOracle.json +++ /dev/null @@ -1,459 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "vBnbAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "previousPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "requestedPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newPriceMantissa", - "type": "uint256" - } - ], - "name": "PricePosted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManager", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "prices", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - } - ], - "name": "setDirectPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VBep20Interface", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "underlyingPriceMantissa", - "type": "uint256" - } - ], - "name": "setUnderlyingPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "tokenConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/resilientOracle.json b/multisig/simulations/arbitrumone/vip-014/abi/resilientOracle.json deleted file mode 100644 index 35f52caa0..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/resilientOracle.json +++ /dev/null @@ -1,640 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "nativeMarketAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - }, - { - "internalType": "contract BoundValidatorInterface", - "name": "_boundValidator", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "OracleEnabled", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - } - ], - "name": "OracleSet", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "mainOracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "pivotOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "fallbackOracle", - "type": "address" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "INVALID_PRICE", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_TOKEN_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "boundValidator", - "outputs": [ - { - "internalType": "contract BoundValidatorInterface", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - }, - { - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "enableOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "getOracle", - "outputs": [ - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "bool", - "name": "enabled", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getTokenConfig", - "outputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "nativeMarket", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "setOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "updateAssetPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "updatePrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/treasury.json b/multisig/simulations/arbitrumone/vip-014/abi/treasury.json deleted file mode 100644 index 18aabb61a..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/treasury.json +++ /dev/null @@ -1,86 +0,0 @@ -[ - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryNative", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryToken", - "type": "event" - }, - { "stateMutability": "payable", "type": "fallback" }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryNative", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "stateMutability": "payable", "type": "receive" } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/xvs.json b/multisig/simulations/arbitrumone/vip-014/abi/xvs.json deleted file mode 100644 index 69092bb4a..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/xvs.json +++ /dev/null @@ -1,716 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user", - "type": "address" - } - ], - "name": "AccountBlacklisted", - "type": "error" - }, - { - "inputs": [], - "name": "AddressesMustDiffer", - "type": "error" - }, - { - "inputs": [], - "name": "MintLimitExceed", - "type": "error" - }, - { - "inputs": [], - "name": "MintedAmountExceed", - "type": "error" - }, - { - "inputs": [], - "name": "NewCapNotGreaterThanMintedTokens", - "type": "error" - }, - { - "inputs": [], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "user", - "type": "address" - }, - { - "indexed": false, - "internalType": "bool", - "name": "value", - "type": "bool" - } - ], - "name": "BlacklistUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "MintCapChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitDecreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "source", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "destination", - "type": "address" - } - ], - "name": "MintedTokensMigrated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Transfer", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "internalType": "address", - "name": "spender", - "type": "address" - } - ], - "name": "allowance", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "approve", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [ - { - "internalType": "uint8", - "name": "", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "subtractedValue", - "type": "uint256" - } - ], - "name": "decreaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "addedValue", - "type": "uint256" - } - ], - "name": "increaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - } - ], - "name": "isBlackListed", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "source_", - "type": "address" - }, - { - "internalType": "address", - "name": "destination_", - "type": "address" - } - ], - "name": "migrateMinterTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "mint", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToCap", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToMintedAmount", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newAccessControlAddress_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "minter_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "setMintCap", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transfer", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transferFrom", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - }, - { - "internalType": "bool", - "name": "value_", - "type": "bool" - } - ], - "name": "updateBlacklist", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/abi/xvsBridgeAdmin.json b/multisig/simulations/arbitrumone/vip-014/abi/xvsBridgeAdmin.json deleted file mode 100644 index 024450a40..000000000 --- a/multisig/simulations/arbitrumone/vip-014/abi/xvsBridgeAdmin.json +++ /dev/null @@ -1,329 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "XVSBridge_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "string", - "name": "signature", - "type": "string" - }, - { - "indexed": false, - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "name": "FunctionRegistryChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "stateMutability": "nonpayable", - "type": "fallback" - }, - { - "inputs": [], - "name": "XVSBridge", - "outputs": [ - { - "internalType": "contract IXVSProxyOFT", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes4", - "name": "", - "type": "bytes4" - } - ], - "name": "functionRegistry", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "isTrustedRemote", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner_", - "type": "address" - } - ], - "name": "transferBridgeOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "string[]", - "name": "signatures_", - "type": "string[]" - }, - { - "internalType": "bool[]", - "name": "active_", - "type": "bool[]" - } - ], - "name": "upsertSignature", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumone/vip-014/index.ts b/multisig/simulations/arbitrumone/vip-014/index.ts deleted file mode 100644 index d96e62355..000000000 --- a/multisig/simulations/arbitrumone/vip-014/index.ts +++ /dev/null @@ -1,225 +0,0 @@ -import { expect } from "chai"; -import { Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip } from "src/vip-framework"; - -import vip014, { - BOUND_VALIDATOR, - COMPTROLLERS, - COMPTROLLER_BEACON, - DEFAULT_PROXY_ADMIN, - PLP, - PRIME, - PSR, - REWARD_DISTRIBUTORS, - VTOKENS, - VTOKEN_BEACON, - XVS, - XVS_BRIDGE_ADMIN_PROXY, - XVS_STORE, -} from "../../../proposals/arbitrumone/vip-014"; -import COMPTROLLER_ABI from "./abi/Comptroller.json"; -import COMPTROLLER_BEACON_ABI from "./abi/ComptrollerBeacon.json"; -import DEFAULT_PROXY_ADMIN_ABI from "./abi/DefaultProxyAdmin.json"; -import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; -import PRIME_ABI from "./abi/Prime.json"; -import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; -import PSR_ABI from "./abi/ProtocolShareReserve.json"; -import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistrbutor.json"; -import VTOKEN_ABI from "./abi/VToken.json"; -import VTOKEN_BEACON_ABI from "./abi/VTokenBeacon.json"; -import XVS_STORE_ABI from "./abi/XVSStore.json"; -import XVS_VAULT_ABI from "./abi/XVSVault.json"; -import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; -import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; -import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; -import TREASURY_ABI from "./abi/treasury.json"; -import XVS_ABI from "./abi/xvs.json"; -import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; - -const { arbitrumone } = NETWORK_ADDRESSES; - -const RESILIENT_ORACLE = arbitrumone.RESILIENT_ORACLE; -const CHAINLINK_ORACLE = arbitrumone.CHAINLINK_ORACLE; -const REDSTONE_ORACLE = arbitrumone.REDSTONE_ORACLE; -const NORMAL_TIMELOCK = arbitrumone.NORMAL_TIMELOCK; - -forking(241039405, async () => { - const provider = ethers.provider; - let proxyAdmin: Contract; - let prime: Contract; - let plp: Contract; - let psr: Contract; - let comptrollerBeacon: Contract; - let vTokenBeacon: Contract; - let poolRegistry: Contract; - let xvsVault: Contract; - let xvsStore: Contract; - let xvs: Contract; - let xvsBridgeAdmin: Contract; - let resilientOracle: Contract; - let chainLinkOracle: Contract; - let redstoneOracle: Contract; - let boundValidator: Contract; - let treasury: Contract; - - describe("Pre-VIP behavior", async () => { - before(async () => { - proxyAdmin = new ethers.Contract(DEFAULT_PROXY_ADMIN, DEFAULT_PROXY_ADMIN_ABI, provider); - prime = new ethers.Contract(PRIME, PRIME_ABI, provider); - plp = new ethers.Contract(PLP, PLP_ABI, provider); - psr = new ethers.Contract(PSR, PSR_ABI, provider); - comptrollerBeacon = new ethers.Contract(COMPTROLLER_BEACON, COMPTROLLER_BEACON_ABI, provider); - vTokenBeacon = new ethers.Contract(VTOKEN_BEACON, VTOKEN_BEACON_ABI, provider); - poolRegistry = new ethers.Contract(arbitrumone.POOL_REGISTRY, POOL_REGISTRY_ABI, provider); - xvsVault = new ethers.Contract(arbitrumone.XVS_VAULT_PROXY, XVS_VAULT_ABI, provider); - xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); - xvs = await ethers.getContractAt(XVS_ABI, XVS); - xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, XVS_BRIDGE_ADMIN_PROXY); - resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); - chainLinkOracle = new ethers.Contract(CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); - redstoneOracle = new ethers.Contract(REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); - boundValidator = new ethers.Contract(BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); - treasury = await ethers.getContractAt(TREASURY_ABI, NETWORK_ADDRESSES.arbitrumone.VTREASURY); - }); - - it("owner of proxy admin is guardian", async () => { - expect(await proxyAdmin.owner()).to.equal(arbitrumone.GUARDIAN); - }); - it("pending owner", async () => { - expect(await prime.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await plp.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - - for (const rewardDistributor of REWARD_DISTRIBUTORS) { - it(`should have no pending owner for ${rewardDistributor}`, async () => { - const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - it("pending owner of psr", async () => { - expect(await psr.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`should have no pending owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`should have no pending owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - it("owner of ComptrollerBeacon is guardian", async () => { - expect(await comptrollerBeacon.owner()).to.equal(arbitrumone.GUARDIAN); - }); - - it("owner of VTokenBeacon is guardian", async () => { - expect(await vTokenBeacon.owner()).to.equal(arbitrumone.GUARDIAN); - }); - - it("pending owner of PoolRegistry", async () => { - expect(await poolRegistry.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - it("should have no pending owner", async () => { - expect(await xvsVault.pendingAdmin()).to.equal(ethers.constants.AddressZero); - }); - - it("should have no pending owner", async () => { - expect(await xvsStore.pendingAdmin()).to.equal(ethers.constants.AddressZero); - }); - - it("should have no pending owner", async () => { - expect(await resilientOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await chainLinkOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await redstoneOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await boundValidator.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - }); - - describe("Post-VIP behavior", async () => { - before(async () => { - await pretendExecutingVip(await vip014()); - }); - - it("owner of proxy admin is timelock", async () => { - expect(await proxyAdmin.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); - }); - - it("pending owner", async () => { - expect(await prime.pendingOwner()).to.equal(arbitrumone.NORMAL_TIMELOCK); - expect(await plp.pendingOwner()).to.equal(arbitrumone.NORMAL_TIMELOCK); - }); - - for (const rewardDistributor of REWARD_DISTRIBUTORS) { - it(`should have Normal Timelock as pending owner for ${rewardDistributor}`, async () => { - const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); - expect(await c.pendingOwner()).to.equal(arbitrumone.NORMAL_TIMELOCK); - }); - } - - it("pending owner of psr", async () => { - expect(await psr.pendingOwner()).to.equal(arbitrumone.NORMAL_TIMELOCK); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`correct pending owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.pendingOwner()).to.equal(arbitrumone.NORMAL_TIMELOCK); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`correct pending owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.pendingOwner()).to.equal(arbitrumone.NORMAL_TIMELOCK); - }); - } - - it("owner of ComptrollerBeacon is NT", async () => { - expect(await comptrollerBeacon.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); - }); - - it("owner of VTokenBeacon is NT", async () => { - expect(await vTokenBeacon.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); - }); - - it("pending owner of PoolRegistry is NT", async () => { - expect(await poolRegistry.pendingOwner()).to.equal(arbitrumone.NORMAL_TIMELOCK); - }); - - it("correct pending owner", async () => { - expect(await xvsVault.pendingAdmin()).to.equal(NORMAL_TIMELOCK); - }); - - it("correct pending owner", async () => { - expect(await xvsStore.pendingAdmin()).to.equal(NORMAL_TIMELOCK); - }); - - it("Should set bridge pending owner to Normal Timelock", async () => { - const pendingOwner = await xvsBridgeAdmin.pendingOwner(); - expect(pendingOwner).equals(arbitrumone.NORMAL_TIMELOCK); - }); - it("Should set XVS owner to Normal Timelock", async () => { - const owner = await xvs.owner(); - expect(owner).equals(arbitrumone.NORMAL_TIMELOCK); - }); - it("correct pending owner", async () => { - expect(await resilientOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); - expect(await chainLinkOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); - expect(await redstoneOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); - expect(await boundValidator.pendingOwner()).to.equal(NORMAL_TIMELOCK); - }); - it("Should set pendingOwner to Normal Timelock", async () => { - const pendingOwner = await treasury.pendingOwner(); - expect(pendingOwner).equals(NETWORK_ADDRESSES.arbitrumone.NORMAL_TIMELOCK); - }); - }); -}); diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/Comptroller.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/Comptroller.json deleted file mode 100644 index f3b2445ac..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/Comptroller.json +++ /dev/null @@ -1,929 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "ActionPaused", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "BorrowCapExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "CollateralExceedsThreshold", - "type": "error" - }, - { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, - { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, - { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } - ], - "name": "InsufficientCollateral", - "type": "error" - }, - { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, - { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, - { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, - { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketAlreadyListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "MarketNotCollateral", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketNotListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "MinimalCollateralViolated", - "type": "error" - }, - { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "PriceError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "SnapshotError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "SupplyCapExceeded", - "type": "error" - }, - { "inputs": [], "name": "TooMuchRepay", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "expectedSender", "type": "address" }, - { "internalType": "address", "name": "actualSender", "type": "address" } - ], - "name": "UnexpectedSender", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, - { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } - ], - "name": "ActionPausedMarket", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "DelegateUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "IsForcedLiquidationEnabledUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketEntered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketExited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "MarketSupported", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } - ], - "name": "NewBorrowCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } - ], - "name": "NewCloseFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } - ], - "name": "NewCollateralFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } - ], - "name": "NewLiquidationIncentive", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "NewLiquidationThreshold", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } - ], - "name": "NewMinLiquidatableCollateral", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "oldPriceOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "newPriceOracle", - "type": "address" - } - ], - "name": "NewPriceOracle", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } - ], - "name": "NewRewardsDistributor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } - ], - "name": "NewSupplyCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "accountAssets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "actionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], - "name": "addRewardsDistributor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "allMarkets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "approvedDelegates", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "borrowCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "contract VToken", "name": "vToken", "type": "address" } - ], - "name": "checkMembership", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "closeFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], - "name": "enterMarkets", - "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], - "name": "exitMarket", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAssetsIn", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getBorrowingPower", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "address", "name": "vTokenModify", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "getHypotheticalAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getRewardDistributors", - "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "getRewardsByMarket", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.RewardSpeeds[]", - "name": "rewardSpeeds", - "type": "tuple[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "healAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isComptroller", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isForcedLiquidationEnabled", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "isMarketListed", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [ - { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.LiquidationOrder[]", - "name": "orders", - "type": "tuple[]" - } - ], - "name": "liquidateAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "liquidateBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } - ], - "name": "liquidateCalculateSeizeTokens", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "liquidationIncentiveMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "bool", "name": "isListed", "type": "bool" }, - { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "minLiquidatableCollateral", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } - ], - "name": "mintVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "preBorrowHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "preLiquidateHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "preMintHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "preRedeemHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preRepayHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "seizerContract", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preSeizeHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "preTransferHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } - ], - "name": "repayBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seizeVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, - { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, - { "internalType": "bool", "name": "paused", "type": "bool" } - ], - "name": "setActionsPaused", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], - "name": "setCloseFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "setCollateralFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "setForcedLiquidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], - "name": "setLiquidationIncentive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } - ], - "name": "setMarketBorrowCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } - ], - "name": "setMarketSupplyCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], - "name": "setMinLiquidatableCollateral", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "supplyCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "supportMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "transferVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "delegate", "type": "address" }, - { "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "updateDelegate", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "updatePrices", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/ComptrollerBeacon.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/ComptrollerBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/ComptrollerBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/DefaultProxyAdmin.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/DefaultProxyAdmin.json deleted file mode 100644 index 9801cfcc7..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/DefaultProxyAdmin.json +++ /dev/null @@ -1,76 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "changeProxyAdmin", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" } - ], - "name": "upgrade", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" }, - { "internalType": "bytes", "name": "data", "type": "bytes" } - ], - "name": "upgradeAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/PoolRegistry.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/PoolRegistry.json deleted file mode 100644 index 31b1e2a17..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/PoolRegistry.json +++ /dev/null @@ -1,379 +0,0 @@ -[ - { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, - { - "name": "Unauthorized", - "type": "error", - "inputs": [ - { "name": "sender", "type": "address", "internalType": "address" }, - { "name": "calledContract", "type": "address", "internalType": "address" }, - { "name": "methodSignature", "type": "string", "internalType": "string" } - ] - }, - { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, - { - "name": "Initialized", - "type": "event", - "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], - "anonymous": false, - "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" - }, - { - "name": "MarketAdded", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" - }, - { - "name": "NewAccessControlManager", - "type": "event", - "inputs": [ - { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, - { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" - }, - { - "name": "OwnershipTransferStarted", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" - }, - { - "name": "OwnershipTransferred", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" - }, - { - "name": "PoolMetadataUpdated", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "oldMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - }, - { - "name": "newMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "anonymous": false, - "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" - }, - { - "name": "PoolNameSet", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, - { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } - ], - "anonymous": false, - "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" - }, - { - "name": "PoolRegistered", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "pool", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "anonymous": false, - "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" - }, - { - "name": "acceptOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x79ba5097", - "stateMutability": "nonpayable" - }, - { - "name": "accessControlManager", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "contract IAccessControlManagerV8" - } - ], - "constant": true, - "signature": "0xb4a0bdf3", - "stateMutability": "view" - }, - { - "name": "addMarket", - "type": "function", - "inputs": [ - { - "name": "input", - "type": "tuple", - "components": [ - { "name": "vToken", "type": "address", "internalType": "contract VToken" }, - { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, - { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, - { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, - { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, - { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistry.AddMarketInput" - } - ], - "outputs": [], - "signature": "0x23dc8d64", - "stateMutability": "nonpayable" - }, - { - "name": "addPool", - "type": "function", - "inputs": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, - { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, - { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } - ], - "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], - "signature": "0xeed873c2", - "stateMutability": "nonpayable" - }, - { - "name": "getAllPools", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "tuple[]", - "value": [], - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool[]" - } - ], - "constant": true, - "signature": "0xd88ff1f4", - "stateMutability": "view" - }, - { - "name": "getPoolByComptroller", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "constant": true, - "signature": "0x7aee632d", - "stateMutability": "view" - }, - { - "name": "getPoolsSupportedByAsset", - "type": "function", - "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], - "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], - "constant": true, - "signature": "0xf36dba38", - "stateMutability": "view" - }, - { - "name": "getVTokenForAsset", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "asset", "type": "address", "internalType": "address" } - ], - "outputs": [{ "name": "", "type": "address", "internalType": "address" }], - "constant": true, - "signature": "0x266e0a7f", - "stateMutability": "view" - }, - { - "name": "getVenusPoolMetadata", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "constant": true, - "signature": "0xa3aefa2c", - "stateMutability": "view" - }, - { - "name": "initialize", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xc4d66de8", - "stateMutability": "nonpayable" - }, - { - "name": "metadata", - "type": "function", - "inputs": [{ "name": "", "type": "address", "internalType": "address" }], - "outputs": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "constant": true, - "signature": "0x2ba21572", - "stateMutability": "view" - }, - { - "name": "owner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x8da5cb5b", - "stateMutability": "view" - }, - { - "name": "pendingOwner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0xe30c3978", - "stateMutability": "view" - }, - { - "name": "renounceOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x715018a6", - "stateMutability": "nonpayable" - }, - { - "name": "setAccessControlManager", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0x0e32cb86", - "stateMutability": "nonpayable" - }, - { - "name": "setPoolName", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "name", "type": "string", "internalType": "string" } - ], - "outputs": [], - "signature": "0x1cb6bb7e", - "stateMutability": "nonpayable" - }, - { - "name": "transferOwnership", - "type": "function", - "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xf2fde38b", - "stateMutability": "nonpayable" - }, - { - "name": "updatePoolMetadata", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { - "name": "metadata_", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "outputs": [], - "signature": "0xff94d958", - "stateMutability": "nonpayable" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/Prime.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/Prime.json deleted file mode 100644 index e8bfa99ff..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/Prime.json +++ /dev/null @@ -1,763 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, - { "internalType": "address", "name": "_nativeMarket", "type": "address" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, - { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, - { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, - { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, - { "internalType": "bool", "name": "_timeBased", "type": "bool" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, - { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidComptroller", "type": "error" }, - { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "n", "type": "uint256" }, - { "internalType": "uint256", "name": "d", "type": "uint256" } - ], - "name": "InvalidFraction", - "type": "error" - }, - { "inputs": [], "name": "InvalidLength", "type": "error" }, - { "inputs": [], "name": "InvalidLimit", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, - { "inputs": [], "name": "InvalidVToken", "type": "error" }, - { - "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], - "name": "LnNonRealResult", - "type": "error" - }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, - { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, - { "inputs": [], "name": "MarketNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, - { "inputs": [], "name": "WaitMoreTime", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, - { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } - ], - "name": "AlphaUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "Burn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "InterestClaimed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "MarketAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } - ], - "name": "MintLimitsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } - ], - "name": "MultiplierUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } - ], - "name": "StakedAtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "TokenUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "UserScoreUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "MAXIMUM_XVS_CAP", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MINIMUM_STAKED_XVS", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_MARKET", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "STAKING_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WRAPPED_NATIVE_TOKEN", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "accrueInterest", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" } - ], - "name": "accrueInterestAndUpdateScore", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "addMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "alphaDenominator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "alphaNumerator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "calculateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "claimTimeRemaining", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "uint256", "name": "borrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supply", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } - ], - "name": "estimateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "getInterestAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "getPendingRewards", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "internalType": "struct PrimeStorageV1.PendingReward[]", - "name": "pendingRewards", - "type": "tuple[]" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "incomeDistributionYearly", - "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "xvsVault_", "type": "address" }, - { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, - { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, - { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, - { "internalType": "address", "name": "comptroller_", "type": "address" }, - { "internalType": "address", "name": "oracle_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "name": "initializeV2", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "interests", - "outputs": [ - { "internalType": "uint256", "name": "accrued", "type": "uint256" }, - { "internalType": "uint256", "name": "score", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "irrevocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "", "type": "uint256" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "isScoreUpdated", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "isUserPrimeHolder", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, - { "internalType": "address[]", "name": "users", "type": "address[]" } - ], - "name": "issue", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, - { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, - { "internalType": "bool", "name": "exists", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "nextScoreUpdateRoundId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingScoreUpdates", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "primeLiquidityProvider", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "revocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } - ], - "name": "setLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "users", "type": "address[]" }, - { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } - ], - "name": "setStakedAt", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "stakedAt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokens", - "outputs": [ - { "internalType": "bool", "name": "exists", "type": "bool" }, - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalIrrevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalRevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalScoreUpdatesRequired", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "unreleasedPLPIncome", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, - { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } - ], - "name": "updateAlpha", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "updateMultipliers", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], - "name": "updateScores", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "vTokenForAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "xvsUpdated", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVault", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultPoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/PrimeLiquidityProvider.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/PrimeLiquidityProvider.json deleted file mode 100644 index 02ca8e0bf..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/PrimeLiquidityProvider.json +++ /dev/null @@ -1,385 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "_timeBased", "type": "bool" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, - { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "balance", "type": "uint256" } - ], - "name": "InsufficientBalance", - "type": "error" - }, - { "inputs": [], "name": "InvalidArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidCaller", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "speed", "type": "uint256" }, - { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } - ], - "name": "InvalidDistributionSpeed", - "type": "error" - }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenAlreadyInitialized", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "TokenNotInitialized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "MaxTokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } - ], - "name": "PrimeTokenUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenDistributionInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "TokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokenTransferredToPrime", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokensAccrued", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "accrueTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "getEffectiveDistributionSpeed", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], - "name": "initializeTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "lastAccruedBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastAccruedBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "maxTokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } - ], - "name": "setMaxTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } - ], - "name": "setTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, - { "internalType": "address", "name": "to_", "type": "address" }, - { "internalType": "uint256", "name": "amount_", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "tokenAmountAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/ProtocolShareReserve.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/ProtocolShareReserve.json deleted file mode 100644 index b33d7c495..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/ProtocolShareReserve.json +++ /dev/null @@ -1,356 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, - { "internalType": "address", "name": "_wbnb", "type": "address" }, - { "internalType": "address", "name": "_vbnb", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetReleased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IProtocolShareReserve.IncomeType", - "name": "incomeType", - "type": "uint8" - }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "AssetsReservesUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } - ], - "name": "PoolRegistryUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "ReservesUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "CORE_POOL_COMPTROLLER", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MAX_PERCENT", - "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "internalType": "struct ProtocolShareReserve.DistributionConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "addOrUpdateDistributionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } - ], - "name": "assetsReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "distributionTargets", - "outputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "getPercentageDistribution", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "getUnreleasedFunds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address[]", "name": "assets", "type": "address[]" } - ], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "name": "removeDistributionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], - "name": "setPoolRegistry", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAssetReserve", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalDistributions", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/RewardDistrbutor.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/RewardDistrbutor.json deleted file mode 100644 index 249fdd111..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/RewardDistrbutor.json +++ /dev/null @@ -1,532 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "BorrowLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "BorrowLastRewardingBlockUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "ContributorRewardTokenSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } - ], - "name": "ContributorRewardsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } - ], - "name": "DistributedBorrowerRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } - ], - "name": "DistributedSupplierRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "MarketInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "indexed": false, - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "RewardTokenBorrowIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenBorrowSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RewardTokenGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "RewardTokenSupplyIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenSupplySpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "SupplyLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "SupplyLastRewardingBlockUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "INITIAL_INDEX", - "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "holder", "type": "address" }, - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } - ], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "distributeBorrowerRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "supplier", "type": "address" } - ], - "name": "distributeSupplierRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "recipient", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "grantRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, - { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "initializeMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastContributorBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "rewardToken", - "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenBorrowerIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenContributorSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenSupplierIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplySpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contributor", "type": "address" }, - { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } - ], - "name": "setContributorRewardTokenSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } - ], - "name": "setLastRewardingBlockTimestamps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, - { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } - ], - "name": "setLastRewardingBlocks", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } - ], - "name": "setRewardTokenSpeeds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], - "name": "updateContributorRewards", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "updateRewardTokenBorrowIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "updateRewardTokenSupplyIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/VToken.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/VToken.json deleted file mode 100644 index d8cc1aae4..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/VToken.json +++ /dev/null @@ -1,861 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], - "name": "AddReservesFactorFreshCheck", - "type": "error" - }, - { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, - { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, - { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], - "name": "LiquidateAccrueCollateralInterestFailed", - "type": "error" - }, - { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, - { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, - { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, - { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, - { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, - { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, - { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "AccrueInterest", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtRecovered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "Borrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "HealBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "LiquidateBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } - ], - "name": "NewComptroller", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "oldInterestRateModel", - "type": "address" - }, - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "newInterestRateModel", - "type": "address" - } - ], - "name": "NewMarketInterestRateModel", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } - ], - "name": "NewProtocolSeizeShare", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } - ], - "name": "NewProtocolShareReserve", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } - ], - "name": "NewReduceReservesBlockDelta", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } - ], - "name": "NewReserveFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } - ], - "name": "NewShortfallContract", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ProtocolSeize", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Redeem", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "RepayBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "ReservesAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "SpreadReservesReduced", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Transfer", - "type": "event" - }, - { - "inputs": [], - "name": "NO_ERROR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrualBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrueInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], - "name": "addReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "owner", "type": "address" }, - { "internalType": "address", "name": "spender", "type": "address" } - ], - "name": "allowance", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "approve", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "badDebt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], - "name": "badDebtRecovered", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOfUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], - "name": "borrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "borrowIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "borrowRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } - ], - "name": "decreaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "forceLiquidateBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountSnapshot", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCash", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "healBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "addedValue", "type": "uint256" } - ], - "name": "increaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "underlying_", "type": "address" }, - { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, - { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, - { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, - { "internalType": "string", "name": "name_", "type": "string" }, - { "internalType": "string", "name": "symbol_", "type": "string" }, - { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, - { "internalType": "address", "name": "admin_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { - "components": [ - { "internalType": "address", "name": "shortfall", "type": "address" }, - { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } - ], - "internalType": "struct VTokenInterface.RiskManagementInit", - "name": "riskManagement", - "type": "tuple" - }, - { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "interestRateModel", - "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isVToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } - ], - "name": "liquidateBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], - "name": "mint", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "mintBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolSeizeShareMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolShareReserve", - "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], - "name": "redeem", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], - "name": "redeemUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } - ], - "name": "redeemUnderlyingBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], - "name": "reduceReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockDelta", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], - "name": "repayBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "repayBorrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reserveFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], - "name": "setInterestRateModel", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], - "name": "setProtocolSeizeShare", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], - "name": "setProtocolShareReserve", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], - "name": "setReduceReservesBlockDelta", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], - "name": "setReserveFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], - "name": "setShortfallContract", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "shortfall", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "supplyRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrows", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrowsCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "totalReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transfer", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transferFrom", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "underlying", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/VTokenBeacon.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/VTokenBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/VTokenBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/XVSStore.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/XVSStore.json deleted file mode 100644 index 2d9ea2bb2..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/XVSStore.json +++ /dev/null @@ -1,130 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "AdminTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } - ], - "name": "NewPendingAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnerTransferred", - "type": "event" - }, - { - "constant": false, - "inputs": [], - "name": "acceptAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "emergencyRewardWithdraw", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokens", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "token", "type": "address" }, - { "internalType": "address", "name": "_to", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "safeRewardTransfer", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], - "name": "setNewOwner", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], - "name": "setPendingAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "bool", "name": "status", "type": "bool" } - ], - "name": "setRewardToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/XVSVault.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/XVSVault.json deleted file mode 100644 index 51d8d540c..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/XVSVault.json +++ /dev/null @@ -1,787 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Claim", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } - ], - "name": "DelegateChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "DelegateVotesChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Deposit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ExecutedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "name": "PoolAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } - ], - "name": "PoolUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RequestedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } - ], - "name": "RewardAmountUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } - ], - "name": "StoreUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } - ], - "name": "VaultDebtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } - ], - "name": "WithdrawalLockingPeriodUpdated", - "type": "event" - }, - { - "constant": true, - "inputs": [], - "name": "DELEGATION_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "DOMAIN_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "MAX_LOCK_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "SECONDS_PER_YEAR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], - "name": "_become", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, - { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, - { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } - ], - "name": "add", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint32", "name": "", "type": "uint32" } - ], - "name": "checkpoints", - "outputs": [ - { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, - { "internalType": "uint96", "name": "votes", "type": "uint96" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_account", "type": "address" }, - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "claim", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], - "name": "delegate", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "delegatee", "type": "address" }, - { "internalType": "uint256", "name": "nonce", "type": "uint256" }, - { "internalType": "uint256", "name": "expiry", "type": "uint256" }, - { "internalType": "uint8", "name": "v", "type": "uint8" }, - { "internalType": "bytes32", "name": "r", "type": "bytes32" }, - { "internalType": "bytes32", "name": "s", "type": "bytes32" } - ], - "name": "delegateBySig", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "delegates", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "deposit", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "executeWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getCurrentVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getEligibleWithdrawalAmount", - "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } - ], - "name": "getPriorVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getRequestedAmount", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getUserInfo", - "outputs": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, - { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getWithdrawalRequests", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, - { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } - ], - "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", - "name": "", - "type": "tuple[]" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "name": "initializeTimeManager", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isStakedToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "nonces", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "numCheckpoints", - "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "pause", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingReward", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "pendingRewardTransfers", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingWithdrawalsBeforeUpgrade", - "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingXVSVaultImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "poolInfos", - "outputs": [ - { "internalType": "contract IBEP20", "name": "token", "type": "address" }, - { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, - { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], - "name": "poolLength", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primePoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeToken", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "requestWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "resume", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], - "name": "rewardTokenAmountsPerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAmountsPerBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } - ], - "name": "set", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], - "name": "setAccessControl", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, - { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } - ], - "name": "setPrimeToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } - ], - "name": "setRewardAmountPerBlockOrSecond", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } - ], - "name": "setWithdrawalLockingPeriod", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_xvs", "type": "address" }, - { "internalType": "address", "name": "_xvsStore", "type": "address" } - ], - "name": "setXvsStore", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAllocPoints", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "totalPendingWithdrawals", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "updatePool", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "vaultPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsStore", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/boundValidator.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/boundValidator.json deleted file mode 100644 index d16c8fb08..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/boundValidator.json +++ /dev/null @@ -1,498 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "previousAdmin", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAdmin", - "type": "address" - } - ], - "name": "AdminChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "beacon", - "type": "address" - } - ], - "name": "BeaconUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "implementation", - "type": "address" - } - ], - "name": "Upgraded", - "type": "event" - }, - { - "stateMutability": "payable", - "type": "fallback" - }, - { - "inputs": [], - "name": "admin", - "outputs": [ - { - "internalType": "address", - "name": "admin_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [ - { - "internalType": "address", - "name": "implementation_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - } - ], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - }, - { - "internalType": "bytes", - "name": "data", - "type": "bytes" - } - ], - "name": "upgradeToAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "upperBound", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "lowerBound", - "type": "uint256" - } - ], - "name": "ValidateConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig", - "name": "config", - "type": "tuple" - } - ], - "name": "setValidateConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "setValidateConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "validateConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "reportedPrice", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "anchorPrice", - "type": "uint256" - } - ], - "name": "validatePriceWithAnchorPrice", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_logic", - "type": "address" - }, - { - "internalType": "address", - "name": "admin_", - "type": "address" - }, - { - "internalType": "bytes", - "name": "_data", - "type": "bytes" - } - ], - "stateMutability": "payable", - "type": "constructor" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/chainlinkOracle.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/chainlinkOracle.json deleted file mode 100644 index cdd689acb..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/chainlinkOracle.json +++ /dev/null @@ -1,459 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "vBnbAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "previousPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "requestedPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newPriceMantissa", - "type": "uint256" - } - ], - "name": "PricePosted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManager", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "prices", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - } - ], - "name": "setDirectPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VBep20Interface", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "underlyingPriceMantissa", - "type": "uint256" - } - ], - "name": "setUnderlyingPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "tokenConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/resilientOracle.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/resilientOracle.json deleted file mode 100644 index 35f52caa0..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/resilientOracle.json +++ /dev/null @@ -1,640 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "nativeMarketAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - }, - { - "internalType": "contract BoundValidatorInterface", - "name": "_boundValidator", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "OracleEnabled", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - } - ], - "name": "OracleSet", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "mainOracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "pivotOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "fallbackOracle", - "type": "address" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "INVALID_PRICE", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_TOKEN_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "boundValidator", - "outputs": [ - { - "internalType": "contract BoundValidatorInterface", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - }, - { - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "enableOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "getOracle", - "outputs": [ - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "bool", - "name": "enabled", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getTokenConfig", - "outputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "nativeMarket", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "setOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "updateAssetPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "updatePrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/treasury.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/treasury.json deleted file mode 100644 index 18aabb61a..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/treasury.json +++ /dev/null @@ -1,86 +0,0 @@ -[ - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryNative", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryToken", - "type": "event" - }, - { "stateMutability": "payable", "type": "fallback" }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryNative", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "stateMutability": "payable", "type": "receive" } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/xvs.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/xvs.json deleted file mode 100644 index 69092bb4a..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/xvs.json +++ /dev/null @@ -1,716 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user", - "type": "address" - } - ], - "name": "AccountBlacklisted", - "type": "error" - }, - { - "inputs": [], - "name": "AddressesMustDiffer", - "type": "error" - }, - { - "inputs": [], - "name": "MintLimitExceed", - "type": "error" - }, - { - "inputs": [], - "name": "MintedAmountExceed", - "type": "error" - }, - { - "inputs": [], - "name": "NewCapNotGreaterThanMintedTokens", - "type": "error" - }, - { - "inputs": [], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "user", - "type": "address" - }, - { - "indexed": false, - "internalType": "bool", - "name": "value", - "type": "bool" - } - ], - "name": "BlacklistUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "MintCapChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitDecreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "source", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "destination", - "type": "address" - } - ], - "name": "MintedTokensMigrated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Transfer", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "internalType": "address", - "name": "spender", - "type": "address" - } - ], - "name": "allowance", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "approve", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [ - { - "internalType": "uint8", - "name": "", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "subtractedValue", - "type": "uint256" - } - ], - "name": "decreaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "addedValue", - "type": "uint256" - } - ], - "name": "increaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - } - ], - "name": "isBlackListed", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "source_", - "type": "address" - }, - { - "internalType": "address", - "name": "destination_", - "type": "address" - } - ], - "name": "migrateMinterTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "mint", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToCap", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToMintedAmount", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newAccessControlAddress_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "minter_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "setMintCap", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transfer", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transferFrom", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - }, - { - "internalType": "bool", - "name": "value_", - "type": "bool" - } - ], - "name": "updateBlacklist", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/xvsBridgeAdmin.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/xvsBridgeAdmin.json deleted file mode 100644 index 024450a40..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/abi/xvsBridgeAdmin.json +++ /dev/null @@ -1,329 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "XVSBridge_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "string", - "name": "signature", - "type": "string" - }, - { - "indexed": false, - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "name": "FunctionRegistryChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "stateMutability": "nonpayable", - "type": "fallback" - }, - { - "inputs": [], - "name": "XVSBridge", - "outputs": [ - { - "internalType": "contract IXVSProxyOFT", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes4", - "name": "", - "type": "bytes4" - } - ], - "name": "functionRegistry", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "isTrustedRemote", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner_", - "type": "address" - } - ], - "name": "transferBridgeOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "string[]", - "name": "signatures_", - "type": "string[]" - }, - { - "internalType": "bool[]", - "name": "active_", - "type": "bool[]" - } - ], - "name": "upsertSignature", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/arbitrumsepolia/vip-014/index.ts b/multisig/simulations/arbitrumsepolia/vip-014/index.ts deleted file mode 100644 index b41f4c84e..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/index.ts +++ /dev/null @@ -1,225 +0,0 @@ -import { expect } from "chai"; -import { Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip } from "src/vip-framework"; - -import vip014, { - BOUND_VALIDATOR, - COMPTROLLERS, - COMPTROLLER_BEACON, - DEFAULT_PROXY_ADMIN, - PLP, - PRIME, - PSR, - REWARD_DISTRIBUTORS, - VTOKENS, - VTOKEN_BEACON, - XVS, - XVS_BRIDGE_ADMIN_PROXY, - XVS_STORE, -} from "../../../proposals/arbitrumsepolia/vip-014"; -import COMPTROLLER_ABI from "./abi/Comptroller.json"; -import COMPTROLLER_BEACON_ABI from "./abi/ComptrollerBeacon.json"; -import DEFAULT_PROXY_ADMIN_ABI from "./abi/DefaultProxyAdmin.json"; -import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; -import PRIME_ABI from "./abi/Prime.json"; -import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; -import PSR_ABI from "./abi/ProtocolShareReserve.json"; -import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistrbutor.json"; -import VTOKEN_ABI from "./abi/VToken.json"; -import VTOKEN_BEACON_ABI from "./abi/VTokenBeacon.json"; -import XVS_STORE_ABI from "./abi/XVSStore.json"; -import XVS_VAULT_ABI from "./abi/XVSVault.json"; -import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; -import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; -import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; -import TREASURY_ABI from "./abi/treasury.json"; -import XVS_ABI from "./abi/xvs.json"; -import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; - -const { arbitrumsepolia } = NETWORK_ADDRESSES; - -const RESILIENT_ORACLE = arbitrumsepolia.RESILIENT_ORACLE; -const CHAINLINK_ORACLE = arbitrumsepolia.CHAINLINK_ORACLE; -const REDSTONE_ORACLE = arbitrumsepolia.REDSTONE_ORACLE; -const NORMAL_TIMELOCK = arbitrumsepolia.NORMAL_TIMELOCK; - -forking(69942668, async () => { - const provider = ethers.provider; - let proxyAdmin: Contract; - let prime: Contract; - let plp: Contract; - let psr: Contract; - let comptrollerBeacon: Contract; - let vTokenBeacon: Contract; - let poolRegistry: Contract; - let xvsVault: Contract; - let xvsStore: Contract; - let xvs: Contract; - let xvsBridgeAdmin: Contract; - let resilientOracle: Contract; - let chainLinkOracle: Contract; - let redstoneOracle: Contract; - let boundValidator: Contract; - let treasury: Contract; - - describe("Pre-VIP behavior", async () => { - before(async () => { - proxyAdmin = new ethers.Contract(DEFAULT_PROXY_ADMIN, DEFAULT_PROXY_ADMIN_ABI, provider); - prime = new ethers.Contract(PRIME, PRIME_ABI, provider); - plp = new ethers.Contract(PLP, PLP_ABI, provider); - psr = new ethers.Contract(PSR, PSR_ABI, provider); - comptrollerBeacon = new ethers.Contract(COMPTROLLER_BEACON, COMPTROLLER_BEACON_ABI, provider); - vTokenBeacon = new ethers.Contract(VTOKEN_BEACON, VTOKEN_BEACON_ABI, provider); - poolRegistry = new ethers.Contract(arbitrumsepolia.POOL_REGISTRY, POOL_REGISTRY_ABI, provider); - xvsVault = new ethers.Contract(arbitrumsepolia.XVS_VAULT_PROXY, XVS_VAULT_ABI, provider); - xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); - xvs = await ethers.getContractAt(XVS_ABI, XVS); - xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, XVS_BRIDGE_ADMIN_PROXY); - resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); - chainLinkOracle = new ethers.Contract(CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); - redstoneOracle = new ethers.Contract(REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); - boundValidator = new ethers.Contract(BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); - treasury = await ethers.getContractAt(TREASURY_ABI, NETWORK_ADDRESSES.arbitrumsepolia.VTREASURY); - }); - - it("owner of proxy admin is guardian", async () => { - expect(await proxyAdmin.owner()).to.equal(arbitrumsepolia.GUARDIAN); - }); - it("pending owner", async () => { - expect(await prime.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await plp.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - - for (const rewardDistributor of REWARD_DISTRIBUTORS) { - it(`should have no pending owner for ${rewardDistributor}`, async () => { - const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - it("pending owner of psr", async () => { - expect(await psr.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`should have no pending owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`should have no pending owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - it("owner of ComptrollerBeacon is guardian", async () => { - expect(await comptrollerBeacon.owner()).to.equal(arbitrumsepolia.GUARDIAN); - }); - - it("owner of VTokenBeacon is guardian", async () => { - expect(await vTokenBeacon.owner()).to.equal(arbitrumsepolia.GUARDIAN); - }); - - it("pending owner of PoolRegistry", async () => { - expect(await poolRegistry.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - it("should have no pending owner", async () => { - expect(await xvsVault.pendingAdmin()).to.equal(ethers.constants.AddressZero); - }); - - it("should have no pending owner", async () => { - expect(await xvsStore.pendingAdmin()).to.equal(ethers.constants.AddressZero); - }); - - it("should have no pending owner", async () => { - expect(await resilientOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await chainLinkOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await redstoneOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await boundValidator.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - }); - - describe("Post-VIP behavior", async () => { - before(async () => { - await pretendExecutingVip(await vip014()); - }); - - it("owner of proxy admin is timelock", async () => { - expect(await proxyAdmin.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - - it("pending owner", async () => { - expect(await prime.pendingOwner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - expect(await plp.pendingOwner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - - for (const rewardDistributor of REWARD_DISTRIBUTORS) { - it(`should have Normal Timelock as pending owner for ${rewardDistributor}`, async () => { - const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); - expect(await c.pendingOwner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - } - - it("pending owner of psr", async () => { - expect(await psr.pendingOwner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`correct pending owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.pendingOwner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`correct pending owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.pendingOwner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - } - - it("owner of ComptrollerBeacon is NT", async () => { - expect(await comptrollerBeacon.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - - it("owner of VTokenBeacon is NT", async () => { - expect(await vTokenBeacon.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - - it("pending owner of PoolRegistry is NT", async () => { - expect(await poolRegistry.pendingOwner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - - it("correct pending owner", async () => { - expect(await xvsVault.pendingAdmin()).to.equal(NORMAL_TIMELOCK); - }); - - it("correct pending owner", async () => { - expect(await xvsStore.pendingAdmin()).to.equal(NORMAL_TIMELOCK); - }); - - it("Should set bridge pending owner to Normal Timelock", async () => { - const pendingOwner = await xvsBridgeAdmin.pendingOwner(); - expect(pendingOwner).equals(arbitrumsepolia.NORMAL_TIMELOCK); - }); - it("Should set XVS owner to Normal Timelock", async () => { - const owner = await xvs.owner(); - expect(owner).equals(arbitrumsepolia.NORMAL_TIMELOCK); - }); - it("correct pending owner", async () => { - expect(await resilientOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); - expect(await chainLinkOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); - expect(await redstoneOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); - expect(await boundValidator.pendingOwner()).to.equal(NORMAL_TIMELOCK); - }); - it("Should set pendingOwner to Normal Timelock", async () => { - const pendingOwner = await treasury.pendingOwner(); - expect(pendingOwner).equals(NETWORK_ADDRESSES.arbitrumsepolia.NORMAL_TIMELOCK); - }); - }); -}); diff --git a/multisig/simulations/ethereum/vip-061/abi/Comptroller.json b/multisig/simulations/ethereum/vip-061/abi/Comptroller.json deleted file mode 100644 index f3b2445ac..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/Comptroller.json +++ /dev/null @@ -1,929 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "ActionPaused", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "BorrowCapExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "CollateralExceedsThreshold", - "type": "error" - }, - { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, - { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, - { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } - ], - "name": "InsufficientCollateral", - "type": "error" - }, - { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, - { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, - { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, - { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketAlreadyListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "MarketNotCollateral", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketNotListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "MinimalCollateralViolated", - "type": "error" - }, - { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "PriceError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "SnapshotError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "SupplyCapExceeded", - "type": "error" - }, - { "inputs": [], "name": "TooMuchRepay", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "expectedSender", "type": "address" }, - { "internalType": "address", "name": "actualSender", "type": "address" } - ], - "name": "UnexpectedSender", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, - { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } - ], - "name": "ActionPausedMarket", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "DelegateUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "IsForcedLiquidationEnabledUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketEntered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketExited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "MarketSupported", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } - ], - "name": "NewBorrowCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } - ], - "name": "NewCloseFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } - ], - "name": "NewCollateralFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } - ], - "name": "NewLiquidationIncentive", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "NewLiquidationThreshold", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } - ], - "name": "NewMinLiquidatableCollateral", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "oldPriceOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "newPriceOracle", - "type": "address" - } - ], - "name": "NewPriceOracle", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } - ], - "name": "NewRewardsDistributor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } - ], - "name": "NewSupplyCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "accountAssets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "actionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], - "name": "addRewardsDistributor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "allMarkets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "approvedDelegates", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "borrowCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "contract VToken", "name": "vToken", "type": "address" } - ], - "name": "checkMembership", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "closeFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], - "name": "enterMarkets", - "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], - "name": "exitMarket", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAssetsIn", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getBorrowingPower", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "address", "name": "vTokenModify", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "getHypotheticalAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getRewardDistributors", - "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "getRewardsByMarket", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.RewardSpeeds[]", - "name": "rewardSpeeds", - "type": "tuple[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "healAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isComptroller", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isForcedLiquidationEnabled", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "isMarketListed", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [ - { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.LiquidationOrder[]", - "name": "orders", - "type": "tuple[]" - } - ], - "name": "liquidateAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "liquidateBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } - ], - "name": "liquidateCalculateSeizeTokens", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "liquidationIncentiveMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "bool", "name": "isListed", "type": "bool" }, - { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "minLiquidatableCollateral", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } - ], - "name": "mintVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "preBorrowHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "preLiquidateHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "preMintHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "preRedeemHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preRepayHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "seizerContract", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preSeizeHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "preTransferHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } - ], - "name": "repayBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seizeVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, - { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, - { "internalType": "bool", "name": "paused", "type": "bool" } - ], - "name": "setActionsPaused", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], - "name": "setCloseFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "setCollateralFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "setForcedLiquidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], - "name": "setLiquidationIncentive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } - ], - "name": "setMarketBorrowCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } - ], - "name": "setMarketSupplyCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], - "name": "setMinLiquidatableCollateral", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "supplyCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "supportMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "transferVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "delegate", "type": "address" }, - { "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "updateDelegate", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "updatePrices", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/ComptrollerBeacon.json b/multisig/simulations/ethereum/vip-061/abi/ComptrollerBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/ComptrollerBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/ConverterNetwork.json b/multisig/simulations/ethereum/vip-061/abi/ConverterNetwork.json deleted file mode 100644 index 396f12a91..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/ConverterNetwork.json +++ /dev/null @@ -1,205 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { "inputs": [], "name": "ConverterAlreadyExists", "type": "error" }, - { "inputs": [], "name": "ConverterDoesNotExist", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "InvalidMaxLoopsLimit", - "type": "error" - }, - { "inputs": [], "name": "InvalidTokenConverterAddress", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], - "name": "ConverterAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], - "name": "ConverterRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], - "name": "addTokenConverter", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "allConverters", - "outputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } - ], - "name": "findTokenConverters", - "outputs": [ - { "internalType": "address[]", "name": "converters", "type": "address[]" }, - { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } - ], - "name": "findTokenConvertersForConverters", - "outputs": [ - { "internalType": "address[]", "name": "converters", "type": "address[]" }, - { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getAllConverters", - "outputs": [{ "internalType": "contract IAbstractTokenConverter[]", "name": "converters", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_tokenConverter", "type": "address" }], - "name": "isTokenConverter", - "outputs": [{ "internalType": "bool", "name": "isConverter", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], - "name": "removeTokenConverter", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/DefaultProxyAdmin.json b/multisig/simulations/ethereum/vip-061/abi/DefaultProxyAdmin.json deleted file mode 100644 index 9801cfcc7..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/DefaultProxyAdmin.json +++ /dev/null @@ -1,76 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "changeProxyAdmin", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" } - ], - "name": "upgrade", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" }, - { "internalType": "bytes", "name": "data", "type": "bytes" } - ], - "name": "upgradeAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/PoolRegistry.json b/multisig/simulations/ethereum/vip-061/abi/PoolRegistry.json deleted file mode 100644 index 31b1e2a17..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/PoolRegistry.json +++ /dev/null @@ -1,379 +0,0 @@ -[ - { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, - { - "name": "Unauthorized", - "type": "error", - "inputs": [ - { "name": "sender", "type": "address", "internalType": "address" }, - { "name": "calledContract", "type": "address", "internalType": "address" }, - { "name": "methodSignature", "type": "string", "internalType": "string" } - ] - }, - { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, - { - "name": "Initialized", - "type": "event", - "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], - "anonymous": false, - "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" - }, - { - "name": "MarketAdded", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" - }, - { - "name": "NewAccessControlManager", - "type": "event", - "inputs": [ - { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, - { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" - }, - { - "name": "OwnershipTransferStarted", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" - }, - { - "name": "OwnershipTransferred", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" - }, - { - "name": "PoolMetadataUpdated", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "oldMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - }, - { - "name": "newMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "anonymous": false, - "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" - }, - { - "name": "PoolNameSet", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, - { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } - ], - "anonymous": false, - "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" - }, - { - "name": "PoolRegistered", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "pool", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "anonymous": false, - "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" - }, - { - "name": "acceptOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x79ba5097", - "stateMutability": "nonpayable" - }, - { - "name": "accessControlManager", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "contract IAccessControlManagerV8" - } - ], - "constant": true, - "signature": "0xb4a0bdf3", - "stateMutability": "view" - }, - { - "name": "addMarket", - "type": "function", - "inputs": [ - { - "name": "input", - "type": "tuple", - "components": [ - { "name": "vToken", "type": "address", "internalType": "contract VToken" }, - { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, - { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, - { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, - { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, - { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistry.AddMarketInput" - } - ], - "outputs": [], - "signature": "0x23dc8d64", - "stateMutability": "nonpayable" - }, - { - "name": "addPool", - "type": "function", - "inputs": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, - { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, - { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } - ], - "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], - "signature": "0xeed873c2", - "stateMutability": "nonpayable" - }, - { - "name": "getAllPools", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "tuple[]", - "value": [], - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool[]" - } - ], - "constant": true, - "signature": "0xd88ff1f4", - "stateMutability": "view" - }, - { - "name": "getPoolByComptroller", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "constant": true, - "signature": "0x7aee632d", - "stateMutability": "view" - }, - { - "name": "getPoolsSupportedByAsset", - "type": "function", - "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], - "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], - "constant": true, - "signature": "0xf36dba38", - "stateMutability": "view" - }, - { - "name": "getVTokenForAsset", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "asset", "type": "address", "internalType": "address" } - ], - "outputs": [{ "name": "", "type": "address", "internalType": "address" }], - "constant": true, - "signature": "0x266e0a7f", - "stateMutability": "view" - }, - { - "name": "getVenusPoolMetadata", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "constant": true, - "signature": "0xa3aefa2c", - "stateMutability": "view" - }, - { - "name": "initialize", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xc4d66de8", - "stateMutability": "nonpayable" - }, - { - "name": "metadata", - "type": "function", - "inputs": [{ "name": "", "type": "address", "internalType": "address" }], - "outputs": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "constant": true, - "signature": "0x2ba21572", - "stateMutability": "view" - }, - { - "name": "owner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x8da5cb5b", - "stateMutability": "view" - }, - { - "name": "pendingOwner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0xe30c3978", - "stateMutability": "view" - }, - { - "name": "renounceOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x715018a6", - "stateMutability": "nonpayable" - }, - { - "name": "setAccessControlManager", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0x0e32cb86", - "stateMutability": "nonpayable" - }, - { - "name": "setPoolName", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "name", "type": "string", "internalType": "string" } - ], - "outputs": [], - "signature": "0x1cb6bb7e", - "stateMutability": "nonpayable" - }, - { - "name": "transferOwnership", - "type": "function", - "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xf2fde38b", - "stateMutability": "nonpayable" - }, - { - "name": "updatePoolMetadata", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { - "name": "metadata_", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "outputs": [], - "signature": "0xff94d958", - "stateMutability": "nonpayable" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/Prime.json b/multisig/simulations/ethereum/vip-061/abi/Prime.json deleted file mode 100644 index e8bfa99ff..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/Prime.json +++ /dev/null @@ -1,763 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, - { "internalType": "address", "name": "_nativeMarket", "type": "address" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, - { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, - { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, - { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, - { "internalType": "bool", "name": "_timeBased", "type": "bool" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, - { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidComptroller", "type": "error" }, - { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "n", "type": "uint256" }, - { "internalType": "uint256", "name": "d", "type": "uint256" } - ], - "name": "InvalidFraction", - "type": "error" - }, - { "inputs": [], "name": "InvalidLength", "type": "error" }, - { "inputs": [], "name": "InvalidLimit", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, - { "inputs": [], "name": "InvalidVToken", "type": "error" }, - { - "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], - "name": "LnNonRealResult", - "type": "error" - }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, - { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, - { "inputs": [], "name": "MarketNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, - { "inputs": [], "name": "WaitMoreTime", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, - { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } - ], - "name": "AlphaUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "Burn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "InterestClaimed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "MarketAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } - ], - "name": "MintLimitsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } - ], - "name": "MultiplierUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } - ], - "name": "StakedAtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "TokenUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "UserScoreUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "MAXIMUM_XVS_CAP", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MINIMUM_STAKED_XVS", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_MARKET", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "STAKING_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WRAPPED_NATIVE_TOKEN", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "accrueInterest", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" } - ], - "name": "accrueInterestAndUpdateScore", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "addMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "alphaDenominator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "alphaNumerator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "calculateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "claimTimeRemaining", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "uint256", "name": "borrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supply", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } - ], - "name": "estimateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "getInterestAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "getPendingRewards", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "internalType": "struct PrimeStorageV1.PendingReward[]", - "name": "pendingRewards", - "type": "tuple[]" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "incomeDistributionYearly", - "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "xvsVault_", "type": "address" }, - { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, - { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, - { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, - { "internalType": "address", "name": "comptroller_", "type": "address" }, - { "internalType": "address", "name": "oracle_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "name": "initializeV2", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "interests", - "outputs": [ - { "internalType": "uint256", "name": "accrued", "type": "uint256" }, - { "internalType": "uint256", "name": "score", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "irrevocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "", "type": "uint256" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "isScoreUpdated", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "isUserPrimeHolder", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, - { "internalType": "address[]", "name": "users", "type": "address[]" } - ], - "name": "issue", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, - { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, - { "internalType": "bool", "name": "exists", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "nextScoreUpdateRoundId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingScoreUpdates", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "primeLiquidityProvider", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "revocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } - ], - "name": "setLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "users", "type": "address[]" }, - { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } - ], - "name": "setStakedAt", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "stakedAt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokens", - "outputs": [ - { "internalType": "bool", "name": "exists", "type": "bool" }, - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalIrrevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalRevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalScoreUpdatesRequired", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "unreleasedPLPIncome", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, - { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } - ], - "name": "updateAlpha", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "updateMultipliers", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], - "name": "updateScores", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "vTokenForAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "xvsUpdated", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVault", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultPoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/PrimeLiquidityProvider.json b/multisig/simulations/ethereum/vip-061/abi/PrimeLiquidityProvider.json deleted file mode 100644 index 02ca8e0bf..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/PrimeLiquidityProvider.json +++ /dev/null @@ -1,385 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "_timeBased", "type": "bool" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, - { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "balance", "type": "uint256" } - ], - "name": "InsufficientBalance", - "type": "error" - }, - { "inputs": [], "name": "InvalidArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidCaller", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "speed", "type": "uint256" }, - { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } - ], - "name": "InvalidDistributionSpeed", - "type": "error" - }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenAlreadyInitialized", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "TokenNotInitialized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "MaxTokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } - ], - "name": "PrimeTokenUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenDistributionInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "TokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokenTransferredToPrime", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokensAccrued", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "accrueTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "getEffectiveDistributionSpeed", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], - "name": "initializeTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "lastAccruedBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastAccruedBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "maxTokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } - ], - "name": "setMaxTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } - ], - "name": "setTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, - { "internalType": "address", "name": "to_", "type": "address" }, - { "internalType": "uint256", "name": "amount_", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "tokenAmountAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/ProtocolShareReserve.json b/multisig/simulations/ethereum/vip-061/abi/ProtocolShareReserve.json deleted file mode 100644 index b33d7c495..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/ProtocolShareReserve.json +++ /dev/null @@ -1,356 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, - { "internalType": "address", "name": "_wbnb", "type": "address" }, - { "internalType": "address", "name": "_vbnb", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetReleased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IProtocolShareReserve.IncomeType", - "name": "incomeType", - "type": "uint8" - }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "AssetsReservesUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } - ], - "name": "PoolRegistryUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "ReservesUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "CORE_POOL_COMPTROLLER", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MAX_PERCENT", - "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "internalType": "struct ProtocolShareReserve.DistributionConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "addOrUpdateDistributionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } - ], - "name": "assetsReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "distributionTargets", - "outputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "getPercentageDistribution", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "getUnreleasedFunds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address[]", "name": "assets", "type": "address[]" } - ], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "name": "removeDistributionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], - "name": "setPoolRegistry", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAssetReserve", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalDistributions", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/RewardDistrbutor.json b/multisig/simulations/ethereum/vip-061/abi/RewardDistrbutor.json deleted file mode 100644 index 249fdd111..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/RewardDistrbutor.json +++ /dev/null @@ -1,532 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "BorrowLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "BorrowLastRewardingBlockUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "ContributorRewardTokenSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } - ], - "name": "ContributorRewardsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } - ], - "name": "DistributedBorrowerRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } - ], - "name": "DistributedSupplierRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "MarketInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "indexed": false, - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "RewardTokenBorrowIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenBorrowSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RewardTokenGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "RewardTokenSupplyIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenSupplySpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "SupplyLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "SupplyLastRewardingBlockUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "INITIAL_INDEX", - "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "holder", "type": "address" }, - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } - ], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "distributeBorrowerRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "supplier", "type": "address" } - ], - "name": "distributeSupplierRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "recipient", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "grantRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, - { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "initializeMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastContributorBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "rewardToken", - "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenBorrowerIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenContributorSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenSupplierIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplySpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contributor", "type": "address" }, - { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } - ], - "name": "setContributorRewardTokenSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } - ], - "name": "setLastRewardingBlockTimestamps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, - { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } - ], - "name": "setLastRewardingBlocks", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } - ], - "name": "setRewardTokenSpeeds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], - "name": "updateContributorRewards", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "updateRewardTokenBorrowIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "updateRewardTokenSupplyIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/SingleTokenConverter.json b/multisig/simulations/ethereum/vip-061/abi/SingleTokenConverter.json deleted file mode 100644 index 8ea10cc8d..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/SingleTokenConverter.json +++ /dev/null @@ -1,587 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } - ], - "name": "AmountInHigherThanMax", - "type": "error" - }, - { "inputs": [], "name": "AmountInMismatched", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } - ], - "name": "AmountOutLowerThanMinRequired", - "type": "error" - }, - { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, - { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, - { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, - { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, - { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, - { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } - ], - "name": "IncentiveTooHigh", - "type": "error" - }, - { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, - { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, - { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, - { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, - { "inputs": [], "name": "InvalidToAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, - { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetTransferredToDestination", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } - ], - "name": "BaseAssetUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "oldAccess", - "type": "uint8" - }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "newAccess", - "type": "uint8" - } - ], - "name": "ConversionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } - ], - "name": "ConverterNetworkAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } - ], - "name": "DestinationAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } - ], - "name": "MinAmountToConvertUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, - { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } - ], - "name": "PriceOracleUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "inputs": [], - "name": "MAX_INCENTIVE", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "baseAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "conversionConfigurations", - "outputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "conversionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "converterNetwork", - "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "destinationAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, - { "internalType": "address", "name": "destinationAddress_", "type": "address" }, - { "internalType": "address", "name": "baseAsset_", "type": "address" }, - { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "minAmountToConvert", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "priceOracle", - "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], - "name": "setBaseAsset", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig", - "name": "conversionConfig", - "type": "tuple" - } - ], - "name": "setConversionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", - "name": "conversionConfigs", - "type": "tuple[]" - } - ], - "name": "setConversionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], - "name": "setConverterNetwork", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], - "name": "setDestination", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], - "name": "setMinAmountToConvert", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/SingleTokenConverterBeacon.json b/multisig/simulations/ethereum/vip-061/abi/SingleTokenConverterBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/SingleTokenConverterBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/VToken.json b/multisig/simulations/ethereum/vip-061/abi/VToken.json deleted file mode 100644 index d8cc1aae4..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/VToken.json +++ /dev/null @@ -1,861 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], - "name": "AddReservesFactorFreshCheck", - "type": "error" - }, - { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, - { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, - { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], - "name": "LiquidateAccrueCollateralInterestFailed", - "type": "error" - }, - { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, - { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, - { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, - { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, - { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, - { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, - { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "AccrueInterest", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtRecovered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "Borrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "HealBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "LiquidateBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } - ], - "name": "NewComptroller", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "oldInterestRateModel", - "type": "address" - }, - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "newInterestRateModel", - "type": "address" - } - ], - "name": "NewMarketInterestRateModel", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } - ], - "name": "NewProtocolSeizeShare", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } - ], - "name": "NewProtocolShareReserve", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } - ], - "name": "NewReduceReservesBlockDelta", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } - ], - "name": "NewReserveFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } - ], - "name": "NewShortfallContract", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ProtocolSeize", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Redeem", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "RepayBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "ReservesAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "SpreadReservesReduced", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Transfer", - "type": "event" - }, - { - "inputs": [], - "name": "NO_ERROR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrualBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrueInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], - "name": "addReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "owner", "type": "address" }, - { "internalType": "address", "name": "spender", "type": "address" } - ], - "name": "allowance", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "approve", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "badDebt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], - "name": "badDebtRecovered", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOfUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], - "name": "borrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "borrowIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "borrowRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } - ], - "name": "decreaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "forceLiquidateBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountSnapshot", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCash", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "healBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "addedValue", "type": "uint256" } - ], - "name": "increaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "underlying_", "type": "address" }, - { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, - { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, - { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, - { "internalType": "string", "name": "name_", "type": "string" }, - { "internalType": "string", "name": "symbol_", "type": "string" }, - { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, - { "internalType": "address", "name": "admin_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { - "components": [ - { "internalType": "address", "name": "shortfall", "type": "address" }, - { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } - ], - "internalType": "struct VTokenInterface.RiskManagementInit", - "name": "riskManagement", - "type": "tuple" - }, - { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "interestRateModel", - "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isVToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } - ], - "name": "liquidateBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], - "name": "mint", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "mintBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolSeizeShareMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolShareReserve", - "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], - "name": "redeem", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], - "name": "redeemUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } - ], - "name": "redeemUnderlyingBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], - "name": "reduceReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockDelta", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], - "name": "repayBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "repayBorrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reserveFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], - "name": "setInterestRateModel", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], - "name": "setProtocolSeizeShare", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], - "name": "setProtocolShareReserve", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], - "name": "setReduceReservesBlockDelta", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], - "name": "setReserveFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], - "name": "setShortfallContract", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "shortfall", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "supplyRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrows", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrowsCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "totalReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transfer", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transferFrom", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "underlying", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/VTokenBeacon.json b/multisig/simulations/ethereum/vip-061/abi/VTokenBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/VTokenBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/XVSStore.json b/multisig/simulations/ethereum/vip-061/abi/XVSStore.json deleted file mode 100644 index 2d9ea2bb2..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/XVSStore.json +++ /dev/null @@ -1,130 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "AdminTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } - ], - "name": "NewPendingAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnerTransferred", - "type": "event" - }, - { - "constant": false, - "inputs": [], - "name": "acceptAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "emergencyRewardWithdraw", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokens", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "token", "type": "address" }, - { "internalType": "address", "name": "_to", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "safeRewardTransfer", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], - "name": "setNewOwner", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], - "name": "setPendingAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "bool", "name": "status", "type": "bool" } - ], - "name": "setRewardToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/XVSVault.json b/multisig/simulations/ethereum/vip-061/abi/XVSVault.json deleted file mode 100644 index 51d8d540c..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/XVSVault.json +++ /dev/null @@ -1,787 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Claim", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } - ], - "name": "DelegateChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "DelegateVotesChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Deposit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ExecutedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "name": "PoolAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } - ], - "name": "PoolUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RequestedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } - ], - "name": "RewardAmountUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } - ], - "name": "StoreUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } - ], - "name": "VaultDebtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } - ], - "name": "WithdrawalLockingPeriodUpdated", - "type": "event" - }, - { - "constant": true, - "inputs": [], - "name": "DELEGATION_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "DOMAIN_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "MAX_LOCK_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "SECONDS_PER_YEAR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], - "name": "_become", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, - { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, - { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } - ], - "name": "add", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint32", "name": "", "type": "uint32" } - ], - "name": "checkpoints", - "outputs": [ - { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, - { "internalType": "uint96", "name": "votes", "type": "uint96" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_account", "type": "address" }, - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "claim", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], - "name": "delegate", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "delegatee", "type": "address" }, - { "internalType": "uint256", "name": "nonce", "type": "uint256" }, - { "internalType": "uint256", "name": "expiry", "type": "uint256" }, - { "internalType": "uint8", "name": "v", "type": "uint8" }, - { "internalType": "bytes32", "name": "r", "type": "bytes32" }, - { "internalType": "bytes32", "name": "s", "type": "bytes32" } - ], - "name": "delegateBySig", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "delegates", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "deposit", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "executeWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getCurrentVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getEligibleWithdrawalAmount", - "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } - ], - "name": "getPriorVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getRequestedAmount", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getUserInfo", - "outputs": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, - { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getWithdrawalRequests", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, - { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } - ], - "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", - "name": "", - "type": "tuple[]" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "name": "initializeTimeManager", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isStakedToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "nonces", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "numCheckpoints", - "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "pause", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingReward", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "pendingRewardTransfers", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingWithdrawalsBeforeUpgrade", - "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingXVSVaultImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "poolInfos", - "outputs": [ - { "internalType": "contract IBEP20", "name": "token", "type": "address" }, - { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, - { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], - "name": "poolLength", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primePoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeToken", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "requestWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "resume", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], - "name": "rewardTokenAmountsPerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAmountsPerBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } - ], - "name": "set", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], - "name": "setAccessControl", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, - { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } - ], - "name": "setPrimeToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } - ], - "name": "setRewardAmountPerBlockOrSecond", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } - ], - "name": "setWithdrawalLockingPeriod", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_xvs", "type": "address" }, - { "internalType": "address", "name": "_xvsStore", "type": "address" } - ], - "name": "setXvsStore", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAllocPoints", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "totalPendingWithdrawals", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "updatePool", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "vaultPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsStore", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/boundValidator.json b/multisig/simulations/ethereum/vip-061/abi/boundValidator.json deleted file mode 100644 index d16c8fb08..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/boundValidator.json +++ /dev/null @@ -1,498 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "previousAdmin", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAdmin", - "type": "address" - } - ], - "name": "AdminChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "beacon", - "type": "address" - } - ], - "name": "BeaconUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "implementation", - "type": "address" - } - ], - "name": "Upgraded", - "type": "event" - }, - { - "stateMutability": "payable", - "type": "fallback" - }, - { - "inputs": [], - "name": "admin", - "outputs": [ - { - "internalType": "address", - "name": "admin_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [ - { - "internalType": "address", - "name": "implementation_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - } - ], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - }, - { - "internalType": "bytes", - "name": "data", - "type": "bytes" - } - ], - "name": "upgradeToAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "upperBound", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "lowerBound", - "type": "uint256" - } - ], - "name": "ValidateConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig", - "name": "config", - "type": "tuple" - } - ], - "name": "setValidateConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "setValidateConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "validateConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "reportedPrice", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "anchorPrice", - "type": "uint256" - } - ], - "name": "validatePriceWithAnchorPrice", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_logic", - "type": "address" - }, - { - "internalType": "address", - "name": "admin_", - "type": "address" - }, - { - "internalType": "bytes", - "name": "_data", - "type": "bytes" - } - ], - "stateMutability": "payable", - "type": "constructor" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/chainlinkOracle.json b/multisig/simulations/ethereum/vip-061/abi/chainlinkOracle.json deleted file mode 100644 index cdd689acb..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/chainlinkOracle.json +++ /dev/null @@ -1,459 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "vBnbAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "previousPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "requestedPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newPriceMantissa", - "type": "uint256" - } - ], - "name": "PricePosted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManager", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "prices", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - } - ], - "name": "setDirectPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VBep20Interface", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "underlyingPriceMantissa", - "type": "uint256" - } - ], - "name": "setUnderlyingPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "tokenConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/resilientOracle.json b/multisig/simulations/ethereum/vip-061/abi/resilientOracle.json deleted file mode 100644 index 35f52caa0..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/resilientOracle.json +++ /dev/null @@ -1,640 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "nativeMarketAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - }, - { - "internalType": "contract BoundValidatorInterface", - "name": "_boundValidator", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "OracleEnabled", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - } - ], - "name": "OracleSet", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "mainOracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "pivotOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "fallbackOracle", - "type": "address" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "INVALID_PRICE", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_TOKEN_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "boundValidator", - "outputs": [ - { - "internalType": "contract BoundValidatorInterface", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - }, - { - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "enableOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "getOracle", - "outputs": [ - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "bool", - "name": "enabled", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getTokenConfig", - "outputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "nativeMarket", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "setOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "updateAssetPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "updatePrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/sFrxETHOracle.json b/multisig/simulations/ethereum/vip-061/abi/sFrxETHOracle.json deleted file mode 100644 index b461549ba..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/sFrxETHOracle.json +++ /dev/null @@ -1,148 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_sfrxEthFraxOracle", "type": "address" }, - { "internalType": "address", "name": "_sfrxETH", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "BadPriceData", "type": "error" }, - { "inputs": [], "name": "InvalidTokenAddress", "type": "error" }, - { "inputs": [], "name": "PriceDifferenceExceeded", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxAllowedPriceDifference", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxAllowedPriceDifference", "type": "uint256" } - ], - "name": "MaxAllowedPriceDifferenceUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [], - "name": "SFRXETH", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "SFRXETH_FRAX_ORACLE", - "outputs": [{ "internalType": "contract ISfrxEthFraxOracle", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], - "name": "getPrice", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxAllowedPriceDifference", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" }], - "name": "setMaxAllowedPriceDifference", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/treasury.json b/multisig/simulations/ethereum/vip-061/abi/treasury.json deleted file mode 100644 index 18aabb61a..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/treasury.json +++ /dev/null @@ -1,86 +0,0 @@ -[ - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryNative", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryToken", - "type": "event" - }, - { "stateMutability": "payable", "type": "fallback" }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryNative", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "stateMutability": "payable", "type": "receive" } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/xvs.json b/multisig/simulations/ethereum/vip-061/abi/xvs.json deleted file mode 100644 index 69092bb4a..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/xvs.json +++ /dev/null @@ -1,716 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user", - "type": "address" - } - ], - "name": "AccountBlacklisted", - "type": "error" - }, - { - "inputs": [], - "name": "AddressesMustDiffer", - "type": "error" - }, - { - "inputs": [], - "name": "MintLimitExceed", - "type": "error" - }, - { - "inputs": [], - "name": "MintedAmountExceed", - "type": "error" - }, - { - "inputs": [], - "name": "NewCapNotGreaterThanMintedTokens", - "type": "error" - }, - { - "inputs": [], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "user", - "type": "address" - }, - { - "indexed": false, - "internalType": "bool", - "name": "value", - "type": "bool" - } - ], - "name": "BlacklistUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "MintCapChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitDecreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "source", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "destination", - "type": "address" - } - ], - "name": "MintedTokensMigrated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Transfer", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "internalType": "address", - "name": "spender", - "type": "address" - } - ], - "name": "allowance", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "approve", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [ - { - "internalType": "uint8", - "name": "", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "subtractedValue", - "type": "uint256" - } - ], - "name": "decreaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "addedValue", - "type": "uint256" - } - ], - "name": "increaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - } - ], - "name": "isBlackListed", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "source_", - "type": "address" - }, - { - "internalType": "address", - "name": "destination_", - "type": "address" - } - ], - "name": "migrateMinterTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "mint", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToCap", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToMintedAmount", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newAccessControlAddress_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "minter_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "setMintCap", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transfer", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transferFrom", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - }, - { - "internalType": "bool", - "name": "value_", - "type": "bool" - } - ], - "name": "updateBlacklist", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/abi/xvsBridgeAdmin.json b/multisig/simulations/ethereum/vip-061/abi/xvsBridgeAdmin.json deleted file mode 100644 index 024450a40..000000000 --- a/multisig/simulations/ethereum/vip-061/abi/xvsBridgeAdmin.json +++ /dev/null @@ -1,329 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "XVSBridge_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "string", - "name": "signature", - "type": "string" - }, - { - "indexed": false, - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "name": "FunctionRegistryChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "stateMutability": "nonpayable", - "type": "fallback" - }, - { - "inputs": [], - "name": "XVSBridge", - "outputs": [ - { - "internalType": "contract IXVSProxyOFT", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes4", - "name": "", - "type": "bytes4" - } - ], - "name": "functionRegistry", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "isTrustedRemote", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner_", - "type": "address" - } - ], - "name": "transferBridgeOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "string[]", - "name": "signatures_", - "type": "string[]" - }, - { - "internalType": "bool[]", - "name": "active_", - "type": "bool[]" - } - ], - "name": "upsertSignature", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-061/index.ts b/multisig/simulations/ethereum/vip-061/index.ts deleted file mode 100644 index 6f790b852..000000000 --- a/multisig/simulations/ethereum/vip-061/index.ts +++ /dev/null @@ -1,277 +0,0 @@ -import { expect } from "chai"; -import { Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip } from "src/vip-framework"; - -import vip061, { - BOUND_VALIDATOR, - COMPTROLLERS, - COMPTROLLER_BEACON, - CONVERTERS, - CONVERTER_NETWORK, - DEFAULT_PROXY_ADMIN, - PLP, - PRIME, - PSR, - REWARD_DISTRIBUTORS, - SFrxETHOracle, - SINGLE_TOKEN_CONVERTER_BEACON, - VTOKENS, - VTOKEN_BEACON, - XVS, - XVS_BRIDGE_ADMIN_PROXY, - XVS_STORE, -} from "../../../proposals/ethereum/vip-061"; -import COMPTROLLER_ABI from "./abi/Comptroller.json"; -import COMPTROLLER_BEACON_ABI from "./abi/ComptrollerBeacon.json"; -import CONVERTER_NETWORK_ABI from "./abi/ConverterNetwork.json"; -import DEFAULT_PROXY_ADMIN_ABI from "./abi/DefaultProxyAdmin.json"; -import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; -import PRIME_ABI from "./abi/Prime.json"; -import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; -import PSR_ABI from "./abi/ProtocolShareReserve.json"; -import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistrbutor.json"; -import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; -import SINGLE_TOKEN_CONVERTER_BEACON_ABI from "./abi/SingleTokenConverterBeacon.json"; -import VTOKEN_ABI from "./abi/VToken.json"; -import VTOKEN_BEACON_ABI from "./abi/VTokenBeacon.json"; -import XVS_STORE_ABI from "./abi/XVSStore.json"; -import XVS_VAULT_ABI from "./abi/XVSVault.json"; -import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; -import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; -import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; -import SFRAXETH_ORACLE_ABI from "./abi/sFrxETHOracle.json"; -import TREASURY_ABI from "./abi/treasury.json"; -import XVS_ABI from "./abi/xvs.json"; -import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; - -const { ethereum } = NETWORK_ADDRESSES; - -const RESILIENT_ORACLE = ethereum.RESILIENT_ORACLE; -const CHAINLINK_ORACLE = ethereum.CHAINLINK_ORACLE; -const REDSTONE_ORACLE = ethereum.REDSTONE_ORACLE; -const NORMAL_TIMELOCK = ethereum.NORMAL_TIMELOCK; - -forking(20482219, async () => { - const provider = ethers.provider; - let proxyAdmin: Contract; - let prime: Contract; - let plp: Contract; - let psr: Contract; - let comptrollerBeacon: Contract; - let vTokenBeacon: Contract; - let poolRegistry: Contract; - let xvsVault: Contract; - let xvsStore: Contract; - let xvs: Contract; - let xvsBridgeAdmin: Contract; - let resilientOracle: Contract; - let chainLinkOracle: Contract; - let redstoneOracle: Contract; - let boundValidator: Contract; - let treasury: Contract; - let sfrxETHOracle: Contract; - - describe("Pre-VIP behavior", async () => { - before(async () => { - proxyAdmin = new ethers.Contract(DEFAULT_PROXY_ADMIN, DEFAULT_PROXY_ADMIN_ABI, provider); - prime = new ethers.Contract(PRIME, PRIME_ABI, provider); - plp = new ethers.Contract(PLP, PLP_ABI, provider); - psr = new ethers.Contract(PSR, PSR_ABI, provider); - comptrollerBeacon = new ethers.Contract(COMPTROLLER_BEACON, COMPTROLLER_BEACON_ABI, provider); - vTokenBeacon = new ethers.Contract(VTOKEN_BEACON, VTOKEN_BEACON_ABI, provider); - poolRegistry = new ethers.Contract(ethereum.POOL_REGISTRY, POOL_REGISTRY_ABI, provider); - xvsVault = new ethers.Contract(ethereum.XVS_VAULT_PROXY, XVS_VAULT_ABI, provider); - xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); - xvs = await ethers.getContractAt(XVS_ABI, XVS); - xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, XVS_BRIDGE_ADMIN_PROXY); - resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); - chainLinkOracle = new ethers.Contract(CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); - redstoneOracle = new ethers.Contract(REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); - boundValidator = new ethers.Contract(BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); - treasury = await ethers.getContractAt(TREASURY_ABI, NETWORK_ADDRESSES.ethereum.VTREASURY); - sfrxETHOracle = new ethers.Contract(SFrxETHOracle, SFRAXETH_ORACLE_ABI, provider); - }); - - it("owner of proxy admin is guardian", async () => { - expect(await proxyAdmin.owner()).to.equal(ethereum.GUARDIAN); - }); - it("pending owner", async () => { - expect(await prime.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await plp.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - - for (const rewardDistributor of REWARD_DISTRIBUTORS) { - it(`should have no pending owner for ${rewardDistributor}`, async () => { - const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - it("pending owner of psr", async () => { - expect(await psr.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`should have no pending owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`should have no pending owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - it("owner of ComptrollerBeacon is guardian", async () => { - expect(await comptrollerBeacon.owner()).to.equal(ethereum.GUARDIAN); - }); - - it("owner of VTokenBeacon is guardian", async () => { - expect(await vTokenBeacon.owner()).to.equal(ethereum.GUARDIAN); - }); - - it("pending owner of PoolRegistry", async () => { - expect(await poolRegistry.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - it("should have no pending owner", async () => { - expect(await xvsVault.pendingAdmin()).to.equal(ethers.constants.AddressZero); - }); - - it("should have no pending owner", async () => { - expect(await xvsStore.pendingAdmin()).to.equal(ethers.constants.AddressZero); - }); - - it("should have no pending owner", async () => { - expect(await resilientOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await chainLinkOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await redstoneOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await boundValidator.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - - for (const converter of CONVERTERS) { - it(`should have no pending owner for ${converter}`, async () => { - const c = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - it(`should have no pending owner for converter network`, async () => { - const c = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - - it(`should have guardian as owner for converer beacon`, async () => { - const c = new ethers.Contract(SINGLE_TOKEN_CONVERTER_BEACON, SINGLE_TOKEN_CONVERTER_BEACON_ABI, provider); - expect(await c.owner()).to.equal(ethereum.GUARDIAN); - }); - - it("should have no pending owner", async () => { - expect(await sfrxETHOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - }); - - describe("Post-VIP behavior", async () => { - before(async () => { - await pretendExecutingVip(await vip061()); - }); - - it("owner of proxy admin is timelock", async () => { - expect(await proxyAdmin.owner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - - it("pending owner", async () => { - expect(await prime.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); - expect(await plp.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - - for (const rewardDistributor of REWARD_DISTRIBUTORS) { - it(`should have Normal Timelock as pending owner for ${rewardDistributor}`, async () => { - const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - } - - it("pending owner of psr", async () => { - expect(await psr.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`correct pending owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`correct pending owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - } - - it("owner of ComptrollerBeacon is NT", async () => { - expect(await comptrollerBeacon.owner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - - it("owner of VTokenBeacon is NT", async () => { - expect(await vTokenBeacon.owner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - - it("pending owner of PoolRegistry is NT", async () => { - expect(await poolRegistry.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - - it("correct pending owner", async () => { - expect(await xvsVault.pendingAdmin()).to.equal(NORMAL_TIMELOCK); - }); - - it("correct pending owner", async () => { - expect(await xvsStore.pendingAdmin()).to.equal(NORMAL_TIMELOCK); - }); - - it("Should set bridge pending owner to Normal Timelock", async () => { - const pendingOwner = await xvsBridgeAdmin.pendingOwner(); - expect(pendingOwner).equals(ethereum.NORMAL_TIMELOCK); - }); - it("Should set XVS owner to Normal Timelock", async () => { - const owner = await xvs.owner(); - expect(owner).equals(ethereum.NORMAL_TIMELOCK); - }); - it("correct pending owner", async () => { - expect(await resilientOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); - expect(await chainLinkOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); - expect(await redstoneOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); - expect(await boundValidator.pendingOwner()).to.equal(NORMAL_TIMELOCK); - }); - it("Should set pendingOwner to Normal Timelock", async () => { - const pendingOwner = await treasury.pendingOwner(); - expect(pendingOwner).equals(NETWORK_ADDRESSES.ethereum.NORMAL_TIMELOCK); - }); - - for (const converter of CONVERTERS) { - it(`should have no pending owner for ${converter}`, async () => { - const c = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - } - - it(`should have no pending owner for converter network`, async () => { - const c = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - - it(`should have NT as owner for converer beacon`, async () => { - const c = new ethers.Contract(SINGLE_TOKEN_CONVERTER_BEACON, SINGLE_TOKEN_CONVERTER_BEACON_ABI, provider); - expect(await c.owner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - - it("correct pending owner", async () => { - expect(await sfrxETHOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); - }); - }); -}); diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/Comptroller.json b/multisig/simulations/opbnbmainnet/vip-021/abi/Comptroller.json deleted file mode 100644 index f3b2445ac..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/Comptroller.json +++ /dev/null @@ -1,929 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "ActionPaused", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "BorrowCapExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "CollateralExceedsThreshold", - "type": "error" - }, - { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, - { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, - { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } - ], - "name": "InsufficientCollateral", - "type": "error" - }, - { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, - { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, - { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, - { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketAlreadyListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "MarketNotCollateral", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketNotListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "MinimalCollateralViolated", - "type": "error" - }, - { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "PriceError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "SnapshotError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "SupplyCapExceeded", - "type": "error" - }, - { "inputs": [], "name": "TooMuchRepay", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "expectedSender", "type": "address" }, - { "internalType": "address", "name": "actualSender", "type": "address" } - ], - "name": "UnexpectedSender", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, - { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } - ], - "name": "ActionPausedMarket", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "DelegateUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "IsForcedLiquidationEnabledUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketEntered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketExited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "MarketSupported", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } - ], - "name": "NewBorrowCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } - ], - "name": "NewCloseFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } - ], - "name": "NewCollateralFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } - ], - "name": "NewLiquidationIncentive", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "NewLiquidationThreshold", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } - ], - "name": "NewMinLiquidatableCollateral", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "oldPriceOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "newPriceOracle", - "type": "address" - } - ], - "name": "NewPriceOracle", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } - ], - "name": "NewRewardsDistributor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } - ], - "name": "NewSupplyCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "accountAssets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "actionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], - "name": "addRewardsDistributor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "allMarkets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "approvedDelegates", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "borrowCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "contract VToken", "name": "vToken", "type": "address" } - ], - "name": "checkMembership", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "closeFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], - "name": "enterMarkets", - "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], - "name": "exitMarket", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAssetsIn", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getBorrowingPower", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "address", "name": "vTokenModify", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "getHypotheticalAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getRewardDistributors", - "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "getRewardsByMarket", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.RewardSpeeds[]", - "name": "rewardSpeeds", - "type": "tuple[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "healAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isComptroller", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isForcedLiquidationEnabled", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "isMarketListed", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [ - { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.LiquidationOrder[]", - "name": "orders", - "type": "tuple[]" - } - ], - "name": "liquidateAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "liquidateBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } - ], - "name": "liquidateCalculateSeizeTokens", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "liquidationIncentiveMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "bool", "name": "isListed", "type": "bool" }, - { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "minLiquidatableCollateral", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } - ], - "name": "mintVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "preBorrowHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "preLiquidateHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "preMintHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "preRedeemHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preRepayHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "seizerContract", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preSeizeHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "preTransferHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } - ], - "name": "repayBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seizeVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, - { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, - { "internalType": "bool", "name": "paused", "type": "bool" } - ], - "name": "setActionsPaused", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], - "name": "setCloseFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "setCollateralFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "setForcedLiquidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], - "name": "setLiquidationIncentive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } - ], - "name": "setMarketBorrowCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } - ], - "name": "setMarketSupplyCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], - "name": "setMinLiquidatableCollateral", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "supplyCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "supportMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "transferVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "delegate", "type": "address" }, - { "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "updateDelegate", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "updatePrices", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/ComptrollerBeacon.json b/multisig/simulations/opbnbmainnet/vip-021/abi/ComptrollerBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/ComptrollerBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/ConverterNetwork.json b/multisig/simulations/opbnbmainnet/vip-021/abi/ConverterNetwork.json deleted file mode 100644 index 396f12a91..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/ConverterNetwork.json +++ /dev/null @@ -1,205 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { "inputs": [], "name": "ConverterAlreadyExists", "type": "error" }, - { "inputs": [], "name": "ConverterDoesNotExist", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "InvalidMaxLoopsLimit", - "type": "error" - }, - { "inputs": [], "name": "InvalidTokenConverterAddress", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], - "name": "ConverterAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], - "name": "ConverterRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], - "name": "addTokenConverter", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "allConverters", - "outputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } - ], - "name": "findTokenConverters", - "outputs": [ - { "internalType": "address[]", "name": "converters", "type": "address[]" }, - { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } - ], - "name": "findTokenConvertersForConverters", - "outputs": [ - { "internalType": "address[]", "name": "converters", "type": "address[]" }, - { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getAllConverters", - "outputs": [{ "internalType": "contract IAbstractTokenConverter[]", "name": "converters", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_tokenConverter", "type": "address" }], - "name": "isTokenConverter", - "outputs": [{ "internalType": "bool", "name": "isConverter", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], - "name": "removeTokenConverter", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/DefaultProxyAdmin.json b/multisig/simulations/opbnbmainnet/vip-021/abi/DefaultProxyAdmin.json deleted file mode 100644 index 9801cfcc7..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/DefaultProxyAdmin.json +++ /dev/null @@ -1,76 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "changeProxyAdmin", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" } - ], - "name": "upgrade", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" }, - { "internalType": "bytes", "name": "data", "type": "bytes" } - ], - "name": "upgradeAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/PoolRegistry.json b/multisig/simulations/opbnbmainnet/vip-021/abi/PoolRegistry.json deleted file mode 100644 index 31b1e2a17..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/PoolRegistry.json +++ /dev/null @@ -1,379 +0,0 @@ -[ - { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, - { - "name": "Unauthorized", - "type": "error", - "inputs": [ - { "name": "sender", "type": "address", "internalType": "address" }, - { "name": "calledContract", "type": "address", "internalType": "address" }, - { "name": "methodSignature", "type": "string", "internalType": "string" } - ] - }, - { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, - { - "name": "Initialized", - "type": "event", - "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], - "anonymous": false, - "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" - }, - { - "name": "MarketAdded", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" - }, - { - "name": "NewAccessControlManager", - "type": "event", - "inputs": [ - { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, - { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" - }, - { - "name": "OwnershipTransferStarted", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" - }, - { - "name": "OwnershipTransferred", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" - }, - { - "name": "PoolMetadataUpdated", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "oldMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - }, - { - "name": "newMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "anonymous": false, - "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" - }, - { - "name": "PoolNameSet", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, - { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } - ], - "anonymous": false, - "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" - }, - { - "name": "PoolRegistered", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "pool", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "anonymous": false, - "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" - }, - { - "name": "acceptOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x79ba5097", - "stateMutability": "nonpayable" - }, - { - "name": "accessControlManager", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "contract IAccessControlManagerV8" - } - ], - "constant": true, - "signature": "0xb4a0bdf3", - "stateMutability": "view" - }, - { - "name": "addMarket", - "type": "function", - "inputs": [ - { - "name": "input", - "type": "tuple", - "components": [ - { "name": "vToken", "type": "address", "internalType": "contract VToken" }, - { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, - { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, - { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, - { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, - { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistry.AddMarketInput" - } - ], - "outputs": [], - "signature": "0x23dc8d64", - "stateMutability": "nonpayable" - }, - { - "name": "addPool", - "type": "function", - "inputs": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, - { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, - { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } - ], - "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], - "signature": "0xeed873c2", - "stateMutability": "nonpayable" - }, - { - "name": "getAllPools", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "tuple[]", - "value": [], - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool[]" - } - ], - "constant": true, - "signature": "0xd88ff1f4", - "stateMutability": "view" - }, - { - "name": "getPoolByComptroller", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "constant": true, - "signature": "0x7aee632d", - "stateMutability": "view" - }, - { - "name": "getPoolsSupportedByAsset", - "type": "function", - "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], - "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], - "constant": true, - "signature": "0xf36dba38", - "stateMutability": "view" - }, - { - "name": "getVTokenForAsset", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "asset", "type": "address", "internalType": "address" } - ], - "outputs": [{ "name": "", "type": "address", "internalType": "address" }], - "constant": true, - "signature": "0x266e0a7f", - "stateMutability": "view" - }, - { - "name": "getVenusPoolMetadata", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "constant": true, - "signature": "0xa3aefa2c", - "stateMutability": "view" - }, - { - "name": "initialize", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xc4d66de8", - "stateMutability": "nonpayable" - }, - { - "name": "metadata", - "type": "function", - "inputs": [{ "name": "", "type": "address", "internalType": "address" }], - "outputs": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "constant": true, - "signature": "0x2ba21572", - "stateMutability": "view" - }, - { - "name": "owner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x8da5cb5b", - "stateMutability": "view" - }, - { - "name": "pendingOwner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0xe30c3978", - "stateMutability": "view" - }, - { - "name": "renounceOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x715018a6", - "stateMutability": "nonpayable" - }, - { - "name": "setAccessControlManager", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0x0e32cb86", - "stateMutability": "nonpayable" - }, - { - "name": "setPoolName", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "name", "type": "string", "internalType": "string" } - ], - "outputs": [], - "signature": "0x1cb6bb7e", - "stateMutability": "nonpayable" - }, - { - "name": "transferOwnership", - "type": "function", - "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xf2fde38b", - "stateMutability": "nonpayable" - }, - { - "name": "updatePoolMetadata", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { - "name": "metadata_", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "outputs": [], - "signature": "0xff94d958", - "stateMutability": "nonpayable" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/Prime.json b/multisig/simulations/opbnbmainnet/vip-021/abi/Prime.json deleted file mode 100644 index e8bfa99ff..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/Prime.json +++ /dev/null @@ -1,763 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, - { "internalType": "address", "name": "_nativeMarket", "type": "address" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, - { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, - { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, - { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, - { "internalType": "bool", "name": "_timeBased", "type": "bool" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, - { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidComptroller", "type": "error" }, - { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "n", "type": "uint256" }, - { "internalType": "uint256", "name": "d", "type": "uint256" } - ], - "name": "InvalidFraction", - "type": "error" - }, - { "inputs": [], "name": "InvalidLength", "type": "error" }, - { "inputs": [], "name": "InvalidLimit", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, - { "inputs": [], "name": "InvalidVToken", "type": "error" }, - { - "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], - "name": "LnNonRealResult", - "type": "error" - }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, - { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, - { "inputs": [], "name": "MarketNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, - { "inputs": [], "name": "WaitMoreTime", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, - { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } - ], - "name": "AlphaUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "Burn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "InterestClaimed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "MarketAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } - ], - "name": "MintLimitsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } - ], - "name": "MultiplierUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } - ], - "name": "StakedAtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "TokenUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "UserScoreUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "MAXIMUM_XVS_CAP", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MINIMUM_STAKED_XVS", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_MARKET", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "STAKING_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WRAPPED_NATIVE_TOKEN", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "accrueInterest", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" } - ], - "name": "accrueInterestAndUpdateScore", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "addMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "alphaDenominator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "alphaNumerator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "calculateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "claimTimeRemaining", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "uint256", "name": "borrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supply", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } - ], - "name": "estimateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "getInterestAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "getPendingRewards", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "internalType": "struct PrimeStorageV1.PendingReward[]", - "name": "pendingRewards", - "type": "tuple[]" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "incomeDistributionYearly", - "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "xvsVault_", "type": "address" }, - { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, - { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, - { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, - { "internalType": "address", "name": "comptroller_", "type": "address" }, - { "internalType": "address", "name": "oracle_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "name": "initializeV2", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "interests", - "outputs": [ - { "internalType": "uint256", "name": "accrued", "type": "uint256" }, - { "internalType": "uint256", "name": "score", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "irrevocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "", "type": "uint256" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "isScoreUpdated", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "isUserPrimeHolder", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, - { "internalType": "address[]", "name": "users", "type": "address[]" } - ], - "name": "issue", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, - { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, - { "internalType": "bool", "name": "exists", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "nextScoreUpdateRoundId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingScoreUpdates", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "primeLiquidityProvider", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "revocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } - ], - "name": "setLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "users", "type": "address[]" }, - { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } - ], - "name": "setStakedAt", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "stakedAt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokens", - "outputs": [ - { "internalType": "bool", "name": "exists", "type": "bool" }, - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalIrrevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalRevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalScoreUpdatesRequired", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "unreleasedPLPIncome", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, - { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } - ], - "name": "updateAlpha", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "updateMultipliers", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], - "name": "updateScores", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "vTokenForAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "xvsUpdated", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVault", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultPoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/PrimeLiquidityProvider.json b/multisig/simulations/opbnbmainnet/vip-021/abi/PrimeLiquidityProvider.json deleted file mode 100644 index 02ca8e0bf..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/PrimeLiquidityProvider.json +++ /dev/null @@ -1,385 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "_timeBased", "type": "bool" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, - { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "balance", "type": "uint256" } - ], - "name": "InsufficientBalance", - "type": "error" - }, - { "inputs": [], "name": "InvalidArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidCaller", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "speed", "type": "uint256" }, - { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } - ], - "name": "InvalidDistributionSpeed", - "type": "error" - }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenAlreadyInitialized", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "TokenNotInitialized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "MaxTokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } - ], - "name": "PrimeTokenUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenDistributionInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "TokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokenTransferredToPrime", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokensAccrued", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "accrueTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "getEffectiveDistributionSpeed", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], - "name": "initializeTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "lastAccruedBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastAccruedBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "maxTokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } - ], - "name": "setMaxTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } - ], - "name": "setTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, - { "internalType": "address", "name": "to_", "type": "address" }, - { "internalType": "uint256", "name": "amount_", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "tokenAmountAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/ProtocolShareReserve.json b/multisig/simulations/opbnbmainnet/vip-021/abi/ProtocolShareReserve.json deleted file mode 100644 index b33d7c495..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/ProtocolShareReserve.json +++ /dev/null @@ -1,356 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, - { "internalType": "address", "name": "_wbnb", "type": "address" }, - { "internalType": "address", "name": "_vbnb", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetReleased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IProtocolShareReserve.IncomeType", - "name": "incomeType", - "type": "uint8" - }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "AssetsReservesUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } - ], - "name": "PoolRegistryUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "ReservesUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "CORE_POOL_COMPTROLLER", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MAX_PERCENT", - "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "internalType": "struct ProtocolShareReserve.DistributionConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "addOrUpdateDistributionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } - ], - "name": "assetsReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "distributionTargets", - "outputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "getPercentageDistribution", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "getUnreleasedFunds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address[]", "name": "assets", "type": "address[]" } - ], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "name": "removeDistributionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], - "name": "setPoolRegistry", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAssetReserve", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalDistributions", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/RewardDistrbutor.json b/multisig/simulations/opbnbmainnet/vip-021/abi/RewardDistrbutor.json deleted file mode 100644 index 249fdd111..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/RewardDistrbutor.json +++ /dev/null @@ -1,532 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "BorrowLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "BorrowLastRewardingBlockUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "ContributorRewardTokenSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } - ], - "name": "ContributorRewardsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } - ], - "name": "DistributedBorrowerRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } - ], - "name": "DistributedSupplierRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "MarketInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "indexed": false, - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "RewardTokenBorrowIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenBorrowSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RewardTokenGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "RewardTokenSupplyIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenSupplySpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "SupplyLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "SupplyLastRewardingBlockUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "INITIAL_INDEX", - "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "holder", "type": "address" }, - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } - ], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "distributeBorrowerRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "supplier", "type": "address" } - ], - "name": "distributeSupplierRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "recipient", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "grantRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, - { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "initializeMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastContributorBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "rewardToken", - "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenBorrowerIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenContributorSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenSupplierIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplySpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contributor", "type": "address" }, - { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } - ], - "name": "setContributorRewardTokenSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } - ], - "name": "setLastRewardingBlockTimestamps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, - { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } - ], - "name": "setLastRewardingBlocks", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } - ], - "name": "setRewardTokenSpeeds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], - "name": "updateContributorRewards", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "updateRewardTokenBorrowIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "updateRewardTokenSupplyIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/SingleTokenConverter.json b/multisig/simulations/opbnbmainnet/vip-021/abi/SingleTokenConverter.json deleted file mode 100644 index 8ea10cc8d..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/SingleTokenConverter.json +++ /dev/null @@ -1,587 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } - ], - "name": "AmountInHigherThanMax", - "type": "error" - }, - { "inputs": [], "name": "AmountInMismatched", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } - ], - "name": "AmountOutLowerThanMinRequired", - "type": "error" - }, - { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, - { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, - { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, - { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, - { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, - { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } - ], - "name": "IncentiveTooHigh", - "type": "error" - }, - { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, - { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, - { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, - { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, - { "inputs": [], "name": "InvalidToAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, - { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetTransferredToDestination", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } - ], - "name": "BaseAssetUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "oldAccess", - "type": "uint8" - }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "newAccess", - "type": "uint8" - } - ], - "name": "ConversionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } - ], - "name": "ConverterNetworkAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } - ], - "name": "DestinationAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } - ], - "name": "MinAmountToConvertUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, - { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } - ], - "name": "PriceOracleUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "inputs": [], - "name": "MAX_INCENTIVE", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "baseAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "conversionConfigurations", - "outputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "conversionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "converterNetwork", - "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "destinationAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, - { "internalType": "address", "name": "destinationAddress_", "type": "address" }, - { "internalType": "address", "name": "baseAsset_", "type": "address" }, - { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "minAmountToConvert", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "priceOracle", - "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], - "name": "setBaseAsset", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig", - "name": "conversionConfig", - "type": "tuple" - } - ], - "name": "setConversionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", - "name": "conversionConfigs", - "type": "tuple[]" - } - ], - "name": "setConversionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], - "name": "setConverterNetwork", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], - "name": "setDestination", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], - "name": "setMinAmountToConvert", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/SingleTokenConverterBeacon.json b/multisig/simulations/opbnbmainnet/vip-021/abi/SingleTokenConverterBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/SingleTokenConverterBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/VToken.json b/multisig/simulations/opbnbmainnet/vip-021/abi/VToken.json deleted file mode 100644 index d8cc1aae4..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/VToken.json +++ /dev/null @@ -1,861 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], - "name": "AddReservesFactorFreshCheck", - "type": "error" - }, - { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, - { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, - { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], - "name": "LiquidateAccrueCollateralInterestFailed", - "type": "error" - }, - { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, - { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, - { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, - { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, - { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, - { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, - { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "AccrueInterest", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtRecovered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "Borrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "HealBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "LiquidateBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } - ], - "name": "NewComptroller", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "oldInterestRateModel", - "type": "address" - }, - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "newInterestRateModel", - "type": "address" - } - ], - "name": "NewMarketInterestRateModel", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } - ], - "name": "NewProtocolSeizeShare", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } - ], - "name": "NewProtocolShareReserve", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } - ], - "name": "NewReduceReservesBlockDelta", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } - ], - "name": "NewReserveFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } - ], - "name": "NewShortfallContract", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ProtocolSeize", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Redeem", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "RepayBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "ReservesAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "SpreadReservesReduced", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Transfer", - "type": "event" - }, - { - "inputs": [], - "name": "NO_ERROR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrualBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrueInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], - "name": "addReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "owner", "type": "address" }, - { "internalType": "address", "name": "spender", "type": "address" } - ], - "name": "allowance", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "approve", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "badDebt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], - "name": "badDebtRecovered", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOfUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], - "name": "borrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "borrowIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "borrowRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } - ], - "name": "decreaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "forceLiquidateBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountSnapshot", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCash", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "healBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "addedValue", "type": "uint256" } - ], - "name": "increaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "underlying_", "type": "address" }, - { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, - { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, - { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, - { "internalType": "string", "name": "name_", "type": "string" }, - { "internalType": "string", "name": "symbol_", "type": "string" }, - { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, - { "internalType": "address", "name": "admin_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { - "components": [ - { "internalType": "address", "name": "shortfall", "type": "address" }, - { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } - ], - "internalType": "struct VTokenInterface.RiskManagementInit", - "name": "riskManagement", - "type": "tuple" - }, - { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "interestRateModel", - "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isVToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } - ], - "name": "liquidateBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], - "name": "mint", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "mintBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolSeizeShareMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolShareReserve", - "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], - "name": "redeem", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], - "name": "redeemUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } - ], - "name": "redeemUnderlyingBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], - "name": "reduceReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockDelta", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], - "name": "repayBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "repayBorrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reserveFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], - "name": "setInterestRateModel", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], - "name": "setProtocolSeizeShare", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], - "name": "setProtocolShareReserve", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], - "name": "setReduceReservesBlockDelta", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], - "name": "setReserveFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], - "name": "setShortfallContract", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "shortfall", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "supplyRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrows", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrowsCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "totalReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transfer", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transferFrom", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "underlying", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/VTokenBeacon.json b/multisig/simulations/opbnbmainnet/vip-021/abi/VTokenBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/VTokenBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/XVSStore.json b/multisig/simulations/opbnbmainnet/vip-021/abi/XVSStore.json deleted file mode 100644 index 2d9ea2bb2..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/XVSStore.json +++ /dev/null @@ -1,130 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "AdminTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } - ], - "name": "NewPendingAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnerTransferred", - "type": "event" - }, - { - "constant": false, - "inputs": [], - "name": "acceptAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "emergencyRewardWithdraw", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokens", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "token", "type": "address" }, - { "internalType": "address", "name": "_to", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "safeRewardTransfer", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], - "name": "setNewOwner", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], - "name": "setPendingAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "bool", "name": "status", "type": "bool" } - ], - "name": "setRewardToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/XVSVault.json b/multisig/simulations/opbnbmainnet/vip-021/abi/XVSVault.json deleted file mode 100644 index 51d8d540c..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/XVSVault.json +++ /dev/null @@ -1,787 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Claim", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } - ], - "name": "DelegateChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "DelegateVotesChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Deposit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ExecutedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "name": "PoolAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } - ], - "name": "PoolUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RequestedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } - ], - "name": "RewardAmountUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } - ], - "name": "StoreUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } - ], - "name": "VaultDebtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } - ], - "name": "WithdrawalLockingPeriodUpdated", - "type": "event" - }, - { - "constant": true, - "inputs": [], - "name": "DELEGATION_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "DOMAIN_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "MAX_LOCK_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "SECONDS_PER_YEAR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], - "name": "_become", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, - { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, - { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } - ], - "name": "add", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint32", "name": "", "type": "uint32" } - ], - "name": "checkpoints", - "outputs": [ - { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, - { "internalType": "uint96", "name": "votes", "type": "uint96" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_account", "type": "address" }, - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "claim", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], - "name": "delegate", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "delegatee", "type": "address" }, - { "internalType": "uint256", "name": "nonce", "type": "uint256" }, - { "internalType": "uint256", "name": "expiry", "type": "uint256" }, - { "internalType": "uint8", "name": "v", "type": "uint8" }, - { "internalType": "bytes32", "name": "r", "type": "bytes32" }, - { "internalType": "bytes32", "name": "s", "type": "bytes32" } - ], - "name": "delegateBySig", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "delegates", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "deposit", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "executeWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getCurrentVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getEligibleWithdrawalAmount", - "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } - ], - "name": "getPriorVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getRequestedAmount", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getUserInfo", - "outputs": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, - { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getWithdrawalRequests", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, - { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } - ], - "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", - "name": "", - "type": "tuple[]" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "name": "initializeTimeManager", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isStakedToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "nonces", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "numCheckpoints", - "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "pause", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingReward", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "pendingRewardTransfers", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingWithdrawalsBeforeUpgrade", - "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingXVSVaultImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "poolInfos", - "outputs": [ - { "internalType": "contract IBEP20", "name": "token", "type": "address" }, - { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, - { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], - "name": "poolLength", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primePoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeToken", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "requestWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "resume", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], - "name": "rewardTokenAmountsPerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAmountsPerBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } - ], - "name": "set", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], - "name": "setAccessControl", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, - { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } - ], - "name": "setPrimeToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } - ], - "name": "setRewardAmountPerBlockOrSecond", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } - ], - "name": "setWithdrawalLockingPeriod", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_xvs", "type": "address" }, - { "internalType": "address", "name": "_xvsStore", "type": "address" } - ], - "name": "setXvsStore", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAllocPoints", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "totalPendingWithdrawals", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "updatePool", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "vaultPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsStore", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/boundValidator.json b/multisig/simulations/opbnbmainnet/vip-021/abi/boundValidator.json deleted file mode 100644 index d16c8fb08..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/boundValidator.json +++ /dev/null @@ -1,498 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "previousAdmin", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAdmin", - "type": "address" - } - ], - "name": "AdminChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "beacon", - "type": "address" - } - ], - "name": "BeaconUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "implementation", - "type": "address" - } - ], - "name": "Upgraded", - "type": "event" - }, - { - "stateMutability": "payable", - "type": "fallback" - }, - { - "inputs": [], - "name": "admin", - "outputs": [ - { - "internalType": "address", - "name": "admin_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [ - { - "internalType": "address", - "name": "implementation_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - } - ], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - }, - { - "internalType": "bytes", - "name": "data", - "type": "bytes" - } - ], - "name": "upgradeToAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "upperBound", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "lowerBound", - "type": "uint256" - } - ], - "name": "ValidateConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig", - "name": "config", - "type": "tuple" - } - ], - "name": "setValidateConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "setValidateConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "validateConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "reportedPrice", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "anchorPrice", - "type": "uint256" - } - ], - "name": "validatePriceWithAnchorPrice", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_logic", - "type": "address" - }, - { - "internalType": "address", - "name": "admin_", - "type": "address" - }, - { - "internalType": "bytes", - "name": "_data", - "type": "bytes" - } - ], - "stateMutability": "payable", - "type": "constructor" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/chainlinkOracle.json b/multisig/simulations/opbnbmainnet/vip-021/abi/chainlinkOracle.json deleted file mode 100644 index cdd689acb..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/chainlinkOracle.json +++ /dev/null @@ -1,459 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "vBnbAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "previousPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "requestedPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newPriceMantissa", - "type": "uint256" - } - ], - "name": "PricePosted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManager", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "prices", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - } - ], - "name": "setDirectPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VBep20Interface", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "underlyingPriceMantissa", - "type": "uint256" - } - ], - "name": "setUnderlyingPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "tokenConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/resilientOracle.json b/multisig/simulations/opbnbmainnet/vip-021/abi/resilientOracle.json deleted file mode 100644 index 35f52caa0..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/resilientOracle.json +++ /dev/null @@ -1,640 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "nativeMarketAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - }, - { - "internalType": "contract BoundValidatorInterface", - "name": "_boundValidator", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "OracleEnabled", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - } - ], - "name": "OracleSet", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "mainOracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "pivotOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "fallbackOracle", - "type": "address" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "INVALID_PRICE", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_TOKEN_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "boundValidator", - "outputs": [ - { - "internalType": "contract BoundValidatorInterface", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - }, - { - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "enableOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "getOracle", - "outputs": [ - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "bool", - "name": "enabled", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getTokenConfig", - "outputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "nativeMarket", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "setOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "updateAssetPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "updatePrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/sFrxETHOracle.json b/multisig/simulations/opbnbmainnet/vip-021/abi/sFrxETHOracle.json deleted file mode 100644 index b461549ba..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/sFrxETHOracle.json +++ /dev/null @@ -1,148 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_sfrxEthFraxOracle", "type": "address" }, - { "internalType": "address", "name": "_sfrxETH", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "BadPriceData", "type": "error" }, - { "inputs": [], "name": "InvalidTokenAddress", "type": "error" }, - { "inputs": [], "name": "PriceDifferenceExceeded", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxAllowedPriceDifference", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxAllowedPriceDifference", "type": "uint256" } - ], - "name": "MaxAllowedPriceDifferenceUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [], - "name": "SFRXETH", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "SFRXETH_FRAX_ORACLE", - "outputs": [{ "internalType": "contract ISfrxEthFraxOracle", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], - "name": "getPrice", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxAllowedPriceDifference", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" }], - "name": "setMaxAllowedPriceDifference", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/treasury.json b/multisig/simulations/opbnbmainnet/vip-021/abi/treasury.json deleted file mode 100644 index 18aabb61a..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/treasury.json +++ /dev/null @@ -1,86 +0,0 @@ -[ - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryNative", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryToken", - "type": "event" - }, - { "stateMutability": "payable", "type": "fallback" }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryNative", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "stateMutability": "payable", "type": "receive" } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/xvs.json b/multisig/simulations/opbnbmainnet/vip-021/abi/xvs.json deleted file mode 100644 index 69092bb4a..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/xvs.json +++ /dev/null @@ -1,716 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user", - "type": "address" - } - ], - "name": "AccountBlacklisted", - "type": "error" - }, - { - "inputs": [], - "name": "AddressesMustDiffer", - "type": "error" - }, - { - "inputs": [], - "name": "MintLimitExceed", - "type": "error" - }, - { - "inputs": [], - "name": "MintedAmountExceed", - "type": "error" - }, - { - "inputs": [], - "name": "NewCapNotGreaterThanMintedTokens", - "type": "error" - }, - { - "inputs": [], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "user", - "type": "address" - }, - { - "indexed": false, - "internalType": "bool", - "name": "value", - "type": "bool" - } - ], - "name": "BlacklistUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "MintCapChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitDecreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "source", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "destination", - "type": "address" - } - ], - "name": "MintedTokensMigrated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Transfer", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "internalType": "address", - "name": "spender", - "type": "address" - } - ], - "name": "allowance", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "approve", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [ - { - "internalType": "uint8", - "name": "", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "subtractedValue", - "type": "uint256" - } - ], - "name": "decreaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "addedValue", - "type": "uint256" - } - ], - "name": "increaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - } - ], - "name": "isBlackListed", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "source_", - "type": "address" - }, - { - "internalType": "address", - "name": "destination_", - "type": "address" - } - ], - "name": "migrateMinterTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "mint", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToCap", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToMintedAmount", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newAccessControlAddress_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "minter_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "setMintCap", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transfer", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transferFrom", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - }, - { - "internalType": "bool", - "name": "value_", - "type": "bool" - } - ], - "name": "updateBlacklist", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/abi/xvsBridgeAdmin.json b/multisig/simulations/opbnbmainnet/vip-021/abi/xvsBridgeAdmin.json deleted file mode 100644 index 024450a40..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/abi/xvsBridgeAdmin.json +++ /dev/null @@ -1,329 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "XVSBridge_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "string", - "name": "signature", - "type": "string" - }, - { - "indexed": false, - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "name": "FunctionRegistryChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "stateMutability": "nonpayable", - "type": "fallback" - }, - { - "inputs": [], - "name": "XVSBridge", - "outputs": [ - { - "internalType": "contract IXVSProxyOFT", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes4", - "name": "", - "type": "bytes4" - } - ], - "name": "functionRegistry", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "isTrustedRemote", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner_", - "type": "address" - } - ], - "name": "transferBridgeOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "string[]", - "name": "signatures_", - "type": "string[]" - }, - { - "internalType": "bool[]", - "name": "active_", - "type": "bool[]" - } - ], - "name": "upsertSignature", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-021/index.ts b/multisig/simulations/opbnbmainnet/vip-021/index.ts deleted file mode 100644 index 1694093ab..000000000 --- a/multisig/simulations/opbnbmainnet/vip-021/index.ts +++ /dev/null @@ -1,181 +0,0 @@ -import { expect } from "chai"; -import { Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip } from "src/vip-framework"; - -import vip021, { - BOUND_VALIDATOR, - COMPTROLLERS, - COMPTROLLER_BEACON, - DEFAULT_PROXY_ADMIN, - PSR, - VTOKENS, - VTOKEN_BEACON, - XVS, - XVS_BRIDGE_ADMIN_PROXY, - XVS_STORE, -} from "../../../proposals/opbnbmainnet/vip-021"; -import COMPTROLLER_ABI from "./abi/Comptroller.json"; -import COMPTROLLER_BEACON_ABI from "./abi/ComptrollerBeacon.json"; -import DEFAULT_PROXY_ADMIN_ABI from "./abi/DefaultProxyAdmin.json"; -import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; -import PSR_ABI from "./abi/ProtocolShareReserve.json"; -import VTOKEN_ABI from "./abi/VToken.json"; -import VTOKEN_BEACON_ABI from "./abi/VTokenBeacon.json"; -import XVS_STORE_ABI from "./abi/XVSStore.json"; -import XVS_VAULT_ABI from "./abi/XVSVault.json"; -import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; -import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; -import TREASURY_ABI from "./abi/treasury.json"; -import XVS_ABI from "./abi/xvs.json"; -import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; - -const { opbnbmainnet } = NETWORK_ADDRESSES; - -const RESILIENT_ORACLE = opbnbmainnet.RESILIENT_ORACLE; -const NORMAL_TIMELOCK = opbnbmainnet.NORMAL_TIMELOCK; - -forking(28761242, async () => { - const provider = ethers.provider; - let proxyAdmin: Contract; - let psr: Contract; - let comptrollerBeacon: Contract; - let vTokenBeacon: Contract; - let poolRegistry: Contract; - let xvsVault: Contract; - let xvsStore: Contract; - let xvs: Contract; - let xvsBridgeAdmin: Contract; - let resilientOracle: Contract; - let boundValidator: Contract; - let treasury: Contract; - - describe("Pre-VIP behavior", async () => { - before(async () => { - proxyAdmin = new ethers.Contract(DEFAULT_PROXY_ADMIN, DEFAULT_PROXY_ADMIN_ABI, provider); - psr = new ethers.Contract(PSR, PSR_ABI, provider); - comptrollerBeacon = new ethers.Contract(COMPTROLLER_BEACON, COMPTROLLER_BEACON_ABI, provider); - vTokenBeacon = new ethers.Contract(VTOKEN_BEACON, VTOKEN_BEACON_ABI, provider); - poolRegistry = new ethers.Contract(opbnbmainnet.POOL_REGISTRY, POOL_REGISTRY_ABI, provider); - xvsVault = new ethers.Contract(opbnbmainnet.XVS_VAULT_PROXY, XVS_VAULT_ABI, provider); - xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); - xvs = await ethers.getContractAt(XVS_ABI, XVS); - xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, XVS_BRIDGE_ADMIN_PROXY); - resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); - boundValidator = new ethers.Contract(BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); - treasury = await ethers.getContractAt(TREASURY_ABI, NETWORK_ADDRESSES.opbnbmainnet.VTREASURY); - }); - - it("owner of proxy admin is guardian", async () => { - expect(await proxyAdmin.owner()).to.equal(opbnbmainnet.GUARDIAN); - }); - - it("pending owner of psr", async () => { - expect(await psr.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`should have no pending owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`should have no pending owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - it("owner of ComptrollerBeacon is guardian", async () => { - expect(await comptrollerBeacon.owner()).to.equal(opbnbmainnet.GUARDIAN); - }); - - it("owner of VTokenBeacon is guardian", async () => { - expect(await vTokenBeacon.owner()).to.equal(opbnbmainnet.GUARDIAN); - }); - - it("pending owner of PoolRegistry", async () => { - expect(await poolRegistry.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - it("should have no pending owner", async () => { - expect(await xvsVault.pendingAdmin()).to.equal(ethers.constants.AddressZero); - }); - - it("should have no pending owner", async () => { - expect(await xvsStore.pendingAdmin()).to.equal(ethers.constants.AddressZero); - }); - - it("should have no pending owner", async () => { - expect(await resilientOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await boundValidator.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - }); - - describe("Post-VIP behavior", async () => { - before(async () => { - await pretendExecutingVip(await vip021()); - }); - - it("owner of proxy admin is timelock", async () => { - expect(await proxyAdmin.owner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); - }); - - it("pending owner of psr", async () => { - expect(await psr.pendingOwner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`correct pending owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.pendingOwner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`correct pending owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.pendingOwner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); - }); - } - - it("owner of ComptrollerBeacon is NT", async () => { - expect(await comptrollerBeacon.owner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); - }); - - it("owner of VTokenBeacon is NT", async () => { - expect(await vTokenBeacon.owner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); - }); - - it("pending owner of PoolRegistry is NT", async () => { - expect(await poolRegistry.pendingOwner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); - }); - - it("correct pending owner", async () => { - expect(await xvsVault.pendingAdmin()).to.equal(NORMAL_TIMELOCK); - }); - - it("correct pending owner", async () => { - expect(await xvsStore.pendingAdmin()).to.equal(NORMAL_TIMELOCK); - }); - - it("Should set bridge pending owner to Normal Timelock", async () => { - const pendingOwner = await xvsBridgeAdmin.pendingOwner(); - expect(pendingOwner).equals(opbnbmainnet.NORMAL_TIMELOCK); - }); - it("Should set XVS owner to Normal Timelock", async () => { - const owner = await xvs.owner(); - expect(owner).equals(opbnbmainnet.NORMAL_TIMELOCK); - }); - it("correct pending owner", async () => { - expect(await resilientOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); - expect(await boundValidator.pendingOwner()).to.equal(NORMAL_TIMELOCK); - }); - it("Should set pendingOwner to Normal Timelock", async () => { - const pendingOwner = await treasury.pendingOwner(); - expect(pendingOwner).equals(NETWORK_ADDRESSES.opbnbmainnet.NORMAL_TIMELOCK); - }); - }); -}); diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/Comptroller.json b/multisig/simulations/opbnbtestnet/vip-021/abi/Comptroller.json deleted file mode 100644 index f3b2445ac..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/Comptroller.json +++ /dev/null @@ -1,929 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "ActionPaused", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "BorrowCapExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "CollateralExceedsThreshold", - "type": "error" - }, - { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, - { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, - { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } - ], - "name": "InsufficientCollateral", - "type": "error" - }, - { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, - { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, - { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, - { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketAlreadyListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "MarketNotCollateral", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketNotListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "MinimalCollateralViolated", - "type": "error" - }, - { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "PriceError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "SnapshotError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "SupplyCapExceeded", - "type": "error" - }, - { "inputs": [], "name": "TooMuchRepay", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "expectedSender", "type": "address" }, - { "internalType": "address", "name": "actualSender", "type": "address" } - ], - "name": "UnexpectedSender", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, - { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } - ], - "name": "ActionPausedMarket", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "DelegateUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "IsForcedLiquidationEnabledUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketEntered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketExited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "MarketSupported", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } - ], - "name": "NewBorrowCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } - ], - "name": "NewCloseFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } - ], - "name": "NewCollateralFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } - ], - "name": "NewLiquidationIncentive", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "NewLiquidationThreshold", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } - ], - "name": "NewMinLiquidatableCollateral", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "oldPriceOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "newPriceOracle", - "type": "address" - } - ], - "name": "NewPriceOracle", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } - ], - "name": "NewRewardsDistributor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } - ], - "name": "NewSupplyCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "accountAssets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "actionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], - "name": "addRewardsDistributor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "allMarkets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "approvedDelegates", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "borrowCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "contract VToken", "name": "vToken", "type": "address" } - ], - "name": "checkMembership", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "closeFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], - "name": "enterMarkets", - "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], - "name": "exitMarket", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAssetsIn", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getBorrowingPower", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "address", "name": "vTokenModify", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "getHypotheticalAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getRewardDistributors", - "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "getRewardsByMarket", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.RewardSpeeds[]", - "name": "rewardSpeeds", - "type": "tuple[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "healAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isComptroller", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isForcedLiquidationEnabled", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "isMarketListed", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [ - { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.LiquidationOrder[]", - "name": "orders", - "type": "tuple[]" - } - ], - "name": "liquidateAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "liquidateBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } - ], - "name": "liquidateCalculateSeizeTokens", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "liquidationIncentiveMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "bool", "name": "isListed", "type": "bool" }, - { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "minLiquidatableCollateral", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } - ], - "name": "mintVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "preBorrowHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "preLiquidateHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "preMintHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "preRedeemHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preRepayHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "seizerContract", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preSeizeHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "preTransferHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } - ], - "name": "repayBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seizeVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, - { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, - { "internalType": "bool", "name": "paused", "type": "bool" } - ], - "name": "setActionsPaused", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], - "name": "setCloseFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "setCollateralFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "setForcedLiquidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], - "name": "setLiquidationIncentive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } - ], - "name": "setMarketBorrowCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } - ], - "name": "setMarketSupplyCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], - "name": "setMinLiquidatableCollateral", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "supplyCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "supportMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "transferVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "delegate", "type": "address" }, - { "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "updateDelegate", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "updatePrices", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/ComptrollerBeacon.json b/multisig/simulations/opbnbtestnet/vip-021/abi/ComptrollerBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/ComptrollerBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/ConverterNetwork.json b/multisig/simulations/opbnbtestnet/vip-021/abi/ConverterNetwork.json deleted file mode 100644 index 396f12a91..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/ConverterNetwork.json +++ /dev/null @@ -1,205 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { "inputs": [], "name": "ConverterAlreadyExists", "type": "error" }, - { "inputs": [], "name": "ConverterDoesNotExist", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "InvalidMaxLoopsLimit", - "type": "error" - }, - { "inputs": [], "name": "InvalidTokenConverterAddress", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], - "name": "ConverterAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], - "name": "ConverterRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], - "name": "addTokenConverter", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "allConverters", - "outputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } - ], - "name": "findTokenConverters", - "outputs": [ - { "internalType": "address[]", "name": "converters", "type": "address[]" }, - { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } - ], - "name": "findTokenConvertersForConverters", - "outputs": [ - { "internalType": "address[]", "name": "converters", "type": "address[]" }, - { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getAllConverters", - "outputs": [{ "internalType": "contract IAbstractTokenConverter[]", "name": "converters", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_tokenConverter", "type": "address" }], - "name": "isTokenConverter", - "outputs": [{ "internalType": "bool", "name": "isConverter", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], - "name": "removeTokenConverter", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/DefaultProxyAdmin.json b/multisig/simulations/opbnbtestnet/vip-021/abi/DefaultProxyAdmin.json deleted file mode 100644 index 9801cfcc7..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/DefaultProxyAdmin.json +++ /dev/null @@ -1,76 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "changeProxyAdmin", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" } - ], - "name": "upgrade", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" }, - { "internalType": "bytes", "name": "data", "type": "bytes" } - ], - "name": "upgradeAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/PoolRegistry.json b/multisig/simulations/opbnbtestnet/vip-021/abi/PoolRegistry.json deleted file mode 100644 index 31b1e2a17..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/PoolRegistry.json +++ /dev/null @@ -1,379 +0,0 @@ -[ - { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, - { - "name": "Unauthorized", - "type": "error", - "inputs": [ - { "name": "sender", "type": "address", "internalType": "address" }, - { "name": "calledContract", "type": "address", "internalType": "address" }, - { "name": "methodSignature", "type": "string", "internalType": "string" } - ] - }, - { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, - { - "name": "Initialized", - "type": "event", - "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], - "anonymous": false, - "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" - }, - { - "name": "MarketAdded", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" - }, - { - "name": "NewAccessControlManager", - "type": "event", - "inputs": [ - { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, - { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" - }, - { - "name": "OwnershipTransferStarted", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" - }, - { - "name": "OwnershipTransferred", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" - }, - { - "name": "PoolMetadataUpdated", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "oldMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - }, - { - "name": "newMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "anonymous": false, - "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" - }, - { - "name": "PoolNameSet", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, - { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } - ], - "anonymous": false, - "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" - }, - { - "name": "PoolRegistered", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "pool", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "anonymous": false, - "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" - }, - { - "name": "acceptOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x79ba5097", - "stateMutability": "nonpayable" - }, - { - "name": "accessControlManager", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "contract IAccessControlManagerV8" - } - ], - "constant": true, - "signature": "0xb4a0bdf3", - "stateMutability": "view" - }, - { - "name": "addMarket", - "type": "function", - "inputs": [ - { - "name": "input", - "type": "tuple", - "components": [ - { "name": "vToken", "type": "address", "internalType": "contract VToken" }, - { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, - { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, - { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, - { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, - { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistry.AddMarketInput" - } - ], - "outputs": [], - "signature": "0x23dc8d64", - "stateMutability": "nonpayable" - }, - { - "name": "addPool", - "type": "function", - "inputs": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, - { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, - { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } - ], - "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], - "signature": "0xeed873c2", - "stateMutability": "nonpayable" - }, - { - "name": "getAllPools", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "tuple[]", - "value": [], - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool[]" - } - ], - "constant": true, - "signature": "0xd88ff1f4", - "stateMutability": "view" - }, - { - "name": "getPoolByComptroller", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "constant": true, - "signature": "0x7aee632d", - "stateMutability": "view" - }, - { - "name": "getPoolsSupportedByAsset", - "type": "function", - "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], - "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], - "constant": true, - "signature": "0xf36dba38", - "stateMutability": "view" - }, - { - "name": "getVTokenForAsset", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "asset", "type": "address", "internalType": "address" } - ], - "outputs": [{ "name": "", "type": "address", "internalType": "address" }], - "constant": true, - "signature": "0x266e0a7f", - "stateMutability": "view" - }, - { - "name": "getVenusPoolMetadata", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "constant": true, - "signature": "0xa3aefa2c", - "stateMutability": "view" - }, - { - "name": "initialize", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xc4d66de8", - "stateMutability": "nonpayable" - }, - { - "name": "metadata", - "type": "function", - "inputs": [{ "name": "", "type": "address", "internalType": "address" }], - "outputs": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "constant": true, - "signature": "0x2ba21572", - "stateMutability": "view" - }, - { - "name": "owner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x8da5cb5b", - "stateMutability": "view" - }, - { - "name": "pendingOwner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0xe30c3978", - "stateMutability": "view" - }, - { - "name": "renounceOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x715018a6", - "stateMutability": "nonpayable" - }, - { - "name": "setAccessControlManager", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0x0e32cb86", - "stateMutability": "nonpayable" - }, - { - "name": "setPoolName", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "name", "type": "string", "internalType": "string" } - ], - "outputs": [], - "signature": "0x1cb6bb7e", - "stateMutability": "nonpayable" - }, - { - "name": "transferOwnership", - "type": "function", - "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xf2fde38b", - "stateMutability": "nonpayable" - }, - { - "name": "updatePoolMetadata", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { - "name": "metadata_", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "outputs": [], - "signature": "0xff94d958", - "stateMutability": "nonpayable" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/Prime.json b/multisig/simulations/opbnbtestnet/vip-021/abi/Prime.json deleted file mode 100644 index e8bfa99ff..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/Prime.json +++ /dev/null @@ -1,763 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, - { "internalType": "address", "name": "_nativeMarket", "type": "address" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, - { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, - { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, - { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, - { "internalType": "bool", "name": "_timeBased", "type": "bool" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, - { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidComptroller", "type": "error" }, - { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "n", "type": "uint256" }, - { "internalType": "uint256", "name": "d", "type": "uint256" } - ], - "name": "InvalidFraction", - "type": "error" - }, - { "inputs": [], "name": "InvalidLength", "type": "error" }, - { "inputs": [], "name": "InvalidLimit", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, - { "inputs": [], "name": "InvalidVToken", "type": "error" }, - { - "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], - "name": "LnNonRealResult", - "type": "error" - }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, - { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, - { "inputs": [], "name": "MarketNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, - { "inputs": [], "name": "WaitMoreTime", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, - { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } - ], - "name": "AlphaUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "Burn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "InterestClaimed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "MarketAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } - ], - "name": "MintLimitsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } - ], - "name": "MultiplierUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } - ], - "name": "StakedAtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "TokenUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "UserScoreUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "MAXIMUM_XVS_CAP", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MINIMUM_STAKED_XVS", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_MARKET", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "STAKING_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WRAPPED_NATIVE_TOKEN", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "accrueInterest", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" } - ], - "name": "accrueInterestAndUpdateScore", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "addMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "alphaDenominator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "alphaNumerator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "calculateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "claimTimeRemaining", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "uint256", "name": "borrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supply", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } - ], - "name": "estimateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "getInterestAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "getPendingRewards", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "internalType": "struct PrimeStorageV1.PendingReward[]", - "name": "pendingRewards", - "type": "tuple[]" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "incomeDistributionYearly", - "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "xvsVault_", "type": "address" }, - { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, - { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, - { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, - { "internalType": "address", "name": "comptroller_", "type": "address" }, - { "internalType": "address", "name": "oracle_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "name": "initializeV2", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "interests", - "outputs": [ - { "internalType": "uint256", "name": "accrued", "type": "uint256" }, - { "internalType": "uint256", "name": "score", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "irrevocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "", "type": "uint256" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "isScoreUpdated", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "isUserPrimeHolder", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, - { "internalType": "address[]", "name": "users", "type": "address[]" } - ], - "name": "issue", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, - { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, - { "internalType": "bool", "name": "exists", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "nextScoreUpdateRoundId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingScoreUpdates", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "primeLiquidityProvider", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "revocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } - ], - "name": "setLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "users", "type": "address[]" }, - { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } - ], - "name": "setStakedAt", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "stakedAt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokens", - "outputs": [ - { "internalType": "bool", "name": "exists", "type": "bool" }, - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalIrrevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalRevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalScoreUpdatesRequired", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "unreleasedPLPIncome", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, - { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } - ], - "name": "updateAlpha", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "updateMultipliers", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], - "name": "updateScores", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "vTokenForAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "xvsUpdated", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVault", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultPoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/PrimeLiquidityProvider.json b/multisig/simulations/opbnbtestnet/vip-021/abi/PrimeLiquidityProvider.json deleted file mode 100644 index 02ca8e0bf..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/PrimeLiquidityProvider.json +++ /dev/null @@ -1,385 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "_timeBased", "type": "bool" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, - { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "balance", "type": "uint256" } - ], - "name": "InsufficientBalance", - "type": "error" - }, - { "inputs": [], "name": "InvalidArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidCaller", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "speed", "type": "uint256" }, - { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } - ], - "name": "InvalidDistributionSpeed", - "type": "error" - }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenAlreadyInitialized", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "TokenNotInitialized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "MaxTokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } - ], - "name": "PrimeTokenUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenDistributionInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "TokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokenTransferredToPrime", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokensAccrued", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "accrueTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "getEffectiveDistributionSpeed", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], - "name": "initializeTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "lastAccruedBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastAccruedBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "maxTokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } - ], - "name": "setMaxTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } - ], - "name": "setTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, - { "internalType": "address", "name": "to_", "type": "address" }, - { "internalType": "uint256", "name": "amount_", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "tokenAmountAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/ProtocolShareReserve.json b/multisig/simulations/opbnbtestnet/vip-021/abi/ProtocolShareReserve.json deleted file mode 100644 index b33d7c495..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/ProtocolShareReserve.json +++ /dev/null @@ -1,356 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, - { "internalType": "address", "name": "_wbnb", "type": "address" }, - { "internalType": "address", "name": "_vbnb", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetReleased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IProtocolShareReserve.IncomeType", - "name": "incomeType", - "type": "uint8" - }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "AssetsReservesUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } - ], - "name": "PoolRegistryUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "ReservesUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "CORE_POOL_COMPTROLLER", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MAX_PERCENT", - "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "internalType": "struct ProtocolShareReserve.DistributionConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "addOrUpdateDistributionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } - ], - "name": "assetsReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "distributionTargets", - "outputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "getPercentageDistribution", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "getUnreleasedFunds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address[]", "name": "assets", "type": "address[]" } - ], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "name": "removeDistributionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], - "name": "setPoolRegistry", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAssetReserve", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalDistributions", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/RewardDistrbutor.json b/multisig/simulations/opbnbtestnet/vip-021/abi/RewardDistrbutor.json deleted file mode 100644 index 249fdd111..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/RewardDistrbutor.json +++ /dev/null @@ -1,532 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "BorrowLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "BorrowLastRewardingBlockUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "ContributorRewardTokenSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } - ], - "name": "ContributorRewardsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } - ], - "name": "DistributedBorrowerRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } - ], - "name": "DistributedSupplierRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "MarketInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "indexed": false, - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "RewardTokenBorrowIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenBorrowSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RewardTokenGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "RewardTokenSupplyIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenSupplySpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "SupplyLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "SupplyLastRewardingBlockUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "INITIAL_INDEX", - "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "holder", "type": "address" }, - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } - ], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "distributeBorrowerRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "supplier", "type": "address" } - ], - "name": "distributeSupplierRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "recipient", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "grantRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, - { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "initializeMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastContributorBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "rewardToken", - "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenBorrowerIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenContributorSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenSupplierIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplySpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contributor", "type": "address" }, - { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } - ], - "name": "setContributorRewardTokenSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } - ], - "name": "setLastRewardingBlockTimestamps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, - { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } - ], - "name": "setLastRewardingBlocks", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } - ], - "name": "setRewardTokenSpeeds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], - "name": "updateContributorRewards", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "updateRewardTokenBorrowIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "updateRewardTokenSupplyIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/SingleTokenConverter.json b/multisig/simulations/opbnbtestnet/vip-021/abi/SingleTokenConverter.json deleted file mode 100644 index 8ea10cc8d..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/SingleTokenConverter.json +++ /dev/null @@ -1,587 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } - ], - "name": "AmountInHigherThanMax", - "type": "error" - }, - { "inputs": [], "name": "AmountInMismatched", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } - ], - "name": "AmountOutLowerThanMinRequired", - "type": "error" - }, - { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, - { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, - { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, - { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, - { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, - { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } - ], - "name": "IncentiveTooHigh", - "type": "error" - }, - { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, - { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, - { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, - { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, - { "inputs": [], "name": "InvalidToAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, - { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetTransferredToDestination", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } - ], - "name": "BaseAssetUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "oldAccess", - "type": "uint8" - }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "newAccess", - "type": "uint8" - } - ], - "name": "ConversionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } - ], - "name": "ConverterNetworkAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } - ], - "name": "DestinationAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } - ], - "name": "MinAmountToConvertUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, - { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } - ], - "name": "PriceOracleUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "inputs": [], - "name": "MAX_INCENTIVE", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "baseAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "conversionConfigurations", - "outputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "conversionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "converterNetwork", - "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "destinationAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, - { "internalType": "address", "name": "destinationAddress_", "type": "address" }, - { "internalType": "address", "name": "baseAsset_", "type": "address" }, - { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "minAmountToConvert", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "priceOracle", - "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], - "name": "setBaseAsset", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig", - "name": "conversionConfig", - "type": "tuple" - } - ], - "name": "setConversionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", - "name": "conversionConfigs", - "type": "tuple[]" - } - ], - "name": "setConversionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], - "name": "setConverterNetwork", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], - "name": "setDestination", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], - "name": "setMinAmountToConvert", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/SingleTokenConverterBeacon.json b/multisig/simulations/opbnbtestnet/vip-021/abi/SingleTokenConverterBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/SingleTokenConverterBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/VToken.json b/multisig/simulations/opbnbtestnet/vip-021/abi/VToken.json deleted file mode 100644 index d8cc1aae4..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/VToken.json +++ /dev/null @@ -1,861 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], - "name": "AddReservesFactorFreshCheck", - "type": "error" - }, - { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, - { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, - { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], - "name": "LiquidateAccrueCollateralInterestFailed", - "type": "error" - }, - { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, - { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, - { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, - { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, - { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, - { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, - { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "AccrueInterest", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtRecovered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "Borrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "HealBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "LiquidateBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } - ], - "name": "NewComptroller", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "oldInterestRateModel", - "type": "address" - }, - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "newInterestRateModel", - "type": "address" - } - ], - "name": "NewMarketInterestRateModel", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } - ], - "name": "NewProtocolSeizeShare", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } - ], - "name": "NewProtocolShareReserve", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } - ], - "name": "NewReduceReservesBlockDelta", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } - ], - "name": "NewReserveFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } - ], - "name": "NewShortfallContract", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ProtocolSeize", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Redeem", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "RepayBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "ReservesAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "SpreadReservesReduced", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Transfer", - "type": "event" - }, - { - "inputs": [], - "name": "NO_ERROR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrualBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrueInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], - "name": "addReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "owner", "type": "address" }, - { "internalType": "address", "name": "spender", "type": "address" } - ], - "name": "allowance", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "approve", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "badDebt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], - "name": "badDebtRecovered", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOfUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], - "name": "borrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "borrowIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "borrowRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } - ], - "name": "decreaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "forceLiquidateBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountSnapshot", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCash", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "healBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "addedValue", "type": "uint256" } - ], - "name": "increaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "underlying_", "type": "address" }, - { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, - { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, - { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, - { "internalType": "string", "name": "name_", "type": "string" }, - { "internalType": "string", "name": "symbol_", "type": "string" }, - { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, - { "internalType": "address", "name": "admin_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { - "components": [ - { "internalType": "address", "name": "shortfall", "type": "address" }, - { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } - ], - "internalType": "struct VTokenInterface.RiskManagementInit", - "name": "riskManagement", - "type": "tuple" - }, - { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "interestRateModel", - "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isVToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } - ], - "name": "liquidateBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], - "name": "mint", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "mintBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolSeizeShareMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolShareReserve", - "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], - "name": "redeem", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], - "name": "redeemUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } - ], - "name": "redeemUnderlyingBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], - "name": "reduceReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockDelta", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], - "name": "repayBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "repayBorrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reserveFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], - "name": "setInterestRateModel", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], - "name": "setProtocolSeizeShare", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], - "name": "setProtocolShareReserve", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], - "name": "setReduceReservesBlockDelta", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], - "name": "setReserveFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], - "name": "setShortfallContract", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "shortfall", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "supplyRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrows", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrowsCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "totalReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transfer", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transferFrom", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "underlying", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/VTokenBeacon.json b/multisig/simulations/opbnbtestnet/vip-021/abi/VTokenBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/VTokenBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/XVSStore.json b/multisig/simulations/opbnbtestnet/vip-021/abi/XVSStore.json deleted file mode 100644 index 2d9ea2bb2..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/XVSStore.json +++ /dev/null @@ -1,130 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "AdminTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } - ], - "name": "NewPendingAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnerTransferred", - "type": "event" - }, - { - "constant": false, - "inputs": [], - "name": "acceptAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "emergencyRewardWithdraw", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokens", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "token", "type": "address" }, - { "internalType": "address", "name": "_to", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "safeRewardTransfer", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], - "name": "setNewOwner", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], - "name": "setPendingAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "bool", "name": "status", "type": "bool" } - ], - "name": "setRewardToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/XVSVault.json b/multisig/simulations/opbnbtestnet/vip-021/abi/XVSVault.json deleted file mode 100644 index 51d8d540c..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/XVSVault.json +++ /dev/null @@ -1,787 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Claim", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } - ], - "name": "DelegateChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "DelegateVotesChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Deposit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ExecutedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "name": "PoolAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } - ], - "name": "PoolUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RequestedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } - ], - "name": "RewardAmountUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } - ], - "name": "StoreUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } - ], - "name": "VaultDebtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } - ], - "name": "WithdrawalLockingPeriodUpdated", - "type": "event" - }, - { - "constant": true, - "inputs": [], - "name": "DELEGATION_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "DOMAIN_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "MAX_LOCK_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "SECONDS_PER_YEAR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], - "name": "_become", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, - { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, - { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } - ], - "name": "add", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint32", "name": "", "type": "uint32" } - ], - "name": "checkpoints", - "outputs": [ - { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, - { "internalType": "uint96", "name": "votes", "type": "uint96" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_account", "type": "address" }, - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "claim", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], - "name": "delegate", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "delegatee", "type": "address" }, - { "internalType": "uint256", "name": "nonce", "type": "uint256" }, - { "internalType": "uint256", "name": "expiry", "type": "uint256" }, - { "internalType": "uint8", "name": "v", "type": "uint8" }, - { "internalType": "bytes32", "name": "r", "type": "bytes32" }, - { "internalType": "bytes32", "name": "s", "type": "bytes32" } - ], - "name": "delegateBySig", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "delegates", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "deposit", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "executeWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getCurrentVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getEligibleWithdrawalAmount", - "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } - ], - "name": "getPriorVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getRequestedAmount", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getUserInfo", - "outputs": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, - { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getWithdrawalRequests", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, - { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } - ], - "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", - "name": "", - "type": "tuple[]" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "name": "initializeTimeManager", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isStakedToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "nonces", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "numCheckpoints", - "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "pause", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingReward", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "pendingRewardTransfers", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingWithdrawalsBeforeUpgrade", - "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingXVSVaultImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "poolInfos", - "outputs": [ - { "internalType": "contract IBEP20", "name": "token", "type": "address" }, - { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, - { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], - "name": "poolLength", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primePoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeToken", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "requestWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "resume", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], - "name": "rewardTokenAmountsPerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAmountsPerBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } - ], - "name": "set", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], - "name": "setAccessControl", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, - { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } - ], - "name": "setPrimeToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } - ], - "name": "setRewardAmountPerBlockOrSecond", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } - ], - "name": "setWithdrawalLockingPeriod", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_xvs", "type": "address" }, - { "internalType": "address", "name": "_xvsStore", "type": "address" } - ], - "name": "setXvsStore", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAllocPoints", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "totalPendingWithdrawals", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "updatePool", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "vaultPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsStore", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/boundValidator.json b/multisig/simulations/opbnbtestnet/vip-021/abi/boundValidator.json deleted file mode 100644 index d16c8fb08..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/boundValidator.json +++ /dev/null @@ -1,498 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "previousAdmin", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAdmin", - "type": "address" - } - ], - "name": "AdminChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "beacon", - "type": "address" - } - ], - "name": "BeaconUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "implementation", - "type": "address" - } - ], - "name": "Upgraded", - "type": "event" - }, - { - "stateMutability": "payable", - "type": "fallback" - }, - { - "inputs": [], - "name": "admin", - "outputs": [ - { - "internalType": "address", - "name": "admin_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [ - { - "internalType": "address", - "name": "implementation_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - } - ], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - }, - { - "internalType": "bytes", - "name": "data", - "type": "bytes" - } - ], - "name": "upgradeToAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "upperBound", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "lowerBound", - "type": "uint256" - } - ], - "name": "ValidateConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig", - "name": "config", - "type": "tuple" - } - ], - "name": "setValidateConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "setValidateConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "validateConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "reportedPrice", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "anchorPrice", - "type": "uint256" - } - ], - "name": "validatePriceWithAnchorPrice", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_logic", - "type": "address" - }, - { - "internalType": "address", - "name": "admin_", - "type": "address" - }, - { - "internalType": "bytes", - "name": "_data", - "type": "bytes" - } - ], - "stateMutability": "payable", - "type": "constructor" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/chainlinkOracle.json b/multisig/simulations/opbnbtestnet/vip-021/abi/chainlinkOracle.json deleted file mode 100644 index cdd689acb..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/chainlinkOracle.json +++ /dev/null @@ -1,459 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "vBnbAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "previousPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "requestedPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newPriceMantissa", - "type": "uint256" - } - ], - "name": "PricePosted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManager", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "prices", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - } - ], - "name": "setDirectPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VBep20Interface", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "underlyingPriceMantissa", - "type": "uint256" - } - ], - "name": "setUnderlyingPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "tokenConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/resilientOracle.json b/multisig/simulations/opbnbtestnet/vip-021/abi/resilientOracle.json deleted file mode 100644 index 35f52caa0..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/resilientOracle.json +++ /dev/null @@ -1,640 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "nativeMarketAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - }, - { - "internalType": "contract BoundValidatorInterface", - "name": "_boundValidator", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "OracleEnabled", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - } - ], - "name": "OracleSet", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "mainOracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "pivotOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "fallbackOracle", - "type": "address" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "INVALID_PRICE", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_TOKEN_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "boundValidator", - "outputs": [ - { - "internalType": "contract BoundValidatorInterface", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - }, - { - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "enableOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "getOracle", - "outputs": [ - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "bool", - "name": "enabled", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getTokenConfig", - "outputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "nativeMarket", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "setOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "updateAssetPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "updatePrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/sFrxETHOracle.json b/multisig/simulations/opbnbtestnet/vip-021/abi/sFrxETHOracle.json deleted file mode 100644 index b461549ba..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/sFrxETHOracle.json +++ /dev/null @@ -1,148 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_sfrxEthFraxOracle", "type": "address" }, - { "internalType": "address", "name": "_sfrxETH", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "BadPriceData", "type": "error" }, - { "inputs": [], "name": "InvalidTokenAddress", "type": "error" }, - { "inputs": [], "name": "PriceDifferenceExceeded", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxAllowedPriceDifference", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxAllowedPriceDifference", "type": "uint256" } - ], - "name": "MaxAllowedPriceDifferenceUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [], - "name": "SFRXETH", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "SFRXETH_FRAX_ORACLE", - "outputs": [{ "internalType": "contract ISfrxEthFraxOracle", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], - "name": "getPrice", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxAllowedPriceDifference", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" }], - "name": "setMaxAllowedPriceDifference", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/treasury.json b/multisig/simulations/opbnbtestnet/vip-021/abi/treasury.json deleted file mode 100644 index 18aabb61a..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/treasury.json +++ /dev/null @@ -1,86 +0,0 @@ -[ - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryNative", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryToken", - "type": "event" - }, - { "stateMutability": "payable", "type": "fallback" }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryNative", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "stateMutability": "payable", "type": "receive" } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/xvs.json b/multisig/simulations/opbnbtestnet/vip-021/abi/xvs.json deleted file mode 100644 index 69092bb4a..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/xvs.json +++ /dev/null @@ -1,716 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user", - "type": "address" - } - ], - "name": "AccountBlacklisted", - "type": "error" - }, - { - "inputs": [], - "name": "AddressesMustDiffer", - "type": "error" - }, - { - "inputs": [], - "name": "MintLimitExceed", - "type": "error" - }, - { - "inputs": [], - "name": "MintedAmountExceed", - "type": "error" - }, - { - "inputs": [], - "name": "NewCapNotGreaterThanMintedTokens", - "type": "error" - }, - { - "inputs": [], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "user", - "type": "address" - }, - { - "indexed": false, - "internalType": "bool", - "name": "value", - "type": "bool" - } - ], - "name": "BlacklistUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "MintCapChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitDecreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "source", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "destination", - "type": "address" - } - ], - "name": "MintedTokensMigrated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Transfer", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "internalType": "address", - "name": "spender", - "type": "address" - } - ], - "name": "allowance", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "approve", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [ - { - "internalType": "uint8", - "name": "", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "subtractedValue", - "type": "uint256" - } - ], - "name": "decreaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "addedValue", - "type": "uint256" - } - ], - "name": "increaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - } - ], - "name": "isBlackListed", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "source_", - "type": "address" - }, - { - "internalType": "address", - "name": "destination_", - "type": "address" - } - ], - "name": "migrateMinterTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "mint", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToCap", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToMintedAmount", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newAccessControlAddress_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "minter_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "setMintCap", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transfer", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transferFrom", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - }, - { - "internalType": "bool", - "name": "value_", - "type": "bool" - } - ], - "name": "updateBlacklist", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/abi/xvsBridgeAdmin.json b/multisig/simulations/opbnbtestnet/vip-021/abi/xvsBridgeAdmin.json deleted file mode 100644 index 024450a40..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/abi/xvsBridgeAdmin.json +++ /dev/null @@ -1,329 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "XVSBridge_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "string", - "name": "signature", - "type": "string" - }, - { - "indexed": false, - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "name": "FunctionRegistryChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "stateMutability": "nonpayable", - "type": "fallback" - }, - { - "inputs": [], - "name": "XVSBridge", - "outputs": [ - { - "internalType": "contract IXVSProxyOFT", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes4", - "name": "", - "type": "bytes4" - } - ], - "name": "functionRegistry", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "isTrustedRemote", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner_", - "type": "address" - } - ], - "name": "transferBridgeOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "string[]", - "name": "signatures_", - "type": "string[]" - }, - { - "internalType": "bool[]", - "name": "active_", - "type": "bool[]" - } - ], - "name": "upsertSignature", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbtestnet/vip-021/index.ts b/multisig/simulations/opbnbtestnet/vip-021/index.ts deleted file mode 100644 index d52ebb2fe..000000000 --- a/multisig/simulations/opbnbtestnet/vip-021/index.ts +++ /dev/null @@ -1,181 +0,0 @@ -import { expect } from "chai"; -import { Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip } from "src/vip-framework"; - -import vip021, { - BOUND_VALIDATOR, - COMPTROLLERS, - COMPTROLLER_BEACON, - DEFAULT_PROXY_ADMIN, - PSR, - VTOKENS, - VTOKEN_BEACON, - XVS, - XVS_BRIDGE_ADMIN_PROXY, - XVS_STORE, -} from "../../../proposals/opbnbtestnet/vip-021"; -import COMPTROLLER_ABI from "./abi/Comptroller.json"; -import COMPTROLLER_BEACON_ABI from "./abi/ComptrollerBeacon.json"; -import DEFAULT_PROXY_ADMIN_ABI from "./abi/DefaultProxyAdmin.json"; -import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; -import PSR_ABI from "./abi/ProtocolShareReserve.json"; -import VTOKEN_ABI from "./abi/VToken.json"; -import VTOKEN_BEACON_ABI from "./abi/VTokenBeacon.json"; -import XVS_STORE_ABI from "./abi/XVSStore.json"; -import XVS_VAULT_ABI from "./abi/XVSVault.json"; -import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; -import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; -import TREASURY_ABI from "./abi/treasury.json"; -import XVS_ABI from "./abi/xvs.json"; -import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; - -const { opbnbtestnet } = NETWORK_ADDRESSES; - -const RESILIENT_ORACLE = opbnbtestnet.RESILIENT_ORACLE; -const NORMAL_TIMELOCK = opbnbtestnet.NORMAL_TIMELOCK; - -forking(28761242, async () => { - const provider = ethers.provider; - let proxyAdmin: Contract; - let psr: Contract; - let comptrollerBeacon: Contract; - let vTokenBeacon: Contract; - let poolRegistry: Contract; - let xvsVault: Contract; - let xvsStore: Contract; - let xvs: Contract; - let xvsBridgeAdmin: Contract; - let resilientOracle: Contract; - let boundValidator: Contract; - let treasury: Contract; - - describe("Pre-VIP behavior", async () => { - before(async () => { - proxyAdmin = new ethers.Contract(DEFAULT_PROXY_ADMIN, DEFAULT_PROXY_ADMIN_ABI, provider); - psr = new ethers.Contract(PSR, PSR_ABI, provider); - comptrollerBeacon = new ethers.Contract(COMPTROLLER_BEACON, COMPTROLLER_BEACON_ABI, provider); - vTokenBeacon = new ethers.Contract(VTOKEN_BEACON, VTOKEN_BEACON_ABI, provider); - poolRegistry = new ethers.Contract(opbnbtestnet.POOL_REGISTRY, POOL_REGISTRY_ABI, provider); - xvsVault = new ethers.Contract(opbnbtestnet.XVS_VAULT_PROXY, XVS_VAULT_ABI, provider); - xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); - xvs = await ethers.getContractAt(XVS_ABI, XVS); - xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, XVS_BRIDGE_ADMIN_PROXY); - resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); - boundValidator = new ethers.Contract(BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); - treasury = await ethers.getContractAt(TREASURY_ABI, NETWORK_ADDRESSES.opbnbtestnet.VTREASURY); - }); - - it("owner of proxy admin is guardian", async () => { - expect(await proxyAdmin.owner()).to.equal(opbnbtestnet.GUARDIAN); - }); - - it("pending owner of psr", async () => { - expect(await psr.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`should have no pending owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`should have no pending owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - it("owner of ComptrollerBeacon is guardian", async () => { - expect(await comptrollerBeacon.owner()).to.equal(opbnbtestnet.GUARDIAN); - }); - - it("owner of VTokenBeacon is guardian", async () => { - expect(await vTokenBeacon.owner()).to.equal(opbnbtestnet.GUARDIAN); - }); - - it("pending owner of PoolRegistry", async () => { - expect(await poolRegistry.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - it("should have no pending owner", async () => { - expect(await xvsVault.pendingAdmin()).to.equal(ethers.constants.AddressZero); - }); - - it("should have no pending owner", async () => { - expect(await xvsStore.pendingAdmin()).to.equal(ethers.constants.AddressZero); - }); - - it("should have no pending owner", async () => { - expect(await resilientOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await boundValidator.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - }); - - describe("Post-VIP behavior", async () => { - before(async () => { - await pretendExecutingVip(await vip021()); - }); - - it("owner of proxy admin is timelock", async () => { - expect(await proxyAdmin.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); - }); - - it("pending owner of psr", async () => { - expect(await psr.pendingOwner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`correct pending owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.pendingOwner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`correct pending owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.pendingOwner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); - }); - } - - it("owner of ComptrollerBeacon is NT", async () => { - expect(await comptrollerBeacon.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); - }); - - it("owner of VTokenBeacon is NT", async () => { - expect(await vTokenBeacon.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); - }); - - it("pending owner of PoolRegistry is NT", async () => { - expect(await poolRegistry.pendingOwner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); - }); - - it("correct pending owner", async () => { - expect(await xvsVault.pendingAdmin()).to.equal(NORMAL_TIMELOCK); - }); - - it("correct pending owner", async () => { - expect(await xvsStore.pendingAdmin()).to.equal(NORMAL_TIMELOCK); - }); - - it("Should set bridge pending owner to Normal Timelock", async () => { - const pendingOwner = await xvsBridgeAdmin.pendingOwner(); - expect(pendingOwner).equals(opbnbtestnet.NORMAL_TIMELOCK); - }); - it("Should set XVS owner to Normal Timelock", async () => { - const owner = await xvs.owner(); - expect(owner).equals(opbnbtestnet.NORMAL_TIMELOCK); - }); - it("correct pending owner", async () => { - expect(await resilientOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); - expect(await boundValidator.pendingOwner()).to.equal(NORMAL_TIMELOCK); - }); - it("Should set pendingOwner to Normal Timelock", async () => { - const pendingOwner = await treasury.pendingOwner(); - expect(pendingOwner).equals(NETWORK_ADDRESSES.opbnbtestnet.NORMAL_TIMELOCK); - }); - }); -}); diff --git a/multisig/simulations/sepolia/vip-060/abi/Comptroller.json b/multisig/simulations/sepolia/vip-060/abi/Comptroller.json deleted file mode 100644 index f3b2445ac..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/Comptroller.json +++ /dev/null @@ -1,929 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "ActionPaused", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "BorrowCapExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "CollateralExceedsThreshold", - "type": "error" - }, - { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, - { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, - { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } - ], - "name": "InsufficientCollateral", - "type": "error" - }, - { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, - { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, - { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, - { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketAlreadyListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "MarketNotCollateral", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketNotListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "MinimalCollateralViolated", - "type": "error" - }, - { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "PriceError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "SnapshotError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "SupplyCapExceeded", - "type": "error" - }, - { "inputs": [], "name": "TooMuchRepay", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "expectedSender", "type": "address" }, - { "internalType": "address", "name": "actualSender", "type": "address" } - ], - "name": "UnexpectedSender", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, - { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } - ], - "name": "ActionPausedMarket", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "DelegateUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "IsForcedLiquidationEnabledUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketEntered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketExited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "MarketSupported", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } - ], - "name": "NewBorrowCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } - ], - "name": "NewCloseFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } - ], - "name": "NewCollateralFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } - ], - "name": "NewLiquidationIncentive", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "NewLiquidationThreshold", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } - ], - "name": "NewMinLiquidatableCollateral", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "oldPriceOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "newPriceOracle", - "type": "address" - } - ], - "name": "NewPriceOracle", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } - ], - "name": "NewRewardsDistributor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } - ], - "name": "NewSupplyCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "accountAssets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "actionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], - "name": "addRewardsDistributor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "allMarkets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "approvedDelegates", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "borrowCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "contract VToken", "name": "vToken", "type": "address" } - ], - "name": "checkMembership", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "closeFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], - "name": "enterMarkets", - "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], - "name": "exitMarket", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAssetsIn", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getBorrowingPower", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "address", "name": "vTokenModify", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "getHypotheticalAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getRewardDistributors", - "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "getRewardsByMarket", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.RewardSpeeds[]", - "name": "rewardSpeeds", - "type": "tuple[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "healAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isComptroller", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isForcedLiquidationEnabled", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "isMarketListed", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [ - { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.LiquidationOrder[]", - "name": "orders", - "type": "tuple[]" - } - ], - "name": "liquidateAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "liquidateBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } - ], - "name": "liquidateCalculateSeizeTokens", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "liquidationIncentiveMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "bool", "name": "isListed", "type": "bool" }, - { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "minLiquidatableCollateral", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } - ], - "name": "mintVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "preBorrowHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "preLiquidateHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "preMintHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "preRedeemHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preRepayHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "seizerContract", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preSeizeHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "preTransferHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } - ], - "name": "repayBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seizeVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, - { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, - { "internalType": "bool", "name": "paused", "type": "bool" } - ], - "name": "setActionsPaused", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], - "name": "setCloseFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "setCollateralFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "setForcedLiquidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], - "name": "setLiquidationIncentive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } - ], - "name": "setMarketBorrowCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } - ], - "name": "setMarketSupplyCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], - "name": "setMinLiquidatableCollateral", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "supplyCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "supportMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "transferVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "delegate", "type": "address" }, - { "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "updateDelegate", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "updatePrices", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/ComptrollerBeacon.json b/multisig/simulations/sepolia/vip-060/abi/ComptrollerBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/ComptrollerBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/ConverterNetwork.json b/multisig/simulations/sepolia/vip-060/abi/ConverterNetwork.json deleted file mode 100644 index 396f12a91..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/ConverterNetwork.json +++ /dev/null @@ -1,205 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { "inputs": [], "name": "ConverterAlreadyExists", "type": "error" }, - { "inputs": [], "name": "ConverterDoesNotExist", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "InvalidMaxLoopsLimit", - "type": "error" - }, - { "inputs": [], "name": "InvalidTokenConverterAddress", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], - "name": "ConverterAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], - "name": "ConverterRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], - "name": "addTokenConverter", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "allConverters", - "outputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } - ], - "name": "findTokenConverters", - "outputs": [ - { "internalType": "address[]", "name": "converters", "type": "address[]" }, - { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } - ], - "name": "findTokenConvertersForConverters", - "outputs": [ - { "internalType": "address[]", "name": "converters", "type": "address[]" }, - { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getAllConverters", - "outputs": [{ "internalType": "contract IAbstractTokenConverter[]", "name": "converters", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_tokenConverter", "type": "address" }], - "name": "isTokenConverter", - "outputs": [{ "internalType": "bool", "name": "isConverter", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], - "name": "removeTokenConverter", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/DefaultProxyAdmin.json b/multisig/simulations/sepolia/vip-060/abi/DefaultProxyAdmin.json deleted file mode 100644 index 9801cfcc7..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/DefaultProxyAdmin.json +++ /dev/null @@ -1,76 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "changeProxyAdmin", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" } - ], - "name": "upgrade", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" }, - { "internalType": "bytes", "name": "data", "type": "bytes" } - ], - "name": "upgradeAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/PoolRegistry.json b/multisig/simulations/sepolia/vip-060/abi/PoolRegistry.json deleted file mode 100644 index 31b1e2a17..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/PoolRegistry.json +++ /dev/null @@ -1,379 +0,0 @@ -[ - { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, - { - "name": "Unauthorized", - "type": "error", - "inputs": [ - { "name": "sender", "type": "address", "internalType": "address" }, - { "name": "calledContract", "type": "address", "internalType": "address" }, - { "name": "methodSignature", "type": "string", "internalType": "string" } - ] - }, - { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, - { - "name": "Initialized", - "type": "event", - "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], - "anonymous": false, - "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" - }, - { - "name": "MarketAdded", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" - }, - { - "name": "NewAccessControlManager", - "type": "event", - "inputs": [ - { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, - { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" - }, - { - "name": "OwnershipTransferStarted", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" - }, - { - "name": "OwnershipTransferred", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" - }, - { - "name": "PoolMetadataUpdated", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "oldMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - }, - { - "name": "newMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "anonymous": false, - "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" - }, - { - "name": "PoolNameSet", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, - { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } - ], - "anonymous": false, - "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" - }, - { - "name": "PoolRegistered", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "pool", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "anonymous": false, - "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" - }, - { - "name": "acceptOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x79ba5097", - "stateMutability": "nonpayable" - }, - { - "name": "accessControlManager", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "contract IAccessControlManagerV8" - } - ], - "constant": true, - "signature": "0xb4a0bdf3", - "stateMutability": "view" - }, - { - "name": "addMarket", - "type": "function", - "inputs": [ - { - "name": "input", - "type": "tuple", - "components": [ - { "name": "vToken", "type": "address", "internalType": "contract VToken" }, - { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, - { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, - { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, - { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, - { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistry.AddMarketInput" - } - ], - "outputs": [], - "signature": "0x23dc8d64", - "stateMutability": "nonpayable" - }, - { - "name": "addPool", - "type": "function", - "inputs": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, - { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, - { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } - ], - "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], - "signature": "0xeed873c2", - "stateMutability": "nonpayable" - }, - { - "name": "getAllPools", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "tuple[]", - "value": [], - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool[]" - } - ], - "constant": true, - "signature": "0xd88ff1f4", - "stateMutability": "view" - }, - { - "name": "getPoolByComptroller", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "constant": true, - "signature": "0x7aee632d", - "stateMutability": "view" - }, - { - "name": "getPoolsSupportedByAsset", - "type": "function", - "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], - "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], - "constant": true, - "signature": "0xf36dba38", - "stateMutability": "view" - }, - { - "name": "getVTokenForAsset", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "asset", "type": "address", "internalType": "address" } - ], - "outputs": [{ "name": "", "type": "address", "internalType": "address" }], - "constant": true, - "signature": "0x266e0a7f", - "stateMutability": "view" - }, - { - "name": "getVenusPoolMetadata", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "constant": true, - "signature": "0xa3aefa2c", - "stateMutability": "view" - }, - { - "name": "initialize", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xc4d66de8", - "stateMutability": "nonpayable" - }, - { - "name": "metadata", - "type": "function", - "inputs": [{ "name": "", "type": "address", "internalType": "address" }], - "outputs": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "constant": true, - "signature": "0x2ba21572", - "stateMutability": "view" - }, - { - "name": "owner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x8da5cb5b", - "stateMutability": "view" - }, - { - "name": "pendingOwner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0xe30c3978", - "stateMutability": "view" - }, - { - "name": "renounceOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x715018a6", - "stateMutability": "nonpayable" - }, - { - "name": "setAccessControlManager", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0x0e32cb86", - "stateMutability": "nonpayable" - }, - { - "name": "setPoolName", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "name", "type": "string", "internalType": "string" } - ], - "outputs": [], - "signature": "0x1cb6bb7e", - "stateMutability": "nonpayable" - }, - { - "name": "transferOwnership", - "type": "function", - "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xf2fde38b", - "stateMutability": "nonpayable" - }, - { - "name": "updatePoolMetadata", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { - "name": "metadata_", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "outputs": [], - "signature": "0xff94d958", - "stateMutability": "nonpayable" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/Prime.json b/multisig/simulations/sepolia/vip-060/abi/Prime.json deleted file mode 100644 index e8bfa99ff..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/Prime.json +++ /dev/null @@ -1,763 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, - { "internalType": "address", "name": "_nativeMarket", "type": "address" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, - { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, - { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, - { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, - { "internalType": "bool", "name": "_timeBased", "type": "bool" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, - { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidComptroller", "type": "error" }, - { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "n", "type": "uint256" }, - { "internalType": "uint256", "name": "d", "type": "uint256" } - ], - "name": "InvalidFraction", - "type": "error" - }, - { "inputs": [], "name": "InvalidLength", "type": "error" }, - { "inputs": [], "name": "InvalidLimit", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, - { "inputs": [], "name": "InvalidVToken", "type": "error" }, - { - "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], - "name": "LnNonRealResult", - "type": "error" - }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, - { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, - { "inputs": [], "name": "MarketNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, - { "inputs": [], "name": "WaitMoreTime", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, - { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } - ], - "name": "AlphaUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "Burn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "InterestClaimed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "MarketAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } - ], - "name": "MintLimitsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } - ], - "name": "MultiplierUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } - ], - "name": "StakedAtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "TokenUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "UserScoreUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "MAXIMUM_XVS_CAP", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MINIMUM_STAKED_XVS", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_MARKET", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "STAKING_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WRAPPED_NATIVE_TOKEN", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "accrueInterest", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" } - ], - "name": "accrueInterestAndUpdateScore", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "addMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "alphaDenominator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "alphaNumerator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "calculateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "claimTimeRemaining", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "uint256", "name": "borrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supply", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } - ], - "name": "estimateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "getInterestAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "getPendingRewards", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "internalType": "struct PrimeStorageV1.PendingReward[]", - "name": "pendingRewards", - "type": "tuple[]" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "incomeDistributionYearly", - "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "xvsVault_", "type": "address" }, - { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, - { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, - { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, - { "internalType": "address", "name": "comptroller_", "type": "address" }, - { "internalType": "address", "name": "oracle_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "name": "initializeV2", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "interests", - "outputs": [ - { "internalType": "uint256", "name": "accrued", "type": "uint256" }, - { "internalType": "uint256", "name": "score", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "irrevocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "", "type": "uint256" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "isScoreUpdated", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "isUserPrimeHolder", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, - { "internalType": "address[]", "name": "users", "type": "address[]" } - ], - "name": "issue", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, - { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, - { "internalType": "bool", "name": "exists", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "nextScoreUpdateRoundId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingScoreUpdates", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "primeLiquidityProvider", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "revocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } - ], - "name": "setLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "users", "type": "address[]" }, - { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } - ], - "name": "setStakedAt", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "stakedAt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokens", - "outputs": [ - { "internalType": "bool", "name": "exists", "type": "bool" }, - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalIrrevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalRevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalScoreUpdatesRequired", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "unreleasedPLPIncome", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, - { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } - ], - "name": "updateAlpha", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "updateMultipliers", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], - "name": "updateScores", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "vTokenForAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "xvsUpdated", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVault", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultPoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/PrimeLiquidityProvider.json b/multisig/simulations/sepolia/vip-060/abi/PrimeLiquidityProvider.json deleted file mode 100644 index 02ca8e0bf..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/PrimeLiquidityProvider.json +++ /dev/null @@ -1,385 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "_timeBased", "type": "bool" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, - { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "balance", "type": "uint256" } - ], - "name": "InsufficientBalance", - "type": "error" - }, - { "inputs": [], "name": "InvalidArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidCaller", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "speed", "type": "uint256" }, - { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } - ], - "name": "InvalidDistributionSpeed", - "type": "error" - }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenAlreadyInitialized", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "TokenNotInitialized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "MaxTokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } - ], - "name": "PrimeTokenUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenDistributionInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "TokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokenTransferredToPrime", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokensAccrued", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "accrueTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "getEffectiveDistributionSpeed", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], - "name": "initializeTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "lastAccruedBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastAccruedBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "maxTokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } - ], - "name": "setMaxTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } - ], - "name": "setTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, - { "internalType": "address", "name": "to_", "type": "address" }, - { "internalType": "uint256", "name": "amount_", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "tokenAmountAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/ProtocolShareReserve.json b/multisig/simulations/sepolia/vip-060/abi/ProtocolShareReserve.json deleted file mode 100644 index b33d7c495..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/ProtocolShareReserve.json +++ /dev/null @@ -1,356 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, - { "internalType": "address", "name": "_wbnb", "type": "address" }, - { "internalType": "address", "name": "_vbnb", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetReleased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IProtocolShareReserve.IncomeType", - "name": "incomeType", - "type": "uint8" - }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "AssetsReservesUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } - ], - "name": "PoolRegistryUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "ReservesUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "CORE_POOL_COMPTROLLER", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MAX_PERCENT", - "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "internalType": "struct ProtocolShareReserve.DistributionConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "addOrUpdateDistributionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } - ], - "name": "assetsReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "distributionTargets", - "outputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "getPercentageDistribution", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "getUnreleasedFunds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address[]", "name": "assets", "type": "address[]" } - ], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "name": "removeDistributionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], - "name": "setPoolRegistry", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAssetReserve", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalDistributions", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/RewardDistrbutor.json b/multisig/simulations/sepolia/vip-060/abi/RewardDistrbutor.json deleted file mode 100644 index 249fdd111..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/RewardDistrbutor.json +++ /dev/null @@ -1,532 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "BorrowLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "BorrowLastRewardingBlockUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "ContributorRewardTokenSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } - ], - "name": "ContributorRewardsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } - ], - "name": "DistributedBorrowerRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } - ], - "name": "DistributedSupplierRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "MarketInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "indexed": false, - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "RewardTokenBorrowIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenBorrowSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RewardTokenGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "RewardTokenSupplyIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenSupplySpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "SupplyLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "SupplyLastRewardingBlockUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "INITIAL_INDEX", - "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "holder", "type": "address" }, - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } - ], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "distributeBorrowerRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "supplier", "type": "address" } - ], - "name": "distributeSupplierRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "recipient", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "grantRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, - { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "initializeMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastContributorBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "rewardToken", - "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenBorrowerIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenContributorSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenSupplierIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplySpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contributor", "type": "address" }, - { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } - ], - "name": "setContributorRewardTokenSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } - ], - "name": "setLastRewardingBlockTimestamps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, - { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } - ], - "name": "setLastRewardingBlocks", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } - ], - "name": "setRewardTokenSpeeds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], - "name": "updateContributorRewards", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "updateRewardTokenBorrowIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "updateRewardTokenSupplyIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/SingleTokenConverter.json b/multisig/simulations/sepolia/vip-060/abi/SingleTokenConverter.json deleted file mode 100644 index 8ea10cc8d..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/SingleTokenConverter.json +++ /dev/null @@ -1,587 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } - ], - "name": "AmountInHigherThanMax", - "type": "error" - }, - { "inputs": [], "name": "AmountInMismatched", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } - ], - "name": "AmountOutLowerThanMinRequired", - "type": "error" - }, - { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, - { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, - { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, - { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, - { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, - { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } - ], - "name": "IncentiveTooHigh", - "type": "error" - }, - { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, - { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, - { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, - { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, - { "inputs": [], "name": "InvalidToAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, - { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetTransferredToDestination", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } - ], - "name": "BaseAssetUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "oldAccess", - "type": "uint8" - }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "newAccess", - "type": "uint8" - } - ], - "name": "ConversionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } - ], - "name": "ConverterNetworkAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } - ], - "name": "DestinationAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } - ], - "name": "MinAmountToConvertUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, - { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } - ], - "name": "PriceOracleUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "inputs": [], - "name": "MAX_INCENTIVE", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "baseAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "conversionConfigurations", - "outputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "conversionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "converterNetwork", - "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "destinationAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, - { "internalType": "address", "name": "destinationAddress_", "type": "address" }, - { "internalType": "address", "name": "baseAsset_", "type": "address" }, - { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "minAmountToConvert", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "priceOracle", - "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], - "name": "setBaseAsset", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig", - "name": "conversionConfig", - "type": "tuple" - } - ], - "name": "setConversionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", - "name": "conversionConfigs", - "type": "tuple[]" - } - ], - "name": "setConversionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], - "name": "setConverterNetwork", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], - "name": "setDestination", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], - "name": "setMinAmountToConvert", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/SingleTokenConverterBeacon.json b/multisig/simulations/sepolia/vip-060/abi/SingleTokenConverterBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/SingleTokenConverterBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/VToken.json b/multisig/simulations/sepolia/vip-060/abi/VToken.json deleted file mode 100644 index d8cc1aae4..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/VToken.json +++ /dev/null @@ -1,861 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], - "name": "AddReservesFactorFreshCheck", - "type": "error" - }, - { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, - { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, - { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], - "name": "LiquidateAccrueCollateralInterestFailed", - "type": "error" - }, - { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, - { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, - { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, - { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, - { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, - { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, - { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "AccrueInterest", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtRecovered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "Borrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "HealBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "LiquidateBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } - ], - "name": "NewComptroller", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "oldInterestRateModel", - "type": "address" - }, - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "newInterestRateModel", - "type": "address" - } - ], - "name": "NewMarketInterestRateModel", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } - ], - "name": "NewProtocolSeizeShare", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } - ], - "name": "NewProtocolShareReserve", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } - ], - "name": "NewReduceReservesBlockDelta", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } - ], - "name": "NewReserveFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } - ], - "name": "NewShortfallContract", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ProtocolSeize", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Redeem", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "RepayBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "ReservesAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "SpreadReservesReduced", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Transfer", - "type": "event" - }, - { - "inputs": [], - "name": "NO_ERROR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrualBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrueInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], - "name": "addReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "owner", "type": "address" }, - { "internalType": "address", "name": "spender", "type": "address" } - ], - "name": "allowance", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "approve", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "badDebt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], - "name": "badDebtRecovered", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOfUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], - "name": "borrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "borrowIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "borrowRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } - ], - "name": "decreaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "forceLiquidateBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountSnapshot", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCash", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "healBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "addedValue", "type": "uint256" } - ], - "name": "increaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "underlying_", "type": "address" }, - { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, - { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, - { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, - { "internalType": "string", "name": "name_", "type": "string" }, - { "internalType": "string", "name": "symbol_", "type": "string" }, - { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, - { "internalType": "address", "name": "admin_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { - "components": [ - { "internalType": "address", "name": "shortfall", "type": "address" }, - { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } - ], - "internalType": "struct VTokenInterface.RiskManagementInit", - "name": "riskManagement", - "type": "tuple" - }, - { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "interestRateModel", - "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isVToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } - ], - "name": "liquidateBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], - "name": "mint", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "mintBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolSeizeShareMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolShareReserve", - "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], - "name": "redeem", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], - "name": "redeemUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } - ], - "name": "redeemUnderlyingBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], - "name": "reduceReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockDelta", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], - "name": "repayBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "repayBorrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reserveFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], - "name": "setInterestRateModel", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], - "name": "setProtocolSeizeShare", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], - "name": "setProtocolShareReserve", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], - "name": "setReduceReservesBlockDelta", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], - "name": "setReserveFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], - "name": "setShortfallContract", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "shortfall", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "supplyRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrows", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrowsCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "totalReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transfer", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transferFrom", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "underlying", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/VTokenBeacon.json b/multisig/simulations/sepolia/vip-060/abi/VTokenBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/VTokenBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/XVSStore.json b/multisig/simulations/sepolia/vip-060/abi/XVSStore.json deleted file mode 100644 index 2d9ea2bb2..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/XVSStore.json +++ /dev/null @@ -1,130 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "AdminTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } - ], - "name": "NewPendingAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnerTransferred", - "type": "event" - }, - { - "constant": false, - "inputs": [], - "name": "acceptAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "emergencyRewardWithdraw", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokens", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "token", "type": "address" }, - { "internalType": "address", "name": "_to", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "safeRewardTransfer", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], - "name": "setNewOwner", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], - "name": "setPendingAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "bool", "name": "status", "type": "bool" } - ], - "name": "setRewardToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/XVSVault.json b/multisig/simulations/sepolia/vip-060/abi/XVSVault.json deleted file mode 100644 index 51d8d540c..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/XVSVault.json +++ /dev/null @@ -1,787 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Claim", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } - ], - "name": "DelegateChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "DelegateVotesChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Deposit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ExecutedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "name": "PoolAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } - ], - "name": "PoolUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RequestedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } - ], - "name": "RewardAmountUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } - ], - "name": "StoreUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } - ], - "name": "VaultDebtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } - ], - "name": "WithdrawalLockingPeriodUpdated", - "type": "event" - }, - { - "constant": true, - "inputs": [], - "name": "DELEGATION_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "DOMAIN_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "MAX_LOCK_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "SECONDS_PER_YEAR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], - "name": "_become", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, - { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, - { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } - ], - "name": "add", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint32", "name": "", "type": "uint32" } - ], - "name": "checkpoints", - "outputs": [ - { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, - { "internalType": "uint96", "name": "votes", "type": "uint96" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_account", "type": "address" }, - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "claim", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], - "name": "delegate", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "delegatee", "type": "address" }, - { "internalType": "uint256", "name": "nonce", "type": "uint256" }, - { "internalType": "uint256", "name": "expiry", "type": "uint256" }, - { "internalType": "uint8", "name": "v", "type": "uint8" }, - { "internalType": "bytes32", "name": "r", "type": "bytes32" }, - { "internalType": "bytes32", "name": "s", "type": "bytes32" } - ], - "name": "delegateBySig", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "delegates", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "deposit", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "executeWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getCurrentVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getEligibleWithdrawalAmount", - "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } - ], - "name": "getPriorVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getRequestedAmount", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getUserInfo", - "outputs": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, - { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getWithdrawalRequests", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, - { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } - ], - "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", - "name": "", - "type": "tuple[]" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "name": "initializeTimeManager", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isStakedToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "nonces", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "numCheckpoints", - "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "pause", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingReward", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "pendingRewardTransfers", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingWithdrawalsBeforeUpgrade", - "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingXVSVaultImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "poolInfos", - "outputs": [ - { "internalType": "contract IBEP20", "name": "token", "type": "address" }, - { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, - { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], - "name": "poolLength", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primePoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeToken", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "requestWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "resume", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], - "name": "rewardTokenAmountsPerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAmountsPerBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } - ], - "name": "set", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], - "name": "setAccessControl", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, - { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } - ], - "name": "setPrimeToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } - ], - "name": "setRewardAmountPerBlockOrSecond", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } - ], - "name": "setWithdrawalLockingPeriod", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_xvs", "type": "address" }, - { "internalType": "address", "name": "_xvsStore", "type": "address" } - ], - "name": "setXvsStore", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAllocPoints", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "totalPendingWithdrawals", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "updatePool", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "vaultPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsStore", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/boundValidator.json b/multisig/simulations/sepolia/vip-060/abi/boundValidator.json deleted file mode 100644 index d16c8fb08..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/boundValidator.json +++ /dev/null @@ -1,498 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "previousAdmin", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAdmin", - "type": "address" - } - ], - "name": "AdminChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "beacon", - "type": "address" - } - ], - "name": "BeaconUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "implementation", - "type": "address" - } - ], - "name": "Upgraded", - "type": "event" - }, - { - "stateMutability": "payable", - "type": "fallback" - }, - { - "inputs": [], - "name": "admin", - "outputs": [ - { - "internalType": "address", - "name": "admin_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [ - { - "internalType": "address", - "name": "implementation_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - } - ], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - }, - { - "internalType": "bytes", - "name": "data", - "type": "bytes" - } - ], - "name": "upgradeToAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "upperBound", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "lowerBound", - "type": "uint256" - } - ], - "name": "ValidateConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig", - "name": "config", - "type": "tuple" - } - ], - "name": "setValidateConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "setValidateConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "validateConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "reportedPrice", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "anchorPrice", - "type": "uint256" - } - ], - "name": "validatePriceWithAnchorPrice", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_logic", - "type": "address" - }, - { - "internalType": "address", - "name": "admin_", - "type": "address" - }, - { - "internalType": "bytes", - "name": "_data", - "type": "bytes" - } - ], - "stateMutability": "payable", - "type": "constructor" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/chainlinkOracle.json b/multisig/simulations/sepolia/vip-060/abi/chainlinkOracle.json deleted file mode 100644 index cdd689acb..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/chainlinkOracle.json +++ /dev/null @@ -1,459 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "vBnbAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "previousPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "requestedPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newPriceMantissa", - "type": "uint256" - } - ], - "name": "PricePosted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManager", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "prices", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - } - ], - "name": "setDirectPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VBep20Interface", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "underlyingPriceMantissa", - "type": "uint256" - } - ], - "name": "setUnderlyingPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "tokenConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/resilientOracle.json b/multisig/simulations/sepolia/vip-060/abi/resilientOracle.json deleted file mode 100644 index 35f52caa0..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/resilientOracle.json +++ /dev/null @@ -1,640 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "nativeMarketAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - }, - { - "internalType": "contract BoundValidatorInterface", - "name": "_boundValidator", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "OracleEnabled", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - } - ], - "name": "OracleSet", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "mainOracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "pivotOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "fallbackOracle", - "type": "address" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "INVALID_PRICE", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_TOKEN_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "boundValidator", - "outputs": [ - { - "internalType": "contract BoundValidatorInterface", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - }, - { - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "enableOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "getOracle", - "outputs": [ - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "bool", - "name": "enabled", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getTokenConfig", - "outputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "nativeMarket", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "setOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "updateAssetPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "updatePrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/sFrxETHOracle.json b/multisig/simulations/sepolia/vip-060/abi/sFrxETHOracle.json deleted file mode 100644 index b461549ba..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/sFrxETHOracle.json +++ /dev/null @@ -1,148 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_sfrxEthFraxOracle", "type": "address" }, - { "internalType": "address", "name": "_sfrxETH", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "BadPriceData", "type": "error" }, - { "inputs": [], "name": "InvalidTokenAddress", "type": "error" }, - { "inputs": [], "name": "PriceDifferenceExceeded", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxAllowedPriceDifference", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxAllowedPriceDifference", "type": "uint256" } - ], - "name": "MaxAllowedPriceDifferenceUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [], - "name": "SFRXETH", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "SFRXETH_FRAX_ORACLE", - "outputs": [{ "internalType": "contract ISfrxEthFraxOracle", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], - "name": "getPrice", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxAllowedPriceDifference", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" }], - "name": "setMaxAllowedPriceDifference", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/treasury.json b/multisig/simulations/sepolia/vip-060/abi/treasury.json deleted file mode 100644 index 18aabb61a..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/treasury.json +++ /dev/null @@ -1,86 +0,0 @@ -[ - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryNative", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryToken", - "type": "event" - }, - { "stateMutability": "payable", "type": "fallback" }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryNative", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "stateMutability": "payable", "type": "receive" } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/xvs.json b/multisig/simulations/sepolia/vip-060/abi/xvs.json deleted file mode 100644 index 69092bb4a..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/xvs.json +++ /dev/null @@ -1,716 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user", - "type": "address" - } - ], - "name": "AccountBlacklisted", - "type": "error" - }, - { - "inputs": [], - "name": "AddressesMustDiffer", - "type": "error" - }, - { - "inputs": [], - "name": "MintLimitExceed", - "type": "error" - }, - { - "inputs": [], - "name": "MintedAmountExceed", - "type": "error" - }, - { - "inputs": [], - "name": "NewCapNotGreaterThanMintedTokens", - "type": "error" - }, - { - "inputs": [], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "user", - "type": "address" - }, - { - "indexed": false, - "internalType": "bool", - "name": "value", - "type": "bool" - } - ], - "name": "BlacklistUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "MintCapChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitDecreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "source", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "destination", - "type": "address" - } - ], - "name": "MintedTokensMigrated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Transfer", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "internalType": "address", - "name": "spender", - "type": "address" - } - ], - "name": "allowance", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "approve", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [ - { - "internalType": "uint8", - "name": "", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "subtractedValue", - "type": "uint256" - } - ], - "name": "decreaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "addedValue", - "type": "uint256" - } - ], - "name": "increaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - } - ], - "name": "isBlackListed", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "source_", - "type": "address" - }, - { - "internalType": "address", - "name": "destination_", - "type": "address" - } - ], - "name": "migrateMinterTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "mint", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToCap", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToMintedAmount", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newAccessControlAddress_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "minter_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "setMintCap", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transfer", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transferFrom", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - }, - { - "internalType": "bool", - "name": "value_", - "type": "bool" - } - ], - "name": "updateBlacklist", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/abi/xvsBridgeAdmin.json b/multisig/simulations/sepolia/vip-060/abi/xvsBridgeAdmin.json deleted file mode 100644 index 024450a40..000000000 --- a/multisig/simulations/sepolia/vip-060/abi/xvsBridgeAdmin.json +++ /dev/null @@ -1,329 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "XVSBridge_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "string", - "name": "signature", - "type": "string" - }, - { - "indexed": false, - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "name": "FunctionRegistryChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "stateMutability": "nonpayable", - "type": "fallback" - }, - { - "inputs": [], - "name": "XVSBridge", - "outputs": [ - { - "internalType": "contract IXVSProxyOFT", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes4", - "name": "", - "type": "bytes4" - } - ], - "name": "functionRegistry", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "isTrustedRemote", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner_", - "type": "address" - } - ], - "name": "transferBridgeOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "string[]", - "name": "signatures_", - "type": "string[]" - }, - { - "internalType": "bool[]", - "name": "active_", - "type": "bool[]" - } - ], - "name": "upsertSignature", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/sepolia/vip-060/index.ts b/multisig/simulations/sepolia/vip-060/index.ts deleted file mode 100644 index 50cc312d6..000000000 --- a/multisig/simulations/sepolia/vip-060/index.ts +++ /dev/null @@ -1,270 +0,0 @@ -import { expect } from "chai"; -import { Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip } from "src/vip-framework"; - -import vip060, { - BOUND_VALIDATOR, - COMPTROLLERS, - COMPTROLLER_BEACON, - CONVERTERS, - CONVERTER_NETWORK, - DEFAULT_PROXY_ADMIN, - PLP, - PRIME, - PSR, - REWARD_DISTRIBUTORS, - SFrxETHOracle, - SINGLE_TOKEN_CONVERTER_BEACON, - VTOKENS, - VTOKEN_BEACON, - XVS, - XVS_BRIDGE_ADMIN_PROXY, - XVS_STORE, -} from "../../../proposals/sepolia/vip-060"; -import COMPTROLLER_ABI from "./abi/Comptroller.json"; -import COMPTROLLER_BEACON_ABI from "./abi/ComptrollerBeacon.json"; -import CONVERTER_NETWORK_ABI from "./abi/ConverterNetwork.json"; -import DEFAULT_PROXY_ADMIN_ABI from "./abi/DefaultProxyAdmin.json"; -import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; -import PRIME_ABI from "./abi/Prime.json"; -import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; -import PSR_ABI from "./abi/ProtocolShareReserve.json"; -import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistrbutor.json"; -import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; -import SINGLE_TOKEN_CONVERTER_BEACON_ABI from "./abi/SingleTokenConverterBeacon.json"; -import VTOKEN_ABI from "./abi/VToken.json"; -import VTOKEN_BEACON_ABI from "./abi/VTokenBeacon.json"; -import XVS_STORE_ABI from "./abi/XVSStore.json"; -import XVS_VAULT_ABI from "./abi/XVSVault.json"; -import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; -import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; -import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; -import SFRAXETH_ORACLE_ABI from "./abi/sFrxETHOracle.json"; -import XVS_ABI from "./abi/xvs.json"; -import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; - -const { sepolia } = NETWORK_ADDRESSES; - -const RESILIENT_ORACLE = sepolia.RESILIENT_ORACLE; -const CHAINLINK_ORACLE = sepolia.CHAINLINK_ORACLE; -const REDSTONE_ORACLE = sepolia.REDSTONE_ORACLE; -const NORMAL_TIMELOCK = sepolia.NORMAL_TIMELOCK; - -forking(6466682, async () => { - const provider = ethers.provider; - let proxyAdmin: Contract; - let prime: Contract; - let plp: Contract; - let psr: Contract; - let comptrollerBeacon: Contract; - let vTokenBeacon: Contract; - let poolRegistry: Contract; - let xvsVault: Contract; - let xvsStore: Contract; - let xvs: Contract; - let xvsBridgeAdmin: Contract; - let resilientOracle: Contract; - let chainLinkOracle: Contract; - let redstoneOracle: Contract; - let boundValidator: Contract; - let sfrxETHOracle: Contract; - - describe("Pre-VIP behavior", async () => { - before(async () => { - proxyAdmin = new ethers.Contract(DEFAULT_PROXY_ADMIN, DEFAULT_PROXY_ADMIN_ABI, provider); - prime = new ethers.Contract(PRIME, PRIME_ABI, provider); - plp = new ethers.Contract(PLP, PLP_ABI, provider); - psr = new ethers.Contract(PSR, PSR_ABI, provider); - comptrollerBeacon = new ethers.Contract(COMPTROLLER_BEACON, COMPTROLLER_BEACON_ABI, provider); - vTokenBeacon = new ethers.Contract(VTOKEN_BEACON, VTOKEN_BEACON_ABI, provider); - poolRegistry = new ethers.Contract(sepolia.POOL_REGISTRY, POOL_REGISTRY_ABI, provider); - xvsVault = new ethers.Contract(sepolia.XVS_VAULT_PROXY, XVS_VAULT_ABI, provider); - xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); - xvs = await ethers.getContractAt(XVS_ABI, XVS); - xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, XVS_BRIDGE_ADMIN_PROXY); - resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); - chainLinkOracle = new ethers.Contract(CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); - redstoneOracle = new ethers.Contract(REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); - boundValidator = new ethers.Contract(BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); - sfrxETHOracle = new ethers.Contract(SFrxETHOracle, SFRAXETH_ORACLE_ABI, provider); - }); - - it("owner of proxy admin is guardian", async () => { - expect(await proxyAdmin.owner()).to.equal(sepolia.GUARDIAN); - }); - it("pending owner", async () => { - expect(await prime.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await plp.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - - for (const rewardDistributor of REWARD_DISTRIBUTORS) { - it(`should have no pending owner for ${rewardDistributor}`, async () => { - const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - it("pending owner of psr", async () => { - expect(await psr.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`should have no pending owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`should have no pending owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - it("owner of ComptrollerBeacon is guardian", async () => { - expect(await comptrollerBeacon.owner()).to.equal(sepolia.GUARDIAN); - }); - - it("owner of VTokenBeacon is guardian", async () => { - expect(await vTokenBeacon.owner()).to.equal(sepolia.GUARDIAN); - }); - - it("pending owner of PoolRegistry", async () => { - expect(await poolRegistry.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - it("should have no pending owner", async () => { - expect(await xvsVault.pendingAdmin()).to.equal(ethers.constants.AddressZero); - }); - - it("should have no pending owner", async () => { - expect(await xvsStore.pendingAdmin()).to.equal(ethers.constants.AddressZero); - }); - - it("should have no pending owner", async () => { - expect(await resilientOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await chainLinkOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await redstoneOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); - expect(await boundValidator.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - - for (const converter of CONVERTERS) { - it(`should have no pending owner for ${converter}`, async () => { - const c = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - } - - it(`should have no pending owner for converter network`, async () => { - const c = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); - expect(await c.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - - it(`should have guardian as owner for converer beacon`, async () => { - const c = new ethers.Contract(SINGLE_TOKEN_CONVERTER_BEACON, SINGLE_TOKEN_CONVERTER_BEACON_ABI, provider); - expect(await c.owner()).to.equal(sepolia.GUARDIAN); - }); - - it("should have no pending owner", async () => { - expect(await sfrxETHOracle.pendingOwner()).to.equal(ethers.constants.AddressZero); - }); - }); - - describe("Post-VIP behavior", async () => { - before(async () => { - await pretendExecutingVip(await vip060()); - }); - - it("owner of proxy admin is timelock", async () => { - expect(await proxyAdmin.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - - it("pending owner", async () => { - expect(await prime.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); - expect(await plp.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - - for (const rewardDistributor of REWARD_DISTRIBUTORS) { - it(`should have Normal Timelock as pending owner for ${rewardDistributor}`, async () => { - const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); - expect(await c.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - } - - it("pending owner of psr", async () => { - expect(await psr.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`correct pending owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`correct pending owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - } - - it("owner of ComptrollerBeacon is NT", async () => { - expect(await comptrollerBeacon.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - - it("owner of VTokenBeacon is NT", async () => { - expect(await vTokenBeacon.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - - it("pending owner of PoolRegistry is NT", async () => { - expect(await poolRegistry.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - - it("correct pending owner", async () => { - expect(await xvsVault.pendingAdmin()).to.equal(NORMAL_TIMELOCK); - }); - - it("correct pending owner", async () => { - expect(await xvsStore.pendingAdmin()).to.equal(NORMAL_TIMELOCK); - }); - - it("Should set bridge pending owner to Normal Timelock", async () => { - const pendingOwner = await xvsBridgeAdmin.pendingOwner(); - expect(pendingOwner).equals(sepolia.NORMAL_TIMELOCK); - }); - it("Should set XVS owner to Normal Timelock", async () => { - const owner = await xvs.owner(); - expect(owner).equals(sepolia.NORMAL_TIMELOCK); - }); - it("correct pending owner", async () => { - expect(await resilientOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); - expect(await chainLinkOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); - expect(await redstoneOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); - expect(await boundValidator.pendingOwner()).to.equal(NORMAL_TIMELOCK); - }); - - for (const converter of CONVERTERS) { - it(`should have no pending owner for ${converter}`, async () => { - const c = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); - expect(await c.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - } - - it(`should have no pending owner for converter network`, async () => { - const c = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); - expect(await c.pendingOwner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - - it(`should have NT as owner for converer beacon`, async () => { - const c = new ethers.Contract(SINGLE_TOKEN_CONVERTER_BEACON, SINGLE_TOKEN_CONVERTER_BEACON_ABI, provider); - expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - - it("correct pending owner", async () => { - expect(await sfrxETHOracle.pendingOwner()).to.equal(NORMAL_TIMELOCK); - }); - }); -}); diff --git a/simulations/vip-372/abi/ACMCommandsAggregator.json b/simulations/vip-372/abi/ACMCommandsAggregator.json deleted file mode 100644 index 6650a3f3c..000000000 --- a/simulations/vip-372/abi/ACMCommandsAggregator.json +++ /dev/null @@ -1,242 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "_acm", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [], - "name": "EmptyPermissions", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "GrantPermissionsAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "GrantPermissionsExecuted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "RevokePermissionsAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "RevokePermissionsExecuted", - "type": "event" - }, - { - "inputs": [], - "name": "ACM", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "contractAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "functionSig", - "type": "string" - }, - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "internalType": "struct ACMCommandsAggregator.Permission[]", - "name": "_permissions", - "type": "tuple[]" - } - ], - "name": "addGrantPermissions", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "contractAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "functionSig", - "type": "string" - }, - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "internalType": "struct ACMCommandsAggregator.Permission[]", - "name": "_permissions", - "type": "tuple[]" - } - ], - "name": "addRevokePermissions", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "executeGrantPermissions", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "executeRevokePermissions", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "name": "grantPermissions", - "outputs": [ - { - "internalType": "address", - "name": "contractAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "functionSig", - "type": "string" - }, - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "name": "revokePermissions", - "outputs": [ - { - "internalType": "address", - "name": "contractAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "functionSig", - "type": "string" - }, - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/AccessControlManager.json b/simulations/vip-372/abi/AccessControlManager.json deleted file mode 100644 index 2ef119947..000000000 --- a/simulations/vip-372/abi/AccessControlManager.json +++ /dev/null @@ -1,157 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, - { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "PermissionGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, - { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "PermissionRevoked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, - { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } - ], - "name": "RoleAdminChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } - ], - "name": "RoleGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } - ], - "name": "RoleRevoked", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_ADMIN_ROLE", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], - "name": "getRoleAdmin", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" }, - { "internalType": "address", "name": "accountToPermit", "type": "address" } - ], - "name": "giveCallPermission", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "grantRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "hasPermission", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "hasRole", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "isAllowedToCall", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "renounceRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" }, - { "internalType": "address", "name": "accountToRevoke", "type": "address" } - ], - "name": "revokeCallPermission", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "revokeRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], - "name": "supportsInterface", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/Comptroller.json b/simulations/vip-372/abi/Comptroller.json deleted file mode 100644 index f3b2445ac..000000000 --- a/simulations/vip-372/abi/Comptroller.json +++ /dev/null @@ -1,929 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "ActionPaused", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "BorrowCapExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "CollateralExceedsThreshold", - "type": "error" - }, - { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, - { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, - { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } - ], - "name": "InsufficientCollateral", - "type": "error" - }, - { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, - { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, - { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, - { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketAlreadyListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "MarketNotCollateral", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketNotListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "MinimalCollateralViolated", - "type": "error" - }, - { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "PriceError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "SnapshotError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "SupplyCapExceeded", - "type": "error" - }, - { "inputs": [], "name": "TooMuchRepay", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "expectedSender", "type": "address" }, - { "internalType": "address", "name": "actualSender", "type": "address" } - ], - "name": "UnexpectedSender", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, - { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } - ], - "name": "ActionPausedMarket", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "DelegateUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "IsForcedLiquidationEnabledUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketEntered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketExited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "MarketSupported", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } - ], - "name": "NewBorrowCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } - ], - "name": "NewCloseFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } - ], - "name": "NewCollateralFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } - ], - "name": "NewLiquidationIncentive", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "NewLiquidationThreshold", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } - ], - "name": "NewMinLiquidatableCollateral", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "oldPriceOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "newPriceOracle", - "type": "address" - } - ], - "name": "NewPriceOracle", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } - ], - "name": "NewRewardsDistributor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } - ], - "name": "NewSupplyCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "accountAssets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "actionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], - "name": "addRewardsDistributor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "allMarkets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "approvedDelegates", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "borrowCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "contract VToken", "name": "vToken", "type": "address" } - ], - "name": "checkMembership", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "closeFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], - "name": "enterMarkets", - "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], - "name": "exitMarket", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAssetsIn", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getBorrowingPower", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "address", "name": "vTokenModify", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "getHypotheticalAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getRewardDistributors", - "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "getRewardsByMarket", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.RewardSpeeds[]", - "name": "rewardSpeeds", - "type": "tuple[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "healAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isComptroller", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isForcedLiquidationEnabled", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "isMarketListed", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [ - { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.LiquidationOrder[]", - "name": "orders", - "type": "tuple[]" - } - ], - "name": "liquidateAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "liquidateBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } - ], - "name": "liquidateCalculateSeizeTokens", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "liquidationIncentiveMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "bool", "name": "isListed", "type": "bool" }, - { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "minLiquidatableCollateral", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } - ], - "name": "mintVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "preBorrowHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "preLiquidateHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "preMintHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "preRedeemHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preRepayHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "seizerContract", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preSeizeHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "preTransferHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } - ], - "name": "repayBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seizeVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, - { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, - { "internalType": "bool", "name": "paused", "type": "bool" } - ], - "name": "setActionsPaused", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], - "name": "setCloseFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "setCollateralFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "setForcedLiquidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], - "name": "setLiquidationIncentive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } - ], - "name": "setMarketBorrowCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } - ], - "name": "setMarketSupplyCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], - "name": "setMinLiquidatableCollateral", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "supplyCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "supportMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "transferVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "delegate", "type": "address" }, - { "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "updateDelegate", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "updatePrices", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/ComptrollerBeacon.json b/simulations/vip-372/abi/ComptrollerBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/simulations/vip-372/abi/ComptrollerBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/ConverterNetwork.json b/simulations/vip-372/abi/ConverterNetwork.json deleted file mode 100644 index 396f12a91..000000000 --- a/simulations/vip-372/abi/ConverterNetwork.json +++ /dev/null @@ -1,205 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { "inputs": [], "name": "ConverterAlreadyExists", "type": "error" }, - { "inputs": [], "name": "ConverterDoesNotExist", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "InvalidMaxLoopsLimit", - "type": "error" - }, - { "inputs": [], "name": "InvalidTokenConverterAddress", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], - "name": "ConverterAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], - "name": "ConverterRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], - "name": "addTokenConverter", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "allConverters", - "outputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } - ], - "name": "findTokenConverters", - "outputs": [ - { "internalType": "address[]", "name": "converters", "type": "address[]" }, - { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } - ], - "name": "findTokenConvertersForConverters", - "outputs": [ - { "internalType": "address[]", "name": "converters", "type": "address[]" }, - { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getAllConverters", - "outputs": [{ "internalType": "contract IAbstractTokenConverter[]", "name": "converters", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_tokenConverter", "type": "address" }], - "name": "isTokenConverter", - "outputs": [{ "internalType": "bool", "name": "isConverter", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], - "name": "removeTokenConverter", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/DefaultProxyAdmin.json b/simulations/vip-372/abi/DefaultProxyAdmin.json deleted file mode 100644 index 9801cfcc7..000000000 --- a/simulations/vip-372/abi/DefaultProxyAdmin.json +++ /dev/null @@ -1,76 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "changeProxyAdmin", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" } - ], - "name": "upgrade", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" }, - { "internalType": "bytes", "name": "data", "type": "bytes" } - ], - "name": "upgradeAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/OmnichainProposalSender.json b/simulations/vip-372/abi/OmnichainProposalSender.json deleted file mode 100644 index 66fd4df02..000000000 --- a/simulations/vip-372/abi/OmnichainProposalSender.json +++ /dev/null @@ -1,314 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } - ], - "name": "ClearPayload", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } - ], - "name": "ExecuteRemoteProposal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } - ], - "name": "FallbackWithdraw", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } - ], - "name": "SetMaxDailyLimit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, - { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } - ], - "name": "SetTrustedRemoteAddress", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, - { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, - { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, - { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } - ], - "name": "StorePayload", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], - "name": "TrustedRemoteRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "LZ_ENDPOINT", - "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourCommandsSent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourWindowStart", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLastProposalSentTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToMaxDailyLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bool", "name": "useZro_", "type": "bool" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } - ], - "name": "estimateFees", - "outputs": [ - { "internalType": "uint256", "name": "", "type": "uint256" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, - { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } - ], - "name": "execute", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "to_", "type": "address" }, - { "internalType": "uint256", "name": "pId_", "type": "uint256" }, - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, - { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } - ], - "name": "fallbackWithdraw", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "version_", "type": "uint16" }, - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "configType_", "type": "uint256" } - ], - "name": "getConfig", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "proposalCount", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], - "name": "removeTrustedRemote", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "uint256", "name": "pId_", "type": "uint256" }, - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, - { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, - { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } - ], - "name": "retryExecute", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "version_", "type": "uint16" }, - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "configType_", "type": "uint256" }, - { "internalType": "bytes", "name": "config_", "type": "bytes" } - ], - "name": "setConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "limit_", "type": "uint256" } - ], - "name": "setMaxDailyLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], - "name": "setSendVersion", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "storedExecutionHashes", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "trustedRemoteLookup", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } -] diff --git a/simulations/vip-372/abi/PoolRegistry.json b/simulations/vip-372/abi/PoolRegistry.json deleted file mode 100644 index 31b1e2a17..000000000 --- a/simulations/vip-372/abi/PoolRegistry.json +++ /dev/null @@ -1,379 +0,0 @@ -[ - { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, - { - "name": "Unauthorized", - "type": "error", - "inputs": [ - { "name": "sender", "type": "address", "internalType": "address" }, - { "name": "calledContract", "type": "address", "internalType": "address" }, - { "name": "methodSignature", "type": "string", "internalType": "string" } - ] - }, - { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, - { - "name": "Initialized", - "type": "event", - "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], - "anonymous": false, - "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" - }, - { - "name": "MarketAdded", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" - }, - { - "name": "NewAccessControlManager", - "type": "event", - "inputs": [ - { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, - { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" - }, - { - "name": "OwnershipTransferStarted", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" - }, - { - "name": "OwnershipTransferred", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" - }, - { - "name": "PoolMetadataUpdated", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "oldMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - }, - { - "name": "newMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "anonymous": false, - "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" - }, - { - "name": "PoolNameSet", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, - { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } - ], - "anonymous": false, - "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" - }, - { - "name": "PoolRegistered", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "pool", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "anonymous": false, - "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" - }, - { - "name": "acceptOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x79ba5097", - "stateMutability": "nonpayable" - }, - { - "name": "accessControlManager", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "contract IAccessControlManagerV8" - } - ], - "constant": true, - "signature": "0xb4a0bdf3", - "stateMutability": "view" - }, - { - "name": "addMarket", - "type": "function", - "inputs": [ - { - "name": "input", - "type": "tuple", - "components": [ - { "name": "vToken", "type": "address", "internalType": "contract VToken" }, - { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, - { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, - { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, - { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, - { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistry.AddMarketInput" - } - ], - "outputs": [], - "signature": "0x23dc8d64", - "stateMutability": "nonpayable" - }, - { - "name": "addPool", - "type": "function", - "inputs": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, - { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, - { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } - ], - "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], - "signature": "0xeed873c2", - "stateMutability": "nonpayable" - }, - { - "name": "getAllPools", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "tuple[]", - "value": [], - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool[]" - } - ], - "constant": true, - "signature": "0xd88ff1f4", - "stateMutability": "view" - }, - { - "name": "getPoolByComptroller", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "constant": true, - "signature": "0x7aee632d", - "stateMutability": "view" - }, - { - "name": "getPoolsSupportedByAsset", - "type": "function", - "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], - "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], - "constant": true, - "signature": "0xf36dba38", - "stateMutability": "view" - }, - { - "name": "getVTokenForAsset", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "asset", "type": "address", "internalType": "address" } - ], - "outputs": [{ "name": "", "type": "address", "internalType": "address" }], - "constant": true, - "signature": "0x266e0a7f", - "stateMutability": "view" - }, - { - "name": "getVenusPoolMetadata", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "constant": true, - "signature": "0xa3aefa2c", - "stateMutability": "view" - }, - { - "name": "initialize", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xc4d66de8", - "stateMutability": "nonpayable" - }, - { - "name": "metadata", - "type": "function", - "inputs": [{ "name": "", "type": "address", "internalType": "address" }], - "outputs": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "constant": true, - "signature": "0x2ba21572", - "stateMutability": "view" - }, - { - "name": "owner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x8da5cb5b", - "stateMutability": "view" - }, - { - "name": "pendingOwner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0xe30c3978", - "stateMutability": "view" - }, - { - "name": "renounceOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x715018a6", - "stateMutability": "nonpayable" - }, - { - "name": "setAccessControlManager", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0x0e32cb86", - "stateMutability": "nonpayable" - }, - { - "name": "setPoolName", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "name", "type": "string", "internalType": "string" } - ], - "outputs": [], - "signature": "0x1cb6bb7e", - "stateMutability": "nonpayable" - }, - { - "name": "transferOwnership", - "type": "function", - "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xf2fde38b", - "stateMutability": "nonpayable" - }, - { - "name": "updatePoolMetadata", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { - "name": "metadata_", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "outputs": [], - "signature": "0xff94d958", - "stateMutability": "nonpayable" - } -] diff --git a/simulations/vip-372/abi/Prime.json b/simulations/vip-372/abi/Prime.json deleted file mode 100644 index e8bfa99ff..000000000 --- a/simulations/vip-372/abi/Prime.json +++ /dev/null @@ -1,763 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, - { "internalType": "address", "name": "_nativeMarket", "type": "address" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, - { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, - { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, - { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, - { "internalType": "bool", "name": "_timeBased", "type": "bool" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, - { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidComptroller", "type": "error" }, - { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "n", "type": "uint256" }, - { "internalType": "uint256", "name": "d", "type": "uint256" } - ], - "name": "InvalidFraction", - "type": "error" - }, - { "inputs": [], "name": "InvalidLength", "type": "error" }, - { "inputs": [], "name": "InvalidLimit", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, - { "inputs": [], "name": "InvalidVToken", "type": "error" }, - { - "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], - "name": "LnNonRealResult", - "type": "error" - }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, - { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, - { "inputs": [], "name": "MarketNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, - { "inputs": [], "name": "WaitMoreTime", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, - { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } - ], - "name": "AlphaUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "Burn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "InterestClaimed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "MarketAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } - ], - "name": "MintLimitsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } - ], - "name": "MultiplierUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } - ], - "name": "StakedAtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "TokenUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "UserScoreUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "MAXIMUM_XVS_CAP", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MINIMUM_STAKED_XVS", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_MARKET", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "STAKING_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WRAPPED_NATIVE_TOKEN", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "accrueInterest", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" } - ], - "name": "accrueInterestAndUpdateScore", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "addMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "alphaDenominator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "alphaNumerator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "calculateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "claimTimeRemaining", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "uint256", "name": "borrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supply", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } - ], - "name": "estimateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "getInterestAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "getPendingRewards", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "internalType": "struct PrimeStorageV1.PendingReward[]", - "name": "pendingRewards", - "type": "tuple[]" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "incomeDistributionYearly", - "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "xvsVault_", "type": "address" }, - { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, - { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, - { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, - { "internalType": "address", "name": "comptroller_", "type": "address" }, - { "internalType": "address", "name": "oracle_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "name": "initializeV2", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "interests", - "outputs": [ - { "internalType": "uint256", "name": "accrued", "type": "uint256" }, - { "internalType": "uint256", "name": "score", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "irrevocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "", "type": "uint256" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "isScoreUpdated", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "isUserPrimeHolder", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, - { "internalType": "address[]", "name": "users", "type": "address[]" } - ], - "name": "issue", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, - { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, - { "internalType": "bool", "name": "exists", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "nextScoreUpdateRoundId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingScoreUpdates", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "primeLiquidityProvider", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "revocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } - ], - "name": "setLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "users", "type": "address[]" }, - { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } - ], - "name": "setStakedAt", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "stakedAt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokens", - "outputs": [ - { "internalType": "bool", "name": "exists", "type": "bool" }, - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalIrrevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalRevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalScoreUpdatesRequired", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "unreleasedPLPIncome", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, - { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } - ], - "name": "updateAlpha", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "updateMultipliers", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], - "name": "updateScores", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "vTokenForAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "xvsUpdated", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVault", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultPoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/PrimeLiquidityProvider.json b/simulations/vip-372/abi/PrimeLiquidityProvider.json deleted file mode 100644 index 02ca8e0bf..000000000 --- a/simulations/vip-372/abi/PrimeLiquidityProvider.json +++ /dev/null @@ -1,385 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "_timeBased", "type": "bool" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, - { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "balance", "type": "uint256" } - ], - "name": "InsufficientBalance", - "type": "error" - }, - { "inputs": [], "name": "InvalidArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidCaller", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "speed", "type": "uint256" }, - { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } - ], - "name": "InvalidDistributionSpeed", - "type": "error" - }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenAlreadyInitialized", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "TokenNotInitialized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "MaxTokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } - ], - "name": "PrimeTokenUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenDistributionInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "TokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokenTransferredToPrime", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokensAccrued", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "accrueTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "getEffectiveDistributionSpeed", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], - "name": "initializeTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "lastAccruedBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastAccruedBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "maxTokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } - ], - "name": "setMaxTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } - ], - "name": "setTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, - { "internalType": "address", "name": "to_", "type": "address" }, - { "internalType": "uint256", "name": "amount_", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "tokenAmountAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/ProtocolShareReserve.json b/simulations/vip-372/abi/ProtocolShareReserve.json deleted file mode 100644 index b33d7c495..000000000 --- a/simulations/vip-372/abi/ProtocolShareReserve.json +++ /dev/null @@ -1,356 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, - { "internalType": "address", "name": "_wbnb", "type": "address" }, - { "internalType": "address", "name": "_vbnb", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetReleased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IProtocolShareReserve.IncomeType", - "name": "incomeType", - "type": "uint8" - }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "AssetsReservesUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } - ], - "name": "PoolRegistryUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "ReservesUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "CORE_POOL_COMPTROLLER", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MAX_PERCENT", - "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "internalType": "struct ProtocolShareReserve.DistributionConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "addOrUpdateDistributionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } - ], - "name": "assetsReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "distributionTargets", - "outputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "getPercentageDistribution", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "getUnreleasedFunds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address[]", "name": "assets", "type": "address[]" } - ], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "name": "removeDistributionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], - "name": "setPoolRegistry", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAssetReserve", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalDistributions", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/RewardDistributor.json b/simulations/vip-372/abi/RewardDistributor.json deleted file mode 100644 index 249fdd111..000000000 --- a/simulations/vip-372/abi/RewardDistributor.json +++ /dev/null @@ -1,532 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "BorrowLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "BorrowLastRewardingBlockUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "ContributorRewardTokenSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } - ], - "name": "ContributorRewardsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } - ], - "name": "DistributedBorrowerRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } - ], - "name": "DistributedSupplierRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "MarketInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "indexed": false, - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "RewardTokenBorrowIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenBorrowSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RewardTokenGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "RewardTokenSupplyIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenSupplySpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "SupplyLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "SupplyLastRewardingBlockUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "INITIAL_INDEX", - "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "holder", "type": "address" }, - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } - ], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "distributeBorrowerRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "supplier", "type": "address" } - ], - "name": "distributeSupplierRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "recipient", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "grantRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, - { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "initializeMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastContributorBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "rewardToken", - "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenBorrowerIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenContributorSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenSupplierIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplySpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contributor", "type": "address" }, - { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } - ], - "name": "setContributorRewardTokenSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } - ], - "name": "setLastRewardingBlockTimestamps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, - { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } - ], - "name": "setLastRewardingBlocks", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } - ], - "name": "setRewardTokenSpeeds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], - "name": "updateContributorRewards", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "updateRewardTokenBorrowIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "updateRewardTokenSupplyIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/SingleTokenConverter.json b/simulations/vip-372/abi/SingleTokenConverter.json deleted file mode 100644 index 8ea10cc8d..000000000 --- a/simulations/vip-372/abi/SingleTokenConverter.json +++ /dev/null @@ -1,587 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } - ], - "name": "AmountInHigherThanMax", - "type": "error" - }, - { "inputs": [], "name": "AmountInMismatched", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } - ], - "name": "AmountOutLowerThanMinRequired", - "type": "error" - }, - { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, - { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, - { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, - { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, - { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, - { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } - ], - "name": "IncentiveTooHigh", - "type": "error" - }, - { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, - { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, - { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, - { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, - { "inputs": [], "name": "InvalidToAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, - { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetTransferredToDestination", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } - ], - "name": "BaseAssetUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "oldAccess", - "type": "uint8" - }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "newAccess", - "type": "uint8" - } - ], - "name": "ConversionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } - ], - "name": "ConverterNetworkAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } - ], - "name": "DestinationAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } - ], - "name": "MinAmountToConvertUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, - { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } - ], - "name": "PriceOracleUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "inputs": [], - "name": "MAX_INCENTIVE", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "baseAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "conversionConfigurations", - "outputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "conversionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "converterNetwork", - "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "destinationAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, - { "internalType": "address", "name": "destinationAddress_", "type": "address" }, - { "internalType": "address", "name": "baseAsset_", "type": "address" }, - { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "minAmountToConvert", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "priceOracle", - "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], - "name": "setBaseAsset", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig", - "name": "conversionConfig", - "type": "tuple" - } - ], - "name": "setConversionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", - "name": "conversionConfigs", - "type": "tuple[]" - } - ], - "name": "setConversionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], - "name": "setConverterNetwork", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], - "name": "setDestination", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], - "name": "setMinAmountToConvert", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/SingleTokenConverterBeacon.json b/simulations/vip-372/abi/SingleTokenConverterBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/simulations/vip-372/abi/SingleTokenConverterBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/VToken.json b/simulations/vip-372/abi/VToken.json deleted file mode 100644 index d8cc1aae4..000000000 --- a/simulations/vip-372/abi/VToken.json +++ /dev/null @@ -1,861 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], - "name": "AddReservesFactorFreshCheck", - "type": "error" - }, - { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, - { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, - { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], - "name": "LiquidateAccrueCollateralInterestFailed", - "type": "error" - }, - { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, - { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, - { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, - { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, - { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, - { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, - { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "AccrueInterest", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtRecovered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "Borrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "HealBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "LiquidateBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } - ], - "name": "NewComptroller", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "oldInterestRateModel", - "type": "address" - }, - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "newInterestRateModel", - "type": "address" - } - ], - "name": "NewMarketInterestRateModel", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } - ], - "name": "NewProtocolSeizeShare", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } - ], - "name": "NewProtocolShareReserve", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } - ], - "name": "NewReduceReservesBlockDelta", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } - ], - "name": "NewReserveFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } - ], - "name": "NewShortfallContract", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ProtocolSeize", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Redeem", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "RepayBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "ReservesAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "SpreadReservesReduced", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Transfer", - "type": "event" - }, - { - "inputs": [], - "name": "NO_ERROR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrualBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrueInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], - "name": "addReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "owner", "type": "address" }, - { "internalType": "address", "name": "spender", "type": "address" } - ], - "name": "allowance", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "approve", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "badDebt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], - "name": "badDebtRecovered", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOfUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], - "name": "borrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "borrowIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "borrowRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } - ], - "name": "decreaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "forceLiquidateBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountSnapshot", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCash", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "healBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "addedValue", "type": "uint256" } - ], - "name": "increaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "underlying_", "type": "address" }, - { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, - { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, - { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, - { "internalType": "string", "name": "name_", "type": "string" }, - { "internalType": "string", "name": "symbol_", "type": "string" }, - { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, - { "internalType": "address", "name": "admin_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { - "components": [ - { "internalType": "address", "name": "shortfall", "type": "address" }, - { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } - ], - "internalType": "struct VTokenInterface.RiskManagementInit", - "name": "riskManagement", - "type": "tuple" - }, - { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "interestRateModel", - "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isVToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } - ], - "name": "liquidateBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], - "name": "mint", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "mintBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolSeizeShareMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolShareReserve", - "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], - "name": "redeem", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], - "name": "redeemUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } - ], - "name": "redeemUnderlyingBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], - "name": "reduceReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockDelta", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], - "name": "repayBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "repayBorrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reserveFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], - "name": "setInterestRateModel", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], - "name": "setProtocolSeizeShare", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], - "name": "setProtocolShareReserve", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], - "name": "setReduceReservesBlockDelta", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], - "name": "setReserveFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], - "name": "setShortfallContract", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "shortfall", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "supplyRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrows", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrowsCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "totalReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transfer", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transferFrom", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "underlying", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/VTokenBeacon.json b/simulations/vip-372/abi/VTokenBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/simulations/vip-372/abi/VTokenBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/XVSStore.json b/simulations/vip-372/abi/XVSStore.json deleted file mode 100644 index 2d9ea2bb2..000000000 --- a/simulations/vip-372/abi/XVSStore.json +++ /dev/null @@ -1,130 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "AdminTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } - ], - "name": "NewPendingAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnerTransferred", - "type": "event" - }, - { - "constant": false, - "inputs": [], - "name": "acceptAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "emergencyRewardWithdraw", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokens", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "token", "type": "address" }, - { "internalType": "address", "name": "_to", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "safeRewardTransfer", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], - "name": "setNewOwner", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], - "name": "setPendingAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "bool", "name": "status", "type": "bool" } - ], - "name": "setRewardToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/XVSVault.json b/simulations/vip-372/abi/XVSVault.json deleted file mode 100644 index 51d8d540c..000000000 --- a/simulations/vip-372/abi/XVSVault.json +++ /dev/null @@ -1,787 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Claim", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } - ], - "name": "DelegateChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "DelegateVotesChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Deposit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ExecutedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "name": "PoolAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } - ], - "name": "PoolUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RequestedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } - ], - "name": "RewardAmountUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } - ], - "name": "StoreUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } - ], - "name": "VaultDebtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } - ], - "name": "WithdrawalLockingPeriodUpdated", - "type": "event" - }, - { - "constant": true, - "inputs": [], - "name": "DELEGATION_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "DOMAIN_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "MAX_LOCK_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "SECONDS_PER_YEAR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], - "name": "_become", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, - { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, - { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } - ], - "name": "add", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint32", "name": "", "type": "uint32" } - ], - "name": "checkpoints", - "outputs": [ - { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, - { "internalType": "uint96", "name": "votes", "type": "uint96" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_account", "type": "address" }, - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "claim", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], - "name": "delegate", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "delegatee", "type": "address" }, - { "internalType": "uint256", "name": "nonce", "type": "uint256" }, - { "internalType": "uint256", "name": "expiry", "type": "uint256" }, - { "internalType": "uint8", "name": "v", "type": "uint8" }, - { "internalType": "bytes32", "name": "r", "type": "bytes32" }, - { "internalType": "bytes32", "name": "s", "type": "bytes32" } - ], - "name": "delegateBySig", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "delegates", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "deposit", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "executeWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getCurrentVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getEligibleWithdrawalAmount", - "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } - ], - "name": "getPriorVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getRequestedAmount", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getUserInfo", - "outputs": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, - { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getWithdrawalRequests", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, - { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } - ], - "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", - "name": "", - "type": "tuple[]" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "name": "initializeTimeManager", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isStakedToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "nonces", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "numCheckpoints", - "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "pause", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingReward", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "pendingRewardTransfers", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingWithdrawalsBeforeUpgrade", - "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingXVSVaultImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "poolInfos", - "outputs": [ - { "internalType": "contract IBEP20", "name": "token", "type": "address" }, - { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, - { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], - "name": "poolLength", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primePoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeToken", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "requestWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "resume", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], - "name": "rewardTokenAmountsPerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAmountsPerBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } - ], - "name": "set", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], - "name": "setAccessControl", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, - { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } - ], - "name": "setPrimeToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } - ], - "name": "setRewardAmountPerBlockOrSecond", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } - ], - "name": "setWithdrawalLockingPeriod", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_xvs", "type": "address" }, - { "internalType": "address", "name": "_xvsStore", "type": "address" } - ], - "name": "setXvsStore", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAllocPoints", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "totalPendingWithdrawals", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "updatePool", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "vaultPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsStore", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/XVSVaultProxy.json b/simulations/vip-372/abi/XVSVaultProxy.json deleted file mode 100644 index 070a7fa56..000000000 --- a/simulations/vip-372/abi/XVSVaultProxy.json +++ /dev/null @@ -1,122 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "error", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "info", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "detail", "type": "uint256" } - ], - "name": "Failure", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAdmin", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "NewAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldImplementation", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newImplementation", "type": "address" } - ], - "name": "NewImplementation", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } - ], - "name": "NewPendingAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldPendingImplementation", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPendingImplementation", "type": "address" } - ], - "name": "NewPendingImplementation", - "type": "event" - }, - { "payable": true, "stateMutability": "payable", "type": "fallback" }, - { - "constant": false, - "inputs": [], - "name": "_acceptAdmin", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "_acceptImplementation", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "newPendingAdmin", "type": "address" }], - "name": "_setPendingAdmin", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "newPendingImplementation", "type": "address" }], - "name": "_setPendingImplementation", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingXVSVaultImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/boundValidator.json b/simulations/vip-372/abi/boundValidator.json deleted file mode 100644 index d16c8fb08..000000000 --- a/simulations/vip-372/abi/boundValidator.json +++ /dev/null @@ -1,498 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "previousAdmin", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAdmin", - "type": "address" - } - ], - "name": "AdminChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "beacon", - "type": "address" - } - ], - "name": "BeaconUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "implementation", - "type": "address" - } - ], - "name": "Upgraded", - "type": "event" - }, - { - "stateMutability": "payable", - "type": "fallback" - }, - { - "inputs": [], - "name": "admin", - "outputs": [ - { - "internalType": "address", - "name": "admin_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [ - { - "internalType": "address", - "name": "implementation_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - } - ], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - }, - { - "internalType": "bytes", - "name": "data", - "type": "bytes" - } - ], - "name": "upgradeToAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "upperBound", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "lowerBound", - "type": "uint256" - } - ], - "name": "ValidateConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig", - "name": "config", - "type": "tuple" - } - ], - "name": "setValidateConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "setValidateConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "validateConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "reportedPrice", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "anchorPrice", - "type": "uint256" - } - ], - "name": "validatePriceWithAnchorPrice", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_logic", - "type": "address" - }, - { - "internalType": "address", - "name": "admin_", - "type": "address" - }, - { - "internalType": "bytes", - "name": "_data", - "type": "bytes" - } - ], - "stateMutability": "payable", - "type": "constructor" - } -] diff --git a/simulations/vip-372/abi/chainlinkOracle.json b/simulations/vip-372/abi/chainlinkOracle.json deleted file mode 100644 index cdd689acb..000000000 --- a/simulations/vip-372/abi/chainlinkOracle.json +++ /dev/null @@ -1,459 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "vBnbAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "previousPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "requestedPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newPriceMantissa", - "type": "uint256" - } - ], - "name": "PricePosted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManager", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "prices", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - } - ], - "name": "setDirectPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VBep20Interface", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "underlyingPriceMantissa", - "type": "uint256" - } - ], - "name": "setUnderlyingPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "tokenConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/resilientOracle.json b/simulations/vip-372/abi/resilientOracle.json deleted file mode 100644 index 35f52caa0..000000000 --- a/simulations/vip-372/abi/resilientOracle.json +++ /dev/null @@ -1,640 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "nativeMarketAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - }, - { - "internalType": "contract BoundValidatorInterface", - "name": "_boundValidator", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "OracleEnabled", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - } - ], - "name": "OracleSet", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "mainOracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "pivotOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "fallbackOracle", - "type": "address" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "INVALID_PRICE", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_TOKEN_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "boundValidator", - "outputs": [ - { - "internalType": "contract BoundValidatorInterface", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - }, - { - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "enableOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "getOracle", - "outputs": [ - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "bool", - "name": "enabled", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getTokenConfig", - "outputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "nativeMarket", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "setOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "updateAssetPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "updatePrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/sFrxETHOracle.json b/simulations/vip-372/abi/sFrxETHOracle.json deleted file mode 100644 index b461549ba..000000000 --- a/simulations/vip-372/abi/sFrxETHOracle.json +++ /dev/null @@ -1,148 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_sfrxEthFraxOracle", "type": "address" }, - { "internalType": "address", "name": "_sfrxETH", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "BadPriceData", "type": "error" }, - { "inputs": [], "name": "InvalidTokenAddress", "type": "error" }, - { "inputs": [], "name": "PriceDifferenceExceeded", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxAllowedPriceDifference", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxAllowedPriceDifference", "type": "uint256" } - ], - "name": "MaxAllowedPriceDifferenceUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [], - "name": "SFRXETH", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "SFRXETH_FRAX_ORACLE", - "outputs": [{ "internalType": "contract ISfrxEthFraxOracle", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], - "name": "getPrice", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxAllowedPriceDifference", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" }], - "name": "setMaxAllowedPriceDifference", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/treasury.json b/simulations/vip-372/abi/treasury.json deleted file mode 100644 index 18aabb61a..000000000 --- a/simulations/vip-372/abi/treasury.json +++ /dev/null @@ -1,86 +0,0 @@ -[ - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryNative", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryToken", - "type": "event" - }, - { "stateMutability": "payable", "type": "fallback" }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryNative", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "stateMutability": "payable", "type": "receive" } -] diff --git a/simulations/vip-372/abi/xvs.json b/simulations/vip-372/abi/xvs.json deleted file mode 100644 index 69092bb4a..000000000 --- a/simulations/vip-372/abi/xvs.json +++ /dev/null @@ -1,716 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user", - "type": "address" - } - ], - "name": "AccountBlacklisted", - "type": "error" - }, - { - "inputs": [], - "name": "AddressesMustDiffer", - "type": "error" - }, - { - "inputs": [], - "name": "MintLimitExceed", - "type": "error" - }, - { - "inputs": [], - "name": "MintedAmountExceed", - "type": "error" - }, - { - "inputs": [], - "name": "NewCapNotGreaterThanMintedTokens", - "type": "error" - }, - { - "inputs": [], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "user", - "type": "address" - }, - { - "indexed": false, - "internalType": "bool", - "name": "value", - "type": "bool" - } - ], - "name": "BlacklistUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "MintCapChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitDecreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "source", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "destination", - "type": "address" - } - ], - "name": "MintedTokensMigrated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Transfer", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "internalType": "address", - "name": "spender", - "type": "address" - } - ], - "name": "allowance", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "approve", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [ - { - "internalType": "uint8", - "name": "", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "subtractedValue", - "type": "uint256" - } - ], - "name": "decreaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "addedValue", - "type": "uint256" - } - ], - "name": "increaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - } - ], - "name": "isBlackListed", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "source_", - "type": "address" - }, - { - "internalType": "address", - "name": "destination_", - "type": "address" - } - ], - "name": "migrateMinterTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "mint", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToCap", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToMintedAmount", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newAccessControlAddress_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "minter_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "setMintCap", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transfer", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transferFrom", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - }, - { - "internalType": "bool", - "name": "value_", - "type": "bool" - } - ], - "name": "updateBlacklist", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-372/abi/xvsBridgeAdmin.json b/simulations/vip-372/abi/xvsBridgeAdmin.json deleted file mode 100644 index 024450a40..000000000 --- a/simulations/vip-372/abi/xvsBridgeAdmin.json +++ /dev/null @@ -1,329 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "XVSBridge_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "string", - "name": "signature", - "type": "string" - }, - { - "indexed": false, - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "name": "FunctionRegistryChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "stateMutability": "nonpayable", - "type": "fallback" - }, - { - "inputs": [], - "name": "XVSBridge", - "outputs": [ - { - "internalType": "contract IXVSProxyOFT", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes4", - "name": "", - "type": "bytes4" - } - ], - "name": "functionRegistry", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "isTrustedRemote", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner_", - "type": "address" - } - ], - "name": "transferBridgeOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "string[]", - "name": "signatures_", - "type": "string[]" - }, - { - "internalType": "bool[]", - "name": "active_", - "type": "bool[]" - } - ], - "name": "upsertSignature", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-372/arbitrumone.ts b/simulations/vip-372/arbitrumone.ts deleted file mode 100644 index ac8c1a3ce..000000000 --- a/simulations/vip-372/arbitrumone.ts +++ /dev/null @@ -1,82 +0,0 @@ -import { expect } from "chai"; -import { Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; - -import vip014 from "../../multisig/proposals/arbitrumone/vip-014"; -import { - COMPTROLLERS, - PLP, - PRIME, - PSR, - REWARD_DISTRIBUTORS, - VTOKENS, - XVS_STORE, -} from "../../multisig/proposals/arbitrumone/vip-014"; -import vip372 from "../../vips/vip-372/bscmainnet"; -import COMPTROLLER_ABI from "./abi/Comptroller.json"; -import PRIME_ABI from "./abi/Prime.json"; -import PRIME_LIQUIDITY_PROVIDER_ABI from "./abi/PrimeLiquidityProvider.json"; -import PSR_ABI from "./abi/ProtocolShareReserve.json"; -import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistributor.json"; -import VTOKEN_ABI from "./abi/VToken.json"; -import XVS_STORE_ABI from "./abi/XVSStore.json"; -import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; - -const { arbitrumone } = NETWORK_ADDRESSES; - -forking(241112064, async () => { - const provider = ethers.provider; - let prime: Contract; - let plp: Contract; - const xvsVaultProxy = new ethers.Contract(arbitrumone.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); - const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); - - before(async () => { - prime = new ethers.Contract(PRIME, PRIME_ABI, provider); - plp = new ethers.Contract(PLP, PRIME_LIQUIDITY_PROVIDER_ABI, provider); - - await pretendExecutingVip(await vip014()); - }); - - testForkedNetworkVipCommands("vip350", await vip372()); - - describe("Post-VIP behavior", async () => { - it(`correct owner `, async () => { - expect(await prime.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); - expect(await plp.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); - }); - - for (const rewardDistributor of REWARD_DISTRIBUTORS) { - it(`correct owner for ${rewardDistributor}`, async () => { - const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); - expect(await c.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); - }); - } - - it(`correct owner for psr`, async () => { - const psr = new ethers.Contract(PSR, PSR_ABI, provider); - expect(await psr.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`correct owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`correct owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.owner()).to.equal(arbitrumone.NORMAL_TIMELOCK); - }); - } - - it("should have the correct pending owner", async () => { - expect(await xvsVaultProxy.admin()).to.equal(arbitrumone.NORMAL_TIMELOCK); - expect(await xvsStore.admin()).to.equal(arbitrumone.NORMAL_TIMELOCK); - }); - }); -}); diff --git a/simulations/vip-372/arbitrumsepolia.ts b/simulations/vip-372/arbitrumsepolia.ts deleted file mode 100644 index d5b0e4b05..000000000 --- a/simulations/vip-372/arbitrumsepolia.ts +++ /dev/null @@ -1,81 +0,0 @@ -import { expect } from "chai"; -import { Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; - -import vip014 from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import { - COMPTROLLERS, - PLP, - PRIME, - PSR, - REWARD_DISTRIBUTORS, - VTOKENS, - XVS_STORE, -} from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import vip372 from "../../vips/vip-372/bsctestnet"; -import COMPTROLLER_ABI from "./abi/Comptroller.json"; -import PRIME_ABI from "./abi/Prime.json"; -import PRIME_LIQUIDITY_PROVIDER_ABI from "./abi/PrimeLiquidityProvider.json"; -import PSR_ABI from "./abi/ProtocolShareReserve.json"; -import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistributor.json"; -import VTOKEN_ABI from "./abi/VToken.json"; -import XVS_STORE_ABI from "./abi/XVSStore.json"; -import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; - -const { arbitrumsepolia } = NETWORK_ADDRESSES; - -forking(87457288, async () => { - const provider = ethers.provider; - let prime: Contract; - let plp: Contract; - const xvsVaultProxy = new ethers.Contract(arbitrumsepolia.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); - const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); - - before(async () => { - prime = new ethers.Contract(PRIME, PRIME_ABI, provider); - plp = new ethers.Contract(PLP, PRIME_LIQUIDITY_PROVIDER_ABI, provider); - await pretendExecutingVip(await vip014()); - }); - - testForkedNetworkVipCommands("vip372", await vip372()); - - describe("Post-VIP behavior", async () => { - it(`correct owner `, async () => { - expect(await prime.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - expect(await plp.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - - for (const rewardDistributor of REWARD_DISTRIBUTORS) { - it(`correct owner for ${rewardDistributor}`, async () => { - const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); - expect(await c.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - } - - it(`correct owner for psr`, async () => { - const psr = new ethers.Contract(PSR, PSR_ABI, provider); - expect(await psr.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`correct owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`correct owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.owner()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - } - - it("should have the correct pending owner", async () => { - expect(await xvsVaultProxy.admin()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - expect(await xvsStore.admin()).to.equal(arbitrumsepolia.NORMAL_TIMELOCK); - }); - }); -}); diff --git a/simulations/vip-372/bscmainnet.ts b/simulations/vip-372/bscmainnet.ts deleted file mode 100644 index cbe3143d0..000000000 --- a/simulations/vip-372/bscmainnet.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { expectEvents } from "../../src/utils"; -import { forking, testVip } from "../../src/vip-framework"; -import vip372 from "../../vips/vip-372/bscmainnet"; -import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; - -forking(40343666, async () => { - testVip("vip372 XVS vault permission proposal", await vip372(), { - callbackAfterExecution: async txResponse => { - await expectEvents( - txResponse, - [OMNICHAIN_PROPOSAL_SENDER_ABI], - ["ExecuteRemoteProposal", "StorePayload"], - [3, 0], - ); - }, - }); -}); diff --git a/simulations/vip-372/bsctestnet.ts b/simulations/vip-372/bsctestnet.ts deleted file mode 100644 index 3f190a00f..000000000 --- a/simulations/vip-372/bsctestnet.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { expectEvents } from "../../src/utils"; -import { forking, testVip } from "../../src/vip-framework"; -import vip372 from "../../vips/vip-372/bsctestnet"; -import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; - -forking(41938696, async () => { - testVip("vip372 XVS vault permission proposal", await vip372(), { - callbackAfterExecution: async txResponse => { - await expectEvents( - txResponse, - [OMNICHAIN_PROPOSAL_SENDER_ABI], - ["ExecuteRemoteProposal", "StorePayload"], - [3, 0], - ); - }, - }); -}); diff --git a/simulations/vip-372/ethereum.ts b/simulations/vip-372/ethereum.ts deleted file mode 100644 index de650a76e..000000000 --- a/simulations/vip-372/ethereum.ts +++ /dev/null @@ -1,97 +0,0 @@ -import { expect } from "chai"; -import { Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; - -import vip061 from "../../multisig/proposals/ethereum/vip-061"; -import { - COMPTROLLERS, - CONVERTERS, - CONVERTER_NETWORK, - PLP, - PRIME, - PSR, - REWARD_DISTRIBUTORS, - VTOKENS, - XVS_STORE, -} from "../../multisig/proposals/ethereum/vip-061"; -import vip372 from "../../vips/vip-372/bscmainnet"; -import COMPTROLLER_ABI from "./abi/Comptroller.json"; -import CONVERTER_NETWORK_ABI from "./abi/ConverterNetwork.json"; -import PRIME_ABI from "./abi/Prime.json"; -import PRIME_LIQUIDITY_PROVIDER_ABI from "./abi/PrimeLiquidityProvider.json"; -import PSR_ABI from "./abi/ProtocolShareReserve.json"; -import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistributor.json"; -import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; -import VTOKEN_ABI from "./abi/VToken.json"; -import XVS_STORE_ABI from "./abi/XVSStore.json"; -import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; - -const { ethereum } = NETWORK_ADDRESSES; - -forking(20482317, async () => { - const provider = ethers.provider; - let prime: Contract; - let plp: Contract; - const xvsVaultProxy = new ethers.Contract(ethereum.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); - const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); - - before(async () => { - prime = new ethers.Contract(PRIME, PRIME_ABI, provider); - plp = new ethers.Contract(PLP, PRIME_LIQUIDITY_PROVIDER_ABI, provider); - await pretendExecutingVip(await vip061()); - }); - - testForkedNetworkVipCommands("vip350", await vip372()); - - describe("Post-VIP behavior", async () => { - for (const converter of CONVERTERS) { - it(`owner for ${converter}`, async () => { - const c = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); - expect(await c.owner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - } - - it(`owner for converter network`, async () => { - const c = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); - expect(await c.owner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - - it(`correct owner `, async () => { - expect(await prime.owner()).to.equal(ethereum.NORMAL_TIMELOCK); - expect(await plp.owner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - - for (const rewardDistributor of REWARD_DISTRIBUTORS) { - it(`correct owner for ${rewardDistributor}`, async () => { - const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); - expect(await c.owner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - } - - it(`correct owner for psr`, async () => { - const psr = new ethers.Contract(PSR, PSR_ABI, provider); - expect(await psr.owner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`correct owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.owner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`correct owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.owner()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - } - - it("should have the correct pending owner", async () => { - expect(await xvsVaultProxy.admin()).to.equal(ethereum.NORMAL_TIMELOCK); - expect(await xvsStore.admin()).to.equal(ethereum.NORMAL_TIMELOCK); - }); - }); -}); diff --git a/simulations/vip-372/opbnbmainnet.ts b/simulations/vip-372/opbnbmainnet.ts deleted file mode 100644 index 2a9a60f45..000000000 --- a/simulations/vip-372/opbnbmainnet.ts +++ /dev/null @@ -1,53 +0,0 @@ -import { expect } from "chai"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; - -import vip021 from "../../multisig/proposals/opbnbmainnet/vip-021"; -import { COMPTROLLERS, PSR, VTOKENS, XVS_STORE } from "../../multisig/proposals/opbnbmainnet/vip-021"; -import vip372 from "../../vips/vip-372/bscmainnet"; -import COMPTROLLER_ABI from "./abi/Comptroller.json"; -import PSR_ABI from "./abi/ProtocolShareReserve.json"; -import VTOKEN_ABI from "./abi/VToken.json"; -import XVS_STORE_ABI from "./abi/XVSStore.json"; -import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; - -const { opbnbmainnet } = NETWORK_ADDRESSES; - -forking(31449867, async () => { - const provider = ethers.provider; - const xvsVaultProxy = new ethers.Contract(opbnbmainnet.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); - const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); - - before(async () => { - await pretendExecutingVip(await vip021()); - }); - - testForkedNetworkVipCommands("vip372", await vip372()); - - describe("Post-VIP behavior", async () => { - it(`correct owner for psr`, async () => { - const psr = new ethers.Contract(PSR, PSR_ABI, provider); - expect(await psr.owner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`correct owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.owner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`correct owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.owner()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); - }); - } - - it("should have the correct pending owner", async () => { - expect(await xvsVaultProxy.admin()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); - expect(await xvsStore.admin()).to.equal(opbnbmainnet.NORMAL_TIMELOCK); - }); - }); -}); diff --git a/simulations/vip-372/opbnbtestnet.ts b/simulations/vip-372/opbnbtestnet.ts deleted file mode 100644 index 79a0ca82a..000000000 --- a/simulations/vip-372/opbnbtestnet.ts +++ /dev/null @@ -1,52 +0,0 @@ -import { expect } from "chai"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; - -import vip021, { COMPTROLLERS, PSR, VTOKENS, XVS_STORE } from "../../multisig/proposals/opbnbtestnet/vip-021"; -import vip372 from "../../vips/vip-350/bsctestnet"; -import COMPTROLLER_ABI from "./abi/Comptroller.json"; -import PSR_ABI from "./abi/ProtocolShareReserve.json"; -import VTOKEN_ABI from "./abi/VToken.json"; -import XVS_STORE_ABI from "./abi/XVSStore.json"; -import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; - -const { opbnbtestnet } = NETWORK_ADDRESSES; - -forking(41684455, async () => { - const provider = ethers.provider; - const xvsVaultProxy = new ethers.Contract(opbnbtestnet.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); - const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); - - before(async () => { - await pretendExecutingVip(await vip021()); - }); - - testForkedNetworkVipCommands("vip372", await vip372()); - - describe("Post-VIP behavior", async () => { - it(`correct owner for psr`, async () => { - const psr = new ethers.Contract(PSR, PSR_ABI, provider); - expect(await psr.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`correct owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`correct owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.owner()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); - }); - } - - it("should have the correct pending owner", async () => { - expect(await xvsVaultProxy.admin()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); - expect(await xvsStore.admin()).to.equal(opbnbtestnet.NORMAL_TIMELOCK); - }); - }); -}); diff --git a/simulations/vip-372/sepolia.ts b/simulations/vip-372/sepolia.ts deleted file mode 100644 index 2c8bfd75a..000000000 --- a/simulations/vip-372/sepolia.ts +++ /dev/null @@ -1,97 +0,0 @@ -import { expect } from "chai"; -import { Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; - -import vip060 from "../../multisig/proposals/sepolia/vip-060"; -import { - COMPTROLLERS, - CONVERTERS, - CONVERTER_NETWORK, - PLP, - PRIME, - PSR, - REWARD_DISTRIBUTORS, - VTOKENS, - XVS_STORE, -} from "../../multisig/proposals/sepolia/vip-060"; -import vip372 from "../../vips/vip-372/bsctestnet"; -import COMPTROLLER_ABI from "./abi/Comptroller.json"; -import CONVERTER_NETWORK_ABI from "./abi/ConverterNetwork.json"; -import PRIME_ABI from "./abi/Prime.json"; -import PRIME_LIQUIDITY_PROVIDER_ABI from "./abi/PrimeLiquidityProvider.json"; -import PSR_ABI from "./abi/ProtocolShareReserve.json"; -import REWARD_DISTRIBUTOR_ABI from "./abi/RewardDistributor.json"; -import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; -import VTOKEN_ABI from "./abi/VToken.json"; -import XVS_STORE_ABI from "./abi/XVSStore.json"; -import XVS_VAULT_PROXY_ABI from "./abi/XVSVaultProxy.json"; - -const { sepolia } = NETWORK_ADDRESSES; - -forking(6850243, async () => { - const provider = ethers.provider; - let prime: Contract; - let plp: Contract; - const xvsVaultProxy = new ethers.Contract(sepolia.XVS_VAULT_PROXY, XVS_VAULT_PROXY_ABI, provider); - const xvsStore = new ethers.Contract(XVS_STORE, XVS_STORE_ABI, provider); - - before(async () => { - prime = new ethers.Contract(PRIME, PRIME_ABI, provider); - plp = new ethers.Contract(PLP, PRIME_LIQUIDITY_PROVIDER_ABI, provider); - await pretendExecutingVip(await vip060()); - }); - - testForkedNetworkVipCommands("vip350", await vip372()); - - describe("Post-VIP behavior", async () => { - for (const converter of CONVERTERS) { - it(`owner for ${converter}`, async () => { - const c = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); - expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - } - - it(`owner for converter network`, async () => { - const c = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); - expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - - it(`correct owner `, async () => { - expect(await prime.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - expect(await plp.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - - for (const rewardDistributor of REWARD_DISTRIBUTORS) { - it(`correct owner for ${rewardDistributor}`, async () => { - const c = new ethers.Contract(rewardDistributor, REWARD_DISTRIBUTOR_ABI, provider); - expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - } - - it(`correct owner for psr`, async () => { - const psr = new ethers.Contract(PSR, PSR_ABI, provider); - expect(await psr.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - - for (const comptrollerAddress of COMPTROLLERS) { - it(`correct owner for ${comptrollerAddress}`, async () => { - const c = new ethers.Contract(comptrollerAddress, COMPTROLLER_ABI, provider); - expect(await c.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - } - - for (const vTokenAddress of VTOKENS) { - it(`correct owner for ${vTokenAddress}`, async () => { - const v = new ethers.Contract(vTokenAddress, VTOKEN_ABI, provider); - expect(await v.owner()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - } - - it("should have the correct pending owner", async () => { - expect(await xvsVaultProxy.admin()).to.equal(sepolia.NORMAL_TIMELOCK); - expect(await xvsStore.admin()).to.equal(sepolia.NORMAL_TIMELOCK); - }); - }); -}); diff --git a/simulations/vip-373/abi/ACMCommandsAggregator.json b/simulations/vip-373/abi/ACMCommandsAggregator.json deleted file mode 100644 index 6650a3f3c..000000000 --- a/simulations/vip-373/abi/ACMCommandsAggregator.json +++ /dev/null @@ -1,242 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "_acm", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [], - "name": "EmptyPermissions", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "GrantPermissionsAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "GrantPermissionsExecuted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "RevokePermissionsAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "RevokePermissionsExecuted", - "type": "event" - }, - { - "inputs": [], - "name": "ACM", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "contractAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "functionSig", - "type": "string" - }, - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "internalType": "struct ACMCommandsAggregator.Permission[]", - "name": "_permissions", - "type": "tuple[]" - } - ], - "name": "addGrantPermissions", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "contractAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "functionSig", - "type": "string" - }, - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "internalType": "struct ACMCommandsAggregator.Permission[]", - "name": "_permissions", - "type": "tuple[]" - } - ], - "name": "addRevokePermissions", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "executeGrantPermissions", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "executeRevokePermissions", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "name": "grantPermissions", - "outputs": [ - { - "internalType": "address", - "name": "contractAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "functionSig", - "type": "string" - }, - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "name": "revokePermissions", - "outputs": [ - { - "internalType": "address", - "name": "contractAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "functionSig", - "type": "string" - }, - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/AccessControlManager.json b/simulations/vip-373/abi/AccessControlManager.json deleted file mode 100644 index 2ef119947..000000000 --- a/simulations/vip-373/abi/AccessControlManager.json +++ /dev/null @@ -1,157 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, - { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "PermissionGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, - { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "PermissionRevoked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, - { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } - ], - "name": "RoleAdminChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } - ], - "name": "RoleGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } - ], - "name": "RoleRevoked", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_ADMIN_ROLE", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], - "name": "getRoleAdmin", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" }, - { "internalType": "address", "name": "accountToPermit", "type": "address" } - ], - "name": "giveCallPermission", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "grantRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "hasPermission", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "hasRole", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "isAllowedToCall", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "renounceRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" }, - { "internalType": "address", "name": "accountToRevoke", "type": "address" } - ], - "name": "revokeCallPermission", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "revokeRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], - "name": "supportsInterface", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/Comptroller.json b/simulations/vip-373/abi/Comptroller.json deleted file mode 100644 index f3b2445ac..000000000 --- a/simulations/vip-373/abi/Comptroller.json +++ /dev/null @@ -1,929 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "ActionPaused", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "BorrowCapExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "CollateralExceedsThreshold", - "type": "error" - }, - { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, - { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, - { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } - ], - "name": "InsufficientCollateral", - "type": "error" - }, - { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, - { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, - { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, - { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketAlreadyListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "MarketNotCollateral", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketNotListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "MinimalCollateralViolated", - "type": "error" - }, - { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "PriceError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "SnapshotError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "SupplyCapExceeded", - "type": "error" - }, - { "inputs": [], "name": "TooMuchRepay", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "expectedSender", "type": "address" }, - { "internalType": "address", "name": "actualSender", "type": "address" } - ], - "name": "UnexpectedSender", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, - { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } - ], - "name": "ActionPausedMarket", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "DelegateUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "IsForcedLiquidationEnabledUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketEntered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketExited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "MarketSupported", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } - ], - "name": "NewBorrowCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } - ], - "name": "NewCloseFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } - ], - "name": "NewCollateralFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } - ], - "name": "NewLiquidationIncentive", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "NewLiquidationThreshold", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } - ], - "name": "NewMinLiquidatableCollateral", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "oldPriceOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "newPriceOracle", - "type": "address" - } - ], - "name": "NewPriceOracle", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } - ], - "name": "NewRewardsDistributor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } - ], - "name": "NewSupplyCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "accountAssets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "actionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], - "name": "addRewardsDistributor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "allMarkets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "approvedDelegates", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "borrowCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "contract VToken", "name": "vToken", "type": "address" } - ], - "name": "checkMembership", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "closeFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], - "name": "enterMarkets", - "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], - "name": "exitMarket", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAssetsIn", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getBorrowingPower", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "address", "name": "vTokenModify", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "getHypotheticalAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getRewardDistributors", - "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "getRewardsByMarket", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.RewardSpeeds[]", - "name": "rewardSpeeds", - "type": "tuple[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "healAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isComptroller", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isForcedLiquidationEnabled", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "isMarketListed", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [ - { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.LiquidationOrder[]", - "name": "orders", - "type": "tuple[]" - } - ], - "name": "liquidateAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "liquidateBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } - ], - "name": "liquidateCalculateSeizeTokens", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "liquidationIncentiveMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "bool", "name": "isListed", "type": "bool" }, - { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "minLiquidatableCollateral", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } - ], - "name": "mintVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "preBorrowHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "preLiquidateHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "preMintHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "preRedeemHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preRepayHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "seizerContract", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preSeizeHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "preTransferHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } - ], - "name": "repayBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seizeVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, - { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, - { "internalType": "bool", "name": "paused", "type": "bool" } - ], - "name": "setActionsPaused", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], - "name": "setCloseFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "setCollateralFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "setForcedLiquidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], - "name": "setLiquidationIncentive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } - ], - "name": "setMarketBorrowCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } - ], - "name": "setMarketSupplyCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], - "name": "setMinLiquidatableCollateral", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "supplyCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "supportMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "transferVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "delegate", "type": "address" }, - { "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "updateDelegate", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "updatePrices", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/ComptrollerBeacon.json b/simulations/vip-373/abi/ComptrollerBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/simulations/vip-373/abi/ComptrollerBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/ConverterNetwork.json b/simulations/vip-373/abi/ConverterNetwork.json deleted file mode 100644 index 396f12a91..000000000 --- a/simulations/vip-373/abi/ConverterNetwork.json +++ /dev/null @@ -1,205 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { "inputs": [], "name": "ConverterAlreadyExists", "type": "error" }, - { "inputs": [], "name": "ConverterDoesNotExist", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "InvalidMaxLoopsLimit", - "type": "error" - }, - { "inputs": [], "name": "InvalidTokenConverterAddress", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], - "name": "ConverterAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], - "name": "ConverterRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], - "name": "addTokenConverter", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "allConverters", - "outputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } - ], - "name": "findTokenConverters", - "outputs": [ - { "internalType": "address[]", "name": "converters", "type": "address[]" }, - { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } - ], - "name": "findTokenConvertersForConverters", - "outputs": [ - { "internalType": "address[]", "name": "converters", "type": "address[]" }, - { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getAllConverters", - "outputs": [{ "internalType": "contract IAbstractTokenConverter[]", "name": "converters", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_tokenConverter", "type": "address" }], - "name": "isTokenConverter", - "outputs": [{ "internalType": "bool", "name": "isConverter", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], - "name": "removeTokenConverter", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/DefaultProxyAdmin.json b/simulations/vip-373/abi/DefaultProxyAdmin.json deleted file mode 100644 index 9801cfcc7..000000000 --- a/simulations/vip-373/abi/DefaultProxyAdmin.json +++ /dev/null @@ -1,76 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "changeProxyAdmin", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" } - ], - "name": "upgrade", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" }, - { "internalType": "bytes", "name": "data", "type": "bytes" } - ], - "name": "upgradeAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/OmnichainProposalSender.json b/simulations/vip-373/abi/OmnichainProposalSender.json deleted file mode 100644 index 66fd4df02..000000000 --- a/simulations/vip-373/abi/OmnichainProposalSender.json +++ /dev/null @@ -1,314 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } - ], - "name": "ClearPayload", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } - ], - "name": "ExecuteRemoteProposal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } - ], - "name": "FallbackWithdraw", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } - ], - "name": "SetMaxDailyLimit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, - { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } - ], - "name": "SetTrustedRemoteAddress", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, - { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, - { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, - { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } - ], - "name": "StorePayload", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], - "name": "TrustedRemoteRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "LZ_ENDPOINT", - "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourCommandsSent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourWindowStart", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLastProposalSentTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToMaxDailyLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bool", "name": "useZro_", "type": "bool" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } - ], - "name": "estimateFees", - "outputs": [ - { "internalType": "uint256", "name": "", "type": "uint256" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, - { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } - ], - "name": "execute", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "to_", "type": "address" }, - { "internalType": "uint256", "name": "pId_", "type": "uint256" }, - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, - { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } - ], - "name": "fallbackWithdraw", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "version_", "type": "uint16" }, - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "configType_", "type": "uint256" } - ], - "name": "getConfig", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "proposalCount", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], - "name": "removeTrustedRemote", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "uint256", "name": "pId_", "type": "uint256" }, - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, - { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, - { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } - ], - "name": "retryExecute", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "version_", "type": "uint16" }, - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "configType_", "type": "uint256" }, - { "internalType": "bytes", "name": "config_", "type": "bytes" } - ], - "name": "setConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "limit_", "type": "uint256" } - ], - "name": "setMaxDailyLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], - "name": "setSendVersion", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "storedExecutionHashes", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "trustedRemoteLookup", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } -] diff --git a/simulations/vip-373/abi/PoolRegistry.json b/simulations/vip-373/abi/PoolRegistry.json deleted file mode 100644 index 31b1e2a17..000000000 --- a/simulations/vip-373/abi/PoolRegistry.json +++ /dev/null @@ -1,379 +0,0 @@ -[ - { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, - { - "name": "Unauthorized", - "type": "error", - "inputs": [ - { "name": "sender", "type": "address", "internalType": "address" }, - { "name": "calledContract", "type": "address", "internalType": "address" }, - { "name": "methodSignature", "type": "string", "internalType": "string" } - ] - }, - { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, - { - "name": "Initialized", - "type": "event", - "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], - "anonymous": false, - "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" - }, - { - "name": "MarketAdded", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" - }, - { - "name": "NewAccessControlManager", - "type": "event", - "inputs": [ - { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, - { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" - }, - { - "name": "OwnershipTransferStarted", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" - }, - { - "name": "OwnershipTransferred", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" - }, - { - "name": "PoolMetadataUpdated", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "oldMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - }, - { - "name": "newMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "anonymous": false, - "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" - }, - { - "name": "PoolNameSet", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, - { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } - ], - "anonymous": false, - "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" - }, - { - "name": "PoolRegistered", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "pool", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "anonymous": false, - "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" - }, - { - "name": "acceptOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x79ba5097", - "stateMutability": "nonpayable" - }, - { - "name": "accessControlManager", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "contract IAccessControlManagerV8" - } - ], - "constant": true, - "signature": "0xb4a0bdf3", - "stateMutability": "view" - }, - { - "name": "addMarket", - "type": "function", - "inputs": [ - { - "name": "input", - "type": "tuple", - "components": [ - { "name": "vToken", "type": "address", "internalType": "contract VToken" }, - { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, - { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, - { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, - { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, - { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistry.AddMarketInput" - } - ], - "outputs": [], - "signature": "0x23dc8d64", - "stateMutability": "nonpayable" - }, - { - "name": "addPool", - "type": "function", - "inputs": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, - { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, - { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } - ], - "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], - "signature": "0xeed873c2", - "stateMutability": "nonpayable" - }, - { - "name": "getAllPools", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "tuple[]", - "value": [], - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool[]" - } - ], - "constant": true, - "signature": "0xd88ff1f4", - "stateMutability": "view" - }, - { - "name": "getPoolByComptroller", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "constant": true, - "signature": "0x7aee632d", - "stateMutability": "view" - }, - { - "name": "getPoolsSupportedByAsset", - "type": "function", - "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], - "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], - "constant": true, - "signature": "0xf36dba38", - "stateMutability": "view" - }, - { - "name": "getVTokenForAsset", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "asset", "type": "address", "internalType": "address" } - ], - "outputs": [{ "name": "", "type": "address", "internalType": "address" }], - "constant": true, - "signature": "0x266e0a7f", - "stateMutability": "view" - }, - { - "name": "getVenusPoolMetadata", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "constant": true, - "signature": "0xa3aefa2c", - "stateMutability": "view" - }, - { - "name": "initialize", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xc4d66de8", - "stateMutability": "nonpayable" - }, - { - "name": "metadata", - "type": "function", - "inputs": [{ "name": "", "type": "address", "internalType": "address" }], - "outputs": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "constant": true, - "signature": "0x2ba21572", - "stateMutability": "view" - }, - { - "name": "owner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x8da5cb5b", - "stateMutability": "view" - }, - { - "name": "pendingOwner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0xe30c3978", - "stateMutability": "view" - }, - { - "name": "renounceOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x715018a6", - "stateMutability": "nonpayable" - }, - { - "name": "setAccessControlManager", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0x0e32cb86", - "stateMutability": "nonpayable" - }, - { - "name": "setPoolName", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "name", "type": "string", "internalType": "string" } - ], - "outputs": [], - "signature": "0x1cb6bb7e", - "stateMutability": "nonpayable" - }, - { - "name": "transferOwnership", - "type": "function", - "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xf2fde38b", - "stateMutability": "nonpayable" - }, - { - "name": "updatePoolMetadata", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { - "name": "metadata_", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "outputs": [], - "signature": "0xff94d958", - "stateMutability": "nonpayable" - } -] diff --git a/simulations/vip-373/abi/Prime.json b/simulations/vip-373/abi/Prime.json deleted file mode 100644 index e8bfa99ff..000000000 --- a/simulations/vip-373/abi/Prime.json +++ /dev/null @@ -1,763 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, - { "internalType": "address", "name": "_nativeMarket", "type": "address" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, - { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, - { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, - { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, - { "internalType": "bool", "name": "_timeBased", "type": "bool" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, - { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidComptroller", "type": "error" }, - { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "n", "type": "uint256" }, - { "internalType": "uint256", "name": "d", "type": "uint256" } - ], - "name": "InvalidFraction", - "type": "error" - }, - { "inputs": [], "name": "InvalidLength", "type": "error" }, - { "inputs": [], "name": "InvalidLimit", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, - { "inputs": [], "name": "InvalidVToken", "type": "error" }, - { - "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], - "name": "LnNonRealResult", - "type": "error" - }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, - { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, - { "inputs": [], "name": "MarketNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, - { "inputs": [], "name": "WaitMoreTime", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, - { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } - ], - "name": "AlphaUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "Burn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "InterestClaimed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "MarketAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } - ], - "name": "MintLimitsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } - ], - "name": "MultiplierUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } - ], - "name": "StakedAtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "TokenUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "UserScoreUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "MAXIMUM_XVS_CAP", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MINIMUM_STAKED_XVS", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_MARKET", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "STAKING_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WRAPPED_NATIVE_TOKEN", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "accrueInterest", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" } - ], - "name": "accrueInterestAndUpdateScore", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "addMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "alphaDenominator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "alphaNumerator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "calculateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "claimTimeRemaining", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "uint256", "name": "borrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supply", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } - ], - "name": "estimateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "getInterestAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "getPendingRewards", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "internalType": "struct PrimeStorageV1.PendingReward[]", - "name": "pendingRewards", - "type": "tuple[]" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "incomeDistributionYearly", - "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "xvsVault_", "type": "address" }, - { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, - { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, - { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, - { "internalType": "address", "name": "comptroller_", "type": "address" }, - { "internalType": "address", "name": "oracle_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "name": "initializeV2", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "interests", - "outputs": [ - { "internalType": "uint256", "name": "accrued", "type": "uint256" }, - { "internalType": "uint256", "name": "score", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "irrevocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "", "type": "uint256" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "isScoreUpdated", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "isUserPrimeHolder", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, - { "internalType": "address[]", "name": "users", "type": "address[]" } - ], - "name": "issue", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, - { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, - { "internalType": "bool", "name": "exists", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "nextScoreUpdateRoundId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingScoreUpdates", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "primeLiquidityProvider", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "revocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } - ], - "name": "setLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "users", "type": "address[]" }, - { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } - ], - "name": "setStakedAt", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "stakedAt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokens", - "outputs": [ - { "internalType": "bool", "name": "exists", "type": "bool" }, - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalIrrevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalRevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalScoreUpdatesRequired", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "unreleasedPLPIncome", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, - { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } - ], - "name": "updateAlpha", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "updateMultipliers", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], - "name": "updateScores", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "vTokenForAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "xvsUpdated", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVault", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultPoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/PrimeLiquidityProvider.json b/simulations/vip-373/abi/PrimeLiquidityProvider.json deleted file mode 100644 index 02ca8e0bf..000000000 --- a/simulations/vip-373/abi/PrimeLiquidityProvider.json +++ /dev/null @@ -1,385 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "_timeBased", "type": "bool" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, - { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "balance", "type": "uint256" } - ], - "name": "InsufficientBalance", - "type": "error" - }, - { "inputs": [], "name": "InvalidArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidCaller", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "speed", "type": "uint256" }, - { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } - ], - "name": "InvalidDistributionSpeed", - "type": "error" - }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenAlreadyInitialized", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "TokenNotInitialized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "MaxTokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } - ], - "name": "PrimeTokenUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenDistributionInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "TokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokenTransferredToPrime", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokensAccrued", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "accrueTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "getEffectiveDistributionSpeed", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], - "name": "initializeTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "lastAccruedBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastAccruedBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "maxTokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } - ], - "name": "setMaxTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } - ], - "name": "setTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, - { "internalType": "address", "name": "to_", "type": "address" }, - { "internalType": "uint256", "name": "amount_", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "tokenAmountAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/ProtocolShareReserve.json b/simulations/vip-373/abi/ProtocolShareReserve.json deleted file mode 100644 index b33d7c495..000000000 --- a/simulations/vip-373/abi/ProtocolShareReserve.json +++ /dev/null @@ -1,356 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, - { "internalType": "address", "name": "_wbnb", "type": "address" }, - { "internalType": "address", "name": "_vbnb", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetReleased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IProtocolShareReserve.IncomeType", - "name": "incomeType", - "type": "uint8" - }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "AssetsReservesUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } - ], - "name": "PoolRegistryUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "ReservesUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "CORE_POOL_COMPTROLLER", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MAX_PERCENT", - "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "internalType": "struct ProtocolShareReserve.DistributionConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "addOrUpdateDistributionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } - ], - "name": "assetsReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "distributionTargets", - "outputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "getPercentageDistribution", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "getUnreleasedFunds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address[]", "name": "assets", "type": "address[]" } - ], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "name": "removeDistributionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], - "name": "setPoolRegistry", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAssetReserve", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalDistributions", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/RewardDistributor.json b/simulations/vip-373/abi/RewardDistributor.json deleted file mode 100644 index 249fdd111..000000000 --- a/simulations/vip-373/abi/RewardDistributor.json +++ /dev/null @@ -1,532 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "BorrowLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "BorrowLastRewardingBlockUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "ContributorRewardTokenSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } - ], - "name": "ContributorRewardsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } - ], - "name": "DistributedBorrowerRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } - ], - "name": "DistributedSupplierRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "MarketInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "indexed": false, - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "RewardTokenBorrowIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenBorrowSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RewardTokenGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "RewardTokenSupplyIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenSupplySpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "SupplyLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "SupplyLastRewardingBlockUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "INITIAL_INDEX", - "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "holder", "type": "address" }, - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } - ], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "distributeBorrowerRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "supplier", "type": "address" } - ], - "name": "distributeSupplierRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "recipient", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "grantRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, - { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "initializeMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastContributorBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "rewardToken", - "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenBorrowerIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenContributorSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenSupplierIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplySpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contributor", "type": "address" }, - { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } - ], - "name": "setContributorRewardTokenSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } - ], - "name": "setLastRewardingBlockTimestamps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, - { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } - ], - "name": "setLastRewardingBlocks", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } - ], - "name": "setRewardTokenSpeeds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], - "name": "updateContributorRewards", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "updateRewardTokenBorrowIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "updateRewardTokenSupplyIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/SingleTokenConverter.json b/simulations/vip-373/abi/SingleTokenConverter.json deleted file mode 100644 index 8ea10cc8d..000000000 --- a/simulations/vip-373/abi/SingleTokenConverter.json +++ /dev/null @@ -1,587 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } - ], - "name": "AmountInHigherThanMax", - "type": "error" - }, - { "inputs": [], "name": "AmountInMismatched", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } - ], - "name": "AmountOutLowerThanMinRequired", - "type": "error" - }, - { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, - { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, - { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, - { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, - { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, - { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } - ], - "name": "IncentiveTooHigh", - "type": "error" - }, - { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, - { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, - { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, - { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, - { "inputs": [], "name": "InvalidToAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, - { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetTransferredToDestination", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } - ], - "name": "BaseAssetUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "oldAccess", - "type": "uint8" - }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "newAccess", - "type": "uint8" - } - ], - "name": "ConversionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } - ], - "name": "ConverterNetworkAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } - ], - "name": "DestinationAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } - ], - "name": "MinAmountToConvertUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, - { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } - ], - "name": "PriceOracleUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "inputs": [], - "name": "MAX_INCENTIVE", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "baseAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "conversionConfigurations", - "outputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "conversionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "converterNetwork", - "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "destinationAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, - { "internalType": "address", "name": "destinationAddress_", "type": "address" }, - { "internalType": "address", "name": "baseAsset_", "type": "address" }, - { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "minAmountToConvert", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "priceOracle", - "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], - "name": "setBaseAsset", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig", - "name": "conversionConfig", - "type": "tuple" - } - ], - "name": "setConversionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", - "name": "conversionConfigs", - "type": "tuple[]" - } - ], - "name": "setConversionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], - "name": "setConverterNetwork", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], - "name": "setDestination", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], - "name": "setMinAmountToConvert", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/SingleTokenConverterBeacon.json b/simulations/vip-373/abi/SingleTokenConverterBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/simulations/vip-373/abi/SingleTokenConverterBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/VToken.json b/simulations/vip-373/abi/VToken.json deleted file mode 100644 index d8cc1aae4..000000000 --- a/simulations/vip-373/abi/VToken.json +++ /dev/null @@ -1,861 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], - "name": "AddReservesFactorFreshCheck", - "type": "error" - }, - { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, - { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, - { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], - "name": "LiquidateAccrueCollateralInterestFailed", - "type": "error" - }, - { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, - { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, - { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, - { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, - { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, - { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, - { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "AccrueInterest", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtRecovered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "Borrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "HealBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "LiquidateBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } - ], - "name": "NewComptroller", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "oldInterestRateModel", - "type": "address" - }, - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "newInterestRateModel", - "type": "address" - } - ], - "name": "NewMarketInterestRateModel", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } - ], - "name": "NewProtocolSeizeShare", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } - ], - "name": "NewProtocolShareReserve", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } - ], - "name": "NewReduceReservesBlockDelta", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } - ], - "name": "NewReserveFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } - ], - "name": "NewShortfallContract", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ProtocolSeize", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Redeem", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "RepayBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "ReservesAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "SpreadReservesReduced", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Transfer", - "type": "event" - }, - { - "inputs": [], - "name": "NO_ERROR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrualBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrueInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], - "name": "addReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "owner", "type": "address" }, - { "internalType": "address", "name": "spender", "type": "address" } - ], - "name": "allowance", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "approve", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "badDebt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], - "name": "badDebtRecovered", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOfUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], - "name": "borrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "borrowIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "borrowRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } - ], - "name": "decreaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "forceLiquidateBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountSnapshot", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCash", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "healBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "addedValue", "type": "uint256" } - ], - "name": "increaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "underlying_", "type": "address" }, - { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, - { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, - { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, - { "internalType": "string", "name": "name_", "type": "string" }, - { "internalType": "string", "name": "symbol_", "type": "string" }, - { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, - { "internalType": "address", "name": "admin_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { - "components": [ - { "internalType": "address", "name": "shortfall", "type": "address" }, - { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } - ], - "internalType": "struct VTokenInterface.RiskManagementInit", - "name": "riskManagement", - "type": "tuple" - }, - { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "interestRateModel", - "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isVToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } - ], - "name": "liquidateBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], - "name": "mint", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "mintBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolSeizeShareMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolShareReserve", - "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], - "name": "redeem", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], - "name": "redeemUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } - ], - "name": "redeemUnderlyingBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], - "name": "reduceReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockDelta", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], - "name": "repayBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "repayBorrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reserveFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], - "name": "setInterestRateModel", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], - "name": "setProtocolSeizeShare", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], - "name": "setProtocolShareReserve", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], - "name": "setReduceReservesBlockDelta", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], - "name": "setReserveFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], - "name": "setShortfallContract", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "shortfall", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "supplyRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrows", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrowsCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "totalReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transfer", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transferFrom", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "underlying", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/VTokenBeacon.json b/simulations/vip-373/abi/VTokenBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/simulations/vip-373/abi/VTokenBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/XVSStore.json b/simulations/vip-373/abi/XVSStore.json deleted file mode 100644 index 2d9ea2bb2..000000000 --- a/simulations/vip-373/abi/XVSStore.json +++ /dev/null @@ -1,130 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "AdminTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } - ], - "name": "NewPendingAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnerTransferred", - "type": "event" - }, - { - "constant": false, - "inputs": [], - "name": "acceptAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "emergencyRewardWithdraw", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokens", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "token", "type": "address" }, - { "internalType": "address", "name": "_to", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "safeRewardTransfer", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], - "name": "setNewOwner", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], - "name": "setPendingAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "bool", "name": "status", "type": "bool" } - ], - "name": "setRewardToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/XVSVault.json b/simulations/vip-373/abi/XVSVault.json deleted file mode 100644 index 51d8d540c..000000000 --- a/simulations/vip-373/abi/XVSVault.json +++ /dev/null @@ -1,787 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Claim", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } - ], - "name": "DelegateChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "DelegateVotesChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Deposit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ExecutedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "name": "PoolAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } - ], - "name": "PoolUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RequestedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } - ], - "name": "RewardAmountUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } - ], - "name": "StoreUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } - ], - "name": "VaultDebtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } - ], - "name": "WithdrawalLockingPeriodUpdated", - "type": "event" - }, - { - "constant": true, - "inputs": [], - "name": "DELEGATION_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "DOMAIN_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "MAX_LOCK_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "SECONDS_PER_YEAR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], - "name": "_become", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, - { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, - { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } - ], - "name": "add", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint32", "name": "", "type": "uint32" } - ], - "name": "checkpoints", - "outputs": [ - { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, - { "internalType": "uint96", "name": "votes", "type": "uint96" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_account", "type": "address" }, - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "claim", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], - "name": "delegate", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "delegatee", "type": "address" }, - { "internalType": "uint256", "name": "nonce", "type": "uint256" }, - { "internalType": "uint256", "name": "expiry", "type": "uint256" }, - { "internalType": "uint8", "name": "v", "type": "uint8" }, - { "internalType": "bytes32", "name": "r", "type": "bytes32" }, - { "internalType": "bytes32", "name": "s", "type": "bytes32" } - ], - "name": "delegateBySig", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "delegates", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "deposit", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "executeWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getCurrentVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getEligibleWithdrawalAmount", - "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } - ], - "name": "getPriorVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getRequestedAmount", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getUserInfo", - "outputs": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, - { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getWithdrawalRequests", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, - { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } - ], - "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", - "name": "", - "type": "tuple[]" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "name": "initializeTimeManager", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isStakedToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "nonces", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "numCheckpoints", - "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "pause", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingReward", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "pendingRewardTransfers", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingWithdrawalsBeforeUpgrade", - "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingXVSVaultImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "poolInfos", - "outputs": [ - { "internalType": "contract IBEP20", "name": "token", "type": "address" }, - { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, - { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], - "name": "poolLength", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primePoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeToken", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "requestWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "resume", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], - "name": "rewardTokenAmountsPerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAmountsPerBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } - ], - "name": "set", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], - "name": "setAccessControl", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, - { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } - ], - "name": "setPrimeToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } - ], - "name": "setRewardAmountPerBlockOrSecond", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } - ], - "name": "setWithdrawalLockingPeriod", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_xvs", "type": "address" }, - { "internalType": "address", "name": "_xvsStore", "type": "address" } - ], - "name": "setXvsStore", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAllocPoints", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "totalPendingWithdrawals", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "updatePool", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "vaultPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsStore", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/XVSVaultProxy.json b/simulations/vip-373/abi/XVSVaultProxy.json deleted file mode 100644 index 070a7fa56..000000000 --- a/simulations/vip-373/abi/XVSVaultProxy.json +++ /dev/null @@ -1,122 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "error", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "info", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "detail", "type": "uint256" } - ], - "name": "Failure", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAdmin", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "NewAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldImplementation", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newImplementation", "type": "address" } - ], - "name": "NewImplementation", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } - ], - "name": "NewPendingAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldPendingImplementation", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPendingImplementation", "type": "address" } - ], - "name": "NewPendingImplementation", - "type": "event" - }, - { "payable": true, "stateMutability": "payable", "type": "fallback" }, - { - "constant": false, - "inputs": [], - "name": "_acceptAdmin", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "_acceptImplementation", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "newPendingAdmin", "type": "address" }], - "name": "_setPendingAdmin", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "newPendingImplementation", "type": "address" }], - "name": "_setPendingImplementation", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingXVSVaultImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/binanceOracle.json b/simulations/vip-373/abi/binanceOracle.json deleted file mode 100644 index 513793a74..000000000 --- a/simulations/vip-373/abi/binanceOracle.json +++ /dev/null @@ -1,284 +0,0 @@ -[ - { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, - { - "name": "Unauthorized", - "type": "error", - "inputs": [ - { "name": "sender", "type": "address", "internalType": "address" }, - { "name": "calledContract", "type": "address", "internalType": "address" }, - { "name": "methodSignature", "type": "string", "internalType": "string" } - ] - }, - { - "name": "FeedRegistryUpdated", - "type": "event", - "inputs": [ - { "name": "oldFeedRegistry", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newFeedRegistry", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x6d1006252b3dd171af76c28c184327bfddc39f439a50e0ac7f418c660b8894b5" - }, - { - "name": "Initialized", - "type": "event", - "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], - "anonymous": false, - "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" - }, - { - "name": "MaxStalePeriodAdded", - "type": "event", - "inputs": [ - { "name": "asset", "type": "string", "indexed": true, "internalType": "string" }, - { "name": "maxStalePeriod", "type": "uint256", "indexed": false, "internalType": "uint256" } - ], - "anonymous": false, - "signature": "0x37839d4a80c5e3f2578f59515c911ee8cce42383d7ebaa1c92afcde9871c4b58" - }, - { - "name": "NewAccessControlManager", - "type": "event", - "inputs": [ - { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, - { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" - }, - { - "name": "OwnershipTransferStarted", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" - }, - { - "name": "OwnershipTransferred", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" - }, - { - "name": "SymbolOverridden", - "type": "event", - "inputs": [ - { "name": "symbol", "type": "string", "indexed": true, "internalType": "string" }, - { "name": "overriddenSymbol", "type": "string", "indexed": false, "internalType": "string" } - ], - "anonymous": false, - "signature": "0xceb1f47aa91b96f02ea70e1deed25fe154ad1885aea509bd7222f9eec0a0bda5" - }, - { - "name": "BNB_ADDR", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x3e83b6b8", - "stateMutability": "view" - }, - { - "name": "acceptOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x79ba5097", - "stateMutability": "nonpayable" - }, - { - "name": "accessControlManager", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "contract IAccessControlManagerV8" - } - ], - "constant": true, - "signature": "0xb4a0bdf3", - "stateMutability": "view" - }, - { - "name": "feedRegistryAddress", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x011d3962", - "stateMutability": "view" - }, - { - "name": "getFeedRegistryAddress", - "type": "function", - "inputs": [], - "outputs": [{ "name": "", "type": "address", "internalType": "address" }], - "constant": true, - "signature": "0x99fe040e", - "stateMutability": "view" - }, - { - "name": "getPrice", - "type": "function", - "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], - "outputs": [{ "name": "", "type": "uint256", "internalType": "uint256" }], - "constant": true, - "signature": "0x41976e09", - "stateMutability": "view" - }, - { - "name": "initialize", - "type": "function", - "inputs": [ - { "name": "_sidRegistryAddress", "type": "address", "internalType": "address" }, - { "name": "_accessControlManager", "type": "address", "internalType": "address" } - ], - "outputs": [], - "signature": "0x485cc955", - "stateMutability": "nonpayable" - }, - { - "name": "maxStalePeriod", - "type": "function", - "inputs": [{ "name": "", "type": "string", "internalType": "string" }], - "outputs": [{ "name": "", "type": "uint256", "internalType": "uint256" }], - "constant": true, - "signature": "0xfdfbc277", - "stateMutability": "view" - }, - { - "name": "owner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x8da5cb5b", - "stateMutability": "view" - }, - { - "name": "pendingOwner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0xe30c3978", - "stateMutability": "view" - }, - { - "name": "renounceOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x715018a6", - "stateMutability": "nonpayable" - }, - { - "name": "setAccessControlManager", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0x0e32cb86", - "stateMutability": "nonpayable" - }, - { - "name": "setFeedRegistryAddress", - "type": "function", - "inputs": [{ "name": "newfeedRegistryAddress", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0x255ce37a", - "stateMutability": "nonpayable" - }, - { - "name": "setMaxStalePeriod", - "type": "function", - "inputs": [ - { "name": "symbol", "type": "string", "internalType": "string" }, - { "name": "_maxStalePeriod", "type": "uint256", "internalType": "uint256" } - ], - "outputs": [], - "signature": "0x636b999a", - "stateMutability": "nonpayable" - }, - { - "name": "setSymbolOverride", - "type": "function", - "inputs": [ - { "name": "symbol", "type": "string", "internalType": "string" }, - { "name": "overrideSymbol", "type": "string", "internalType": "string" } - ], - "outputs": [], - "signature": "0x9eab1ad6", - "stateMutability": "nonpayable" - }, - { - "name": "sidRegistryAddress", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x475e7de5", - "stateMutability": "view" - }, - { - "name": "symbols", - "type": "function", - "inputs": [{ "name": "", "type": "string", "internalType": "string" }], - "outputs": [{ "name": "", "type": "string", "internalType": "string" }], - "constant": true, - "signature": "0x047a74b2", - "stateMutability": "view" - }, - { - "name": "transferOwnership", - "type": "function", - "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xf2fde38b", - "stateMutability": "nonpayable" - } -] diff --git a/simulations/vip-373/abi/boundValidator.json b/simulations/vip-373/abi/boundValidator.json deleted file mode 100644 index d16c8fb08..000000000 --- a/simulations/vip-373/abi/boundValidator.json +++ /dev/null @@ -1,498 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "previousAdmin", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAdmin", - "type": "address" - } - ], - "name": "AdminChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "beacon", - "type": "address" - } - ], - "name": "BeaconUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "implementation", - "type": "address" - } - ], - "name": "Upgraded", - "type": "event" - }, - { - "stateMutability": "payable", - "type": "fallback" - }, - { - "inputs": [], - "name": "admin", - "outputs": [ - { - "internalType": "address", - "name": "admin_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [ - { - "internalType": "address", - "name": "implementation_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - } - ], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - }, - { - "internalType": "bytes", - "name": "data", - "type": "bytes" - } - ], - "name": "upgradeToAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "upperBound", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "lowerBound", - "type": "uint256" - } - ], - "name": "ValidateConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig", - "name": "config", - "type": "tuple" - } - ], - "name": "setValidateConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "setValidateConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "validateConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "reportedPrice", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "anchorPrice", - "type": "uint256" - } - ], - "name": "validatePriceWithAnchorPrice", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_logic", - "type": "address" - }, - { - "internalType": "address", - "name": "admin_", - "type": "address" - }, - { - "internalType": "bytes", - "name": "_data", - "type": "bytes" - } - ], - "stateMutability": "payable", - "type": "constructor" - } -] diff --git a/simulations/vip-373/abi/chainlinkOracle.json b/simulations/vip-373/abi/chainlinkOracle.json deleted file mode 100644 index cdd689acb..000000000 --- a/simulations/vip-373/abi/chainlinkOracle.json +++ /dev/null @@ -1,459 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "vBnbAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "previousPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "requestedPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newPriceMantissa", - "type": "uint256" - } - ], - "name": "PricePosted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManager", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "prices", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - } - ], - "name": "setDirectPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VBep20Interface", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "underlyingPriceMantissa", - "type": "uint256" - } - ], - "name": "setUnderlyingPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "tokenConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/resilientOracle.json b/simulations/vip-373/abi/resilientOracle.json deleted file mode 100644 index 35f52caa0..000000000 --- a/simulations/vip-373/abi/resilientOracle.json +++ /dev/null @@ -1,640 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "nativeMarketAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - }, - { - "internalType": "contract BoundValidatorInterface", - "name": "_boundValidator", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "OracleEnabled", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - } - ], - "name": "OracleSet", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "mainOracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "pivotOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "fallbackOracle", - "type": "address" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "INVALID_PRICE", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_TOKEN_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "boundValidator", - "outputs": [ - { - "internalType": "contract BoundValidatorInterface", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - }, - { - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "enableOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "getOracle", - "outputs": [ - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "bool", - "name": "enabled", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getTokenConfig", - "outputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "nativeMarket", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "setOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "updateAssetPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "updatePrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/sFrxETHOracle.json b/simulations/vip-373/abi/sFrxETHOracle.json deleted file mode 100644 index b461549ba..000000000 --- a/simulations/vip-373/abi/sFrxETHOracle.json +++ /dev/null @@ -1,148 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_sfrxEthFraxOracle", "type": "address" }, - { "internalType": "address", "name": "_sfrxETH", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "BadPriceData", "type": "error" }, - { "inputs": [], "name": "InvalidTokenAddress", "type": "error" }, - { "inputs": [], "name": "PriceDifferenceExceeded", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxAllowedPriceDifference", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxAllowedPriceDifference", "type": "uint256" } - ], - "name": "MaxAllowedPriceDifferenceUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [], - "name": "SFRXETH", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "SFRXETH_FRAX_ORACLE", - "outputs": [{ "internalType": "contract ISfrxEthFraxOracle", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], - "name": "getPrice", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxAllowedPriceDifference", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" }], - "name": "setMaxAllowedPriceDifference", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/treasury.json b/simulations/vip-373/abi/treasury.json deleted file mode 100644 index 18aabb61a..000000000 --- a/simulations/vip-373/abi/treasury.json +++ /dev/null @@ -1,86 +0,0 @@ -[ - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryNative", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryToken", - "type": "event" - }, - { "stateMutability": "payable", "type": "fallback" }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryNative", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "stateMutability": "payable", "type": "receive" } -] diff --git a/simulations/vip-373/abi/xvs.json b/simulations/vip-373/abi/xvs.json deleted file mode 100644 index 69092bb4a..000000000 --- a/simulations/vip-373/abi/xvs.json +++ /dev/null @@ -1,716 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user", - "type": "address" - } - ], - "name": "AccountBlacklisted", - "type": "error" - }, - { - "inputs": [], - "name": "AddressesMustDiffer", - "type": "error" - }, - { - "inputs": [], - "name": "MintLimitExceed", - "type": "error" - }, - { - "inputs": [], - "name": "MintedAmountExceed", - "type": "error" - }, - { - "inputs": [], - "name": "NewCapNotGreaterThanMintedTokens", - "type": "error" - }, - { - "inputs": [], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "user", - "type": "address" - }, - { - "indexed": false, - "internalType": "bool", - "name": "value", - "type": "bool" - } - ], - "name": "BlacklistUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "MintCapChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitDecreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "source", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "destination", - "type": "address" - } - ], - "name": "MintedTokensMigrated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Transfer", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "internalType": "address", - "name": "spender", - "type": "address" - } - ], - "name": "allowance", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "approve", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [ - { - "internalType": "uint8", - "name": "", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "subtractedValue", - "type": "uint256" - } - ], - "name": "decreaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "addedValue", - "type": "uint256" - } - ], - "name": "increaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - } - ], - "name": "isBlackListed", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "source_", - "type": "address" - }, - { - "internalType": "address", - "name": "destination_", - "type": "address" - } - ], - "name": "migrateMinterTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "mint", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToCap", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToMintedAmount", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newAccessControlAddress_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "minter_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "setMintCap", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transfer", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transferFrom", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - }, - { - "internalType": "bool", - "name": "value_", - "type": "bool" - } - ], - "name": "updateBlacklist", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/xvsBridge.json b/simulations/vip-373/abi/xvsBridge.json deleted file mode 100644 index 4e4dc5152..000000000 --- a/simulations/vip-373/abi/xvsBridge.json +++ /dev/null @@ -1,807 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress_", "type": "address" }, - { "internalType": "uint8", "name": "sharedDecimals_", "type": "uint8" }, - { "internalType": "address", "name": "lzEndpoint_", "type": "address" }, - { "internalType": "address", "name": "oracle_", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "balance", "type": "uint256" } - ], - "name": "InsufficientBalance", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "indexed": false, "internalType": "bytes32", "name": "_hash", "type": "bytes32" } - ], - "name": "CallOFTReceivedSuccess", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "srcChainId", "type": "uint16" }, - { "indexed": true, "internalType": "bytes", "name": "srcAddress", "type": "bytes" }, - { "indexed": false, "internalType": "uint64", "name": "nonce", "type": "uint64" } - ], - "name": "DropFailedMessage", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "innerToken", "type": "address" }], - "name": "InnerTokenAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "indexed": false, "internalType": "bytes", "name": "_payload", "type": "bytes" }, - { "indexed": false, "internalType": "bytes", "name": "_reason", "type": "bytes" } - ], - "name": "MessageFailed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "_address", "type": "address" }], - "name": "NonContractAddress", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldOracle", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOracle", "type": "address" } - ], - "name": "OracleChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "indexed": true, "internalType": "address", "name": "_to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "ReceiveFromChain", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "indexed": false, "internalType": "bytes32", "name": "_payloadHash", "type": "bytes32" } - ], - "name": "RetryMessageSuccess", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "indexed": true, "internalType": "address", "name": "_from", "type": "address" }, - { "indexed": true, "internalType": "bytes32", "name": "_toAddress", "type": "bytes32" }, - { "indexed": false, "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "SendToChain", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } - ], - "name": "SetMaxDailyLimit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } - ], - "name": "SetMaxDailyReceiveLimit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } - ], - "name": "SetMaxSingleReceiveTransactionLimit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } - ], - "name": "SetMaxSingleTransactionLimit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint16", "name": "_type", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "_minDstGas", "type": "uint256" } - ], - "name": "SetMinDstGas", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "precrime", "type": "address" }], - "name": "SetPrecrime", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_path", "type": "bytes" } - ], - "name": "SetTrustedRemote", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } - ], - "name": "SetTrustedRemoteAddress", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "addr", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "isWhitelist", "type": "bool" } - ], - "name": "SetWhitelist", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }], - "name": "TrustedRemoteRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "bool", "name": "enabled", "type": "bool" }], - "name": "UpdateSendAndCallEnabled", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_PAYLOAD_SIZE_LIMIT", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NO_EXTRA_GAS", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "PT_SEND", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "PT_SEND_AND_CALL", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "internalType": "bytes32", "name": "_from", "type": "bytes32" }, - { "internalType": "address", "name": "_to", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" }, - { "internalType": "bytes", "name": "_payload", "type": "bytes" }, - { "internalType": "uint256", "name": "_gasForCall", "type": "uint256" } - ], - "name": "callOnOFTReceived", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourReceiveWindowStart", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourReceived", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourTransferred", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourWindowStart", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToMaxDailyLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToMaxDailyReceiveLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToMaxSingleReceiveTransactionLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToMaxSingleTransactionLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "circulatingSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "", "type": "uint16" }, - { "internalType": "bytes", "name": "", "type": "bytes" }, - { "internalType": "uint64", "name": "", "type": "uint64" } - ], - "name": "creditedPackets", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "srcAddress_", "type": "bytes" }, - { "internalType": "uint64", "name": "nonce_", "type": "uint64" } - ], - "name": "dropFailedMessage", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "internalType": "bytes32", "name": "_toAddress", "type": "bytes32" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" }, - { "internalType": "bytes", "name": "_payload", "type": "bytes" }, - { "internalType": "uint64", "name": "_dstGasForCall", "type": "uint64" }, - { "internalType": "bool", "name": "_useZro", "type": "bool" }, - { "internalType": "bytes", "name": "_adapterParams", "type": "bytes" } - ], - "name": "estimateSendAndCallFee", - "outputs": [ - { "internalType": "uint256", "name": "nativeFee", "type": "uint256" }, - { "internalType": "uint256", "name": "zroFee", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "internalType": "bytes32", "name": "_toAddress", "type": "bytes32" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" }, - { "internalType": "bool", "name": "_useZro", "type": "bool" }, - { "internalType": "bytes", "name": "_adapterParams", "type": "bytes" } - ], - "name": "estimateSendFee", - "outputs": [ - { "internalType": "uint256", "name": "nativeFee", "type": "uint256" }, - { "internalType": "uint256", "name": "zroFee", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "", "type": "uint16" }, - { "internalType": "bytes", "name": "", "type": "bytes" }, - { "internalType": "uint64", "name": "", "type": "uint64" } - ], - "name": "failedMessages", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } - ], - "name": "forceResumeReceive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_version", "type": "uint16" }, - { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "_configType", "type": "uint256" } - ], - "name": "getConfig", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }], - "name": "getTrustedRemoteAddress", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "from_", "type": "address" }, - { "internalType": "uint16", "name": "dstChainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "amount_", "type": "uint256" } - ], - "name": "isEligibleToSend", - "outputs": [ - { "internalType": "bool", "name": "eligibleToSend", "type": "bool" }, - { "internalType": "uint256", "name": "maxSingleTransactionLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "maxDailyLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInUsd", "type": "uint256" }, - { "internalType": "uint256", "name": "transferredInWindow", "type": "uint256" }, - { "internalType": "uint256", "name": "last24HourWindowStart", "type": "uint256" }, - { "internalType": "bool", "name": "isWhiteListedUser", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } - ], - "name": "isTrustedRemote", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "lzEndpoint", - "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "internalType": "bytes", "name": "_payload", "type": "bytes" } - ], - "name": "lzReceive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "", "type": "uint16" }, - { "internalType": "uint16", "name": "", "type": "uint16" } - ], - "name": "minDstGasLookup", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "internalType": "bytes", "name": "_payload", "type": "bytes" } - ], - "name": "nonblockingLzReceive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "payloadSizeLimitLookup", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "precrime", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], - "name": "removeTrustedRemote", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "internalType": "bytes", "name": "_payload", "type": "bytes" } - ], - "name": "retryMessage", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "from_", "type": "address" }, - { "internalType": "uint16", "name": "dstChainId_", "type": "uint16" }, - { "internalType": "bytes32", "name": "toAddress_", "type": "bytes32" }, - { "internalType": "uint256", "name": "amount_", "type": "uint256" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "uint64", "name": "dstGasForCall_", "type": "uint64" }, - { - "components": [ - { "internalType": "address payable", "name": "refundAddress", "type": "address" }, - { "internalType": "address", "name": "zroPaymentAddress", "type": "address" }, - { "internalType": "bytes", "name": "adapterParams", "type": "bytes" } - ], - "internalType": "struct ICommonOFT.LzCallParams", - "name": "callparams_", - "type": "tuple" - } - ], - "name": "sendAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [], - "name": "sendAndCallEnabled", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_from", "type": "address" }, - { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "internalType": "bytes32", "name": "_toAddress", "type": "bytes32" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" }, - { - "components": [ - { "internalType": "address payable", "name": "refundAddress", "type": "address" }, - { "internalType": "address", "name": "zroPaymentAddress", "type": "address" }, - { "internalType": "bytes", "name": "adapterParams", "type": "bytes" } - ], - "internalType": "struct ICommonOFT.LzCallParams", - "name": "_callParams", - "type": "tuple" - } - ], - "name": "sendFrom", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_version", "type": "uint16" }, - { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, - { "internalType": "uint256", "name": "_configType", "type": "uint256" }, - { "internalType": "bytes", "name": "_config", "type": "bytes" } - ], - "name": "setConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "limit_", "type": "uint256" } - ], - "name": "setMaxDailyLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "limit_", "type": "uint256" } - ], - "name": "setMaxDailyReceiveLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "limit_", "type": "uint256" } - ], - "name": "setMaxSingleReceiveTransactionLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "limit_", "type": "uint256" } - ], - "name": "setMaxSingleTransactionLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "internalType": "uint16", "name": "_packetType", "type": "uint16" }, - { "internalType": "uint256", "name": "_minGas", "type": "uint256" } - ], - "name": "setMinDstGas", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "oracleAddress_", "type": "address" }], - "name": "setOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "internalType": "uint256", "name": "_size", "type": "uint256" } - ], - "name": "setPayloadSizeLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_precrime", "type": "address" }], - "name": "setPrecrime", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], - "name": "setReceiveVersion", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], - "name": "setSendVersion", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_path", "type": "bytes" } - ], - "name": "setTrustedRemote", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "user_", "type": "address" }, - { "internalType": "bool", "name": "val_", "type": "bool" } - ], - "name": "setWhitelist", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "sharedDecimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], - "name": "supportsInterface", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract IERC20", "name": "token_", "type": "address" }, - { "internalType": "address", "name": "to_", "type": "address" }, - { "internalType": "uint256", "name": "amount_", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "token", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "trustedRemoteLookup", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "bool", "name": "enabled_", "type": "bool" }], - "name": "updateSendAndCallEnabled", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "whitelist", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-373/abi/xvsBridgeAdmin.json b/simulations/vip-373/abi/xvsBridgeAdmin.json deleted file mode 100644 index 024450a40..000000000 --- a/simulations/vip-373/abi/xvsBridgeAdmin.json +++ /dev/null @@ -1,329 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "XVSBridge_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "string", - "name": "signature", - "type": "string" - }, - { - "indexed": false, - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "name": "FunctionRegistryChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "stateMutability": "nonpayable", - "type": "fallback" - }, - { - "inputs": [], - "name": "XVSBridge", - "outputs": [ - { - "internalType": "contract IXVSProxyOFT", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes4", - "name": "", - "type": "bytes4" - } - ], - "name": "functionRegistry", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "isTrustedRemote", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner_", - "type": "address" - } - ], - "name": "transferBridgeOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "string[]", - "name": "signatures_", - "type": "string[]" - }, - { - "internalType": "bool[]", - "name": "active_", - "type": "bool[]" - } - ], - "name": "upsertSignature", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-373/arbitrumone.ts b/simulations/vip-373/arbitrumone.ts deleted file mode 100644 index a7863c1b3..000000000 --- a/simulations/vip-373/arbitrumone.ts +++ /dev/null @@ -1,58 +0,0 @@ -import { expect } from "chai"; -import { Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; - -import vip014 from "../../multisig/proposals/arbitrumone/vip-014"; -import vip373, { ARBITRUM_ONE_BOUND_VALIDATOR, ARBITRUM_XVS_BRIDGE_ADMIN } from "../../vips/vip-373/bscmainnet"; -import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; -import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; -import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; -import TREASURY_ABI from "./abi/treasury.json"; -import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; -import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; - -const XVS_BRIDGE = "0x20cEa49B5F7a6DBD78cAE772CA5973eF360AA1e6"; -const { arbitrumone } = NETWORK_ADDRESSES; - -forking(230362555, async () => { - const provider = ethers.provider; - let chainLinkOracle: Contract; - let redstoneOracle: Contract; - let resilientOracle: Contract; - let boundValidator: Contract; - let treasury: Contract; - let xvsBridgeAdmin: Contract; - let xvsBridge: Contract; - before(async () => { - chainLinkOracle = new ethers.Contract(arbitrumone.CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); - redstoneOracle = new ethers.Contract(arbitrumone.REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); - resilientOracle = new ethers.Contract(arbitrumone.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); - boundValidator = new ethers.Contract(ARBITRUM_ONE_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); - treasury = await ethers.getContractAt(TREASURY_ABI, arbitrumone.VTREASURY); - xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, ARBITRUM_XVS_BRIDGE_ADMIN); - xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); - await pretendExecutingVip(await vip014()); - }); - - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip373()); - - describe("Post-VIP behaviour", async () => { - it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { - expect(await xvsBridgeAdmin.owner()).to.be.equals(arbitrumone.NORMAL_TIMELOCK); - }); - it("Normal Timelock should be whitelisted", async () => { - expect(await xvsBridge.whitelist(arbitrumone.NORMAL_TIMELOCK)).to.be.true; - }); - it("oracles should have correct owner", async () => { - expect(await resilientOracle.owner()).equals(arbitrumone.NORMAL_TIMELOCK); - expect(await chainLinkOracle.owner()).equals(arbitrumone.NORMAL_TIMELOCK); - expect(await redstoneOracle.owner()).equals(arbitrumone.NORMAL_TIMELOCK); - expect(await boundValidator.owner()).equals(arbitrumone.NORMAL_TIMELOCK); - }); - it("Normal Timelock should be the owner of the Vtreasury", async () => { - expect(await treasury.owner()).equals(arbitrumone.NORMAL_TIMELOCK); - }); - }); -}); diff --git a/simulations/vip-373/arbitrumsepolia.ts b/simulations/vip-373/arbitrumsepolia.ts deleted file mode 100644 index ebb9a0b1f..000000000 --- a/simulations/vip-373/arbitrumsepolia.ts +++ /dev/null @@ -1,62 +0,0 @@ -import { expect } from "chai"; -import { Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; - -import vip014 from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import vip373, { - ARBITRUM_SEPOLIA_BOUND_VALIDATOR, - ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN, -} from "../../vips/vip-373/bsctestnet"; -import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; -import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; -import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; -import TREASURY_ABI from "./abi/treasury.json"; -import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; -import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; - -const XVS_BRIDGE = "0xFdC5cEC63FD167DA46cF006585b30D03B104eFD4"; -const { arbitrumsepolia } = NETWORK_ADDRESSES; - -forking(87457288, async () => { - const provider = ethers.provider; - let chainLinkOracle: Contract; - let redstoneOracle: Contract; - let resilientOracle: Contract; - let boundValidator: Contract; - let xvsBridgeAdmin: Contract; - let xvsBridge: Contract; - let treasury: Contract; - before(async () => { - chainLinkOracle = new ethers.Contract(arbitrumsepolia.CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); - redstoneOracle = new ethers.Contract(arbitrumsepolia.REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); - resilientOracle = new ethers.Contract(arbitrumsepolia.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); - boundValidator = new ethers.Contract(ARBITRUM_SEPOLIA_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); - xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN); - xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); - treasury = await ethers.getContractAt(TREASURY_ABI, arbitrumsepolia.VTREASURY); - - await pretendExecutingVip(await vip014()); - }); - - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip373()); - - describe("Post-VIP behaviour", async () => { - it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { - expect(await xvsBridgeAdmin.owner()).to.be.equals(arbitrumsepolia.NORMAL_TIMELOCK); - }); - it("Normal Timelock should be whitelisted", async () => { - expect(await xvsBridge.whitelist(arbitrumsepolia.NORMAL_TIMELOCK)).to.be.true; - }); - it("oracles should have correct owner", async () => { - expect(await resilientOracle.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); - expect(await chainLinkOracle.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); - expect(await redstoneOracle.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); - expect(await boundValidator.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); - }); - it("Normal Timelock should be the owner of the Vtreasury", async () => { - expect(await treasury.owner()).equals(arbitrumsepolia.NORMAL_TIMELOCK); - }); - }); -}); diff --git a/simulations/vip-373/bscmainnet.ts b/simulations/vip-373/bscmainnet.ts deleted file mode 100644 index 3f63215f1..000000000 --- a/simulations/vip-373/bscmainnet.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { expectEvents } from "../../src/utils"; -import { forking, testVip } from "../../src/vip-framework"; -import vip373 from "../../vips/vip-373/bscmainnet"; -import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; - -forking(40343666, async () => { - testVip("vip373 XVS vault permission proposal", await vip373(), { - callbackAfterExecution: async txResponse => { - await expectEvents( - txResponse, - [OMNICHAIN_PROPOSAL_SENDER_ABI], - ["ExecuteRemoteProposal", "StorePayload"], - [3, 0], - ); - }, - }); -}); diff --git a/simulations/vip-373/bsctestnet.ts b/simulations/vip-373/bsctestnet.ts deleted file mode 100644 index bf36f1ba9..000000000 --- a/simulations/vip-373/bsctestnet.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { expectEvents } from "../../src/utils"; -import { forking, testVip } from "../../src/vip-framework"; -import vip373 from "../../vips/vip-373/bsctestnet"; -import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; - -forking(41938696, async () => { - testVip("vip373 XVS vault permission proposal", await vip373(), { - callbackAfterExecution: async txResponse => { - await expectEvents( - txResponse, - [OMNICHAIN_PROPOSAL_SENDER_ABI], - ["ExecuteRemoteProposal", "StorePayload"], - [3, 0], - ); - }, - }); -}); diff --git a/simulations/vip-373/ethereum.ts b/simulations/vip-373/ethereum.ts deleted file mode 100644 index 40cff7f0d..000000000 --- a/simulations/vip-373/ethereum.ts +++ /dev/null @@ -1,66 +0,0 @@ -import { expect } from "chai"; -import { Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; - -import vip061 from "../../multisig/proposals/ethereum/vip-061"; -import vip373, { - ETHEREUM_BOUND_VALIDATOR, - ETHEREUM_XVS_BRIDGE_ADMIN, - ETHEREUM_sFrxETH_ORACLE, -} from "../../vips/vip-373/bscmainnet"; -import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; -import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; -import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; -import SFRAXETH_ORACLE_ABI from "./abi/sFrxETHOracle.json"; -import TREASURY_ABI from "./abi/treasury.json"; -import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; -import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; - -const XVS_BRIDGE = "0x888E317606b4c590BBAD88653863e8B345702633"; -const { ethereum } = NETWORK_ADDRESSES; - -forking(20274111, async () => { - const provider = ethers.provider; - let xvsBridgeAdmin: Contract; - let xvsBridge: Contract; - let chainLinkOracle: Contract; - let redstoneOracle: Contract; - let resilientOracle: Contract; - let boundValidator: Contract; - let sfraxETH: Contract; - let treasury: Contract; - before(async () => { - xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, ETHEREUM_XVS_BRIDGE_ADMIN); - xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); - chainLinkOracle = new ethers.Contract(ethereum.CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); - redstoneOracle = new ethers.Contract(ethereum.REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); - resilientOracle = new ethers.Contract(ethereum.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); - boundValidator = new ethers.Contract(ETHEREUM_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); - sfraxETH = new ethers.Contract(ETHEREUM_sFrxETH_ORACLE, SFRAXETH_ORACLE_ABI, provider); - treasury = await ethers.getContractAt(TREASURY_ABI, ethereum.VTREASURY); - await pretendExecutingVip(await vip061()); - }); - - testForkedNetworkVipCommands("vip373", await vip373()); - - describe("Post-VIP behaviour", async () => { - it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { - expect(await xvsBridgeAdmin.owner()).to.be.equals(ethereum.NORMAL_TIMELOCK); - }); - it("Normal Timelock should be whitelisted", async () => { - expect(await xvsBridge.whitelist(ethereum.NORMAL_TIMELOCK)).to.be.true; - }); - it("oracles should have correct owner", async () => { - expect(await resilientOracle.owner()).equals(ethereum.NORMAL_TIMELOCK); - expect(await chainLinkOracle.owner()).equals(ethereum.NORMAL_TIMELOCK); - expect(await redstoneOracle.owner()).equals(ethereum.NORMAL_TIMELOCK); - expect(await boundValidator.owner()).equals(ethereum.NORMAL_TIMELOCK); - expect(await sfraxETH.owner()).equals(ethereum.NORMAL_TIMELOCK); - }); - it("Normal Timelock should be the owner of the Vtreasury", async () => { - expect(await treasury.owner()).equals(ethereum.NORMAL_TIMELOCK); - }); - }); -}); diff --git a/simulations/vip-373/opbnbmainnet.ts b/simulations/vip-373/opbnbmainnet.ts deleted file mode 100644 index 5e9a82acd..000000000 --- a/simulations/vip-373/opbnbmainnet.ts +++ /dev/null @@ -1,58 +0,0 @@ -import { expect } from "chai"; -import { Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; - -import vip021 from "../../multisig/proposals/opbnbmainnet/vip-021"; -import vip373, { OPBNBMAINNET_BOUND_VALIDATOR, OPBNBMAINNET_XVS_BRIDGE_ADMIN } from "../../vips/vip-373/bscmainnet"; -import BINANCE_ORACLE_API from "./abi/binanceOracle.json"; -import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; -import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; -import TREASURY_ABI from "./abi/treasury.json"; -import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; -import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; - -const XVS_BRIDGE = "0x100D331C1B5Dcd41eACB1eCeD0e83DCEbf3498B2"; -const { opbnbmainnet } = NETWORK_ADDRESSES; - -forking(28761242, async () => { - const provider = ethers.provider; - let binanceOracle: Contract; - let resilientOracle: Contract; - let boundValidator: Contract; - let treasury: Contract; - let xvsBridgeAdmin: Contract; - let xvsBridge: Contract; - - before(async () => { - binanceOracle = new ethers.Contract(opbnbmainnet.BINANCE_ORACLE, BINANCE_ORACLE_API, provider); - resilientOracle = new ethers.Contract(opbnbmainnet.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); - boundValidator = new ethers.Contract(OPBNBMAINNET_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); - xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, OPBNBMAINNET_XVS_BRIDGE_ADMIN); - xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); - treasury = await ethers.getContractAt(TREASURY_ABI, opbnbmainnet.VTREASURY); - await pretendExecutingVip(await vip021()); - }); - - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip373()); - - describe("Post-VIP behaviour", async () => { - it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { - expect(await xvsBridgeAdmin.owner()).to.be.equals(opbnbmainnet.NORMAL_TIMELOCK); - }); - it("Normal Timelock should be whitelisted", async () => { - expect(await xvsBridge.whitelist(opbnbmainnet.NORMAL_TIMELOCK)).to.be.true; - }); - - it("oracles should have correct owner", async () => { - expect(await resilientOracle.owner()).equals(opbnbmainnet.NORMAL_TIMELOCK); - expect(await binanceOracle.owner()).equals(opbnbmainnet.NORMAL_TIMELOCK); - expect(await boundValidator.owner()).equals(opbnbmainnet.NORMAL_TIMELOCK); - }); - - it("Normal Timelock should be the owner of the Vtreasury", async () => { - expect(await treasury.owner()).equals(opbnbmainnet.NORMAL_TIMELOCK); - }); - }); -}); diff --git a/simulations/vip-373/opbnbtestnet.ts b/simulations/vip-373/opbnbtestnet.ts deleted file mode 100644 index a2f952530..000000000 --- a/simulations/vip-373/opbnbtestnet.ts +++ /dev/null @@ -1,55 +0,0 @@ -import { expect } from "chai"; -import { Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; - -import vip021 from "../../multisig/proposals/opbnbtestnet/vip-021"; -import vip373, { OPBNBTESTNET_BOUND_VALIDATOR, OPBNBTESTNET_XVS_BRIDGE_ADMIN } from "../../vips/vip-373/bsctestnet"; -import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; -import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; -import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; -import TREASURY_ABI from "./abi/treasury.json"; -import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; -import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; - -const XVS_BRIDGE = "0xA03205bC635A772E533E7BE36b5701E331a70ea3"; -const { opbnbtestnet } = NETWORK_ADDRESSES; - -forking(41684455, async () => { - const provider = ethers.provider; - let binanceOracle: Contract; - let resilientOracle: Contract; - let boundValidator: Contract; - let treasury: Contract; - let xvsBridgeAdmin: Contract; - let xvsBridge: Contract; - before(async () => { - binanceOracle = new ethers.Contract(opbnbtestnet.BINANCE_ORACLE, CHAINLINK_ORACLE_ABI, provider); - resilientOracle = new ethers.Contract(opbnbtestnet.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); - boundValidator = new ethers.Contract(OPBNBTESTNET_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); - xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, OPBNBTESTNET_XVS_BRIDGE_ADMIN); - xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); - treasury = await ethers.getContractAt(TREASURY_ABI, opbnbtestnet.VTREASURY); - await pretendExecutingVip(await vip021()); - }); - - testForkedNetworkVipCommands("vip373", await vip373(), {}); - - describe("Post-VIP behaviour", async () => { - it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { - expect(await xvsBridgeAdmin.owner()).to.be.equals(opbnbtestnet.NORMAL_TIMELOCK); - }); - it("Normal Timelock should be whitelisted", async () => { - expect(await xvsBridge.whitelist(opbnbtestnet.NORMAL_TIMELOCK)).to.be.true; - }); - it("oracles should have correct owner", async () => { - expect(await resilientOracle.owner()).equals(opbnbtestnet.NORMAL_TIMELOCK); - expect(await binanceOracle.owner()).equals(opbnbtestnet.NORMAL_TIMELOCK); - expect(await boundValidator.owner()).equals(opbnbtestnet.NORMAL_TIMELOCK); - }); - it("Normal Timelock should be the owner of the Vtreasury", async () => { - expect(await treasury.owner()).equals(opbnbtestnet.NORMAL_TIMELOCK); - }); - }); -}); diff --git a/simulations/vip-373/sepolia.ts b/simulations/vip-373/sepolia.ts deleted file mode 100644 index 2436b36a9..000000000 --- a/simulations/vip-373/sepolia.ts +++ /dev/null @@ -1,65 +0,0 @@ -import { expect } from "chai"; -import { Contract } from "ethers"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; - -import vip060 from "../../multisig/proposals/sepolia/vip-060"; -import vip373, { - SEPOLIA_BOUND_VALIDATOR, - SEPOLIA_XVS_BRIDGE_ADMIN, - SEPOLIA_sFrxETH_ORACLE, -} from "../../vips/vip-373/bsctestnet"; -import BOUND_VALIDATOR_ABI from "./abi/boundValidator.json"; -import CHAINLINK_ORACLE_ABI from "./abi/chainlinkOracle.json"; -import RESILLIENT_ORACLE_ABI from "./abi/resilientOracle.json"; -import SFRAXETH_ORACLE_ABI from "./abi/sFrxETHOracle.json"; -import XVS_BRIDGE_ABI from "./abi/xvsBridge.json"; -import XVS_BRIDGE_ADMIN_ABI from "./abi/xvsBridgeAdmin.json"; - -const XVS_BRIDGE = "0xc340b7d3406502F43dC11a988E4EC5bbE536E642"; -const { sepolia } = NETWORK_ADDRESSES; - -forking(6850243, async () => { - const provider = ethers.provider; - let chainLinkOracle: Contract; - let redstoneOracle: Contract; - let resilientOracle: Contract; - let boundValidator: Contract; - let sfraxETH: Contract; - - before(async () => { - chainLinkOracle = new ethers.Contract(sepolia.CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); - redstoneOracle = new ethers.Contract(sepolia.REDSTONE_ORACLE, CHAINLINK_ORACLE_ABI, provider); - resilientOracle = new ethers.Contract(sepolia.RESILIENT_ORACLE, RESILLIENT_ORACLE_ABI, provider); - boundValidator = new ethers.Contract(SEPOLIA_BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); - sfraxETH = new ethers.Contract(SEPOLIA_sFrxETH_ORACLE, SFRAXETH_ORACLE_ABI, provider); - - await pretendExecutingVip(await vip060()); - }); - - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip373()); - - describe("Post-VIP behaviour", async () => { - let xvsBridgeAdmin: Contract; - let xvsBridge: Contract; - before(async () => { - xvsBridgeAdmin = await ethers.getContractAt(XVS_BRIDGE_ADMIN_ABI, SEPOLIA_XVS_BRIDGE_ADMIN); - xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); - }); - - it("XVSBridgeAdmin ownership transferred to Normal Timelock", async () => { - expect(await xvsBridgeAdmin.owner()).to.be.equals(sepolia.NORMAL_TIMELOCK); - }); - it("Normal Timelock should be whitelisted", async () => { - expect(await xvsBridge.whitelist(sepolia.NORMAL_TIMELOCK)).to.be.true; - }); - it("oracles should have correct owner", async () => { - expect(await resilientOracle.owner()).equals(sepolia.NORMAL_TIMELOCK); - expect(await chainLinkOracle.owner()).equals(sepolia.NORMAL_TIMELOCK); - expect(await redstoneOracle.owner()).equals(sepolia.NORMAL_TIMELOCK); - expect(await boundValidator.owner()).equals(sepolia.NORMAL_TIMELOCK); - expect(await sfraxETH.owner()).equals(sepolia.NORMAL_TIMELOCK); - }); - }); -}); diff --git a/vips/vip-372/bscmainnet.ts b/vips/vip-372/bscmainnet.ts deleted file mode 100644 index c75db413a..000000000 --- a/vips/vip-372/bscmainnet.ts +++ /dev/null @@ -1,180 +0,0 @@ -import { LzChainId, ProposalType } from "src/types"; -import { makeProposal } from "src/utils"; - -import { PLP as ARBITRUMONE_PLP, PRIME as ARBITRUMONE_PRIME } from "../../multisig/proposals/arbitrumone/vip-014"; -import { REWARD_DISTRIBUTORS as ARBITRUMONE_REWARD_DISTRIBUTORS } from "../../multisig/proposals/arbitrumone/vip-014"; -import { COMPTROLLERS as ARBITRUMONE_COMPTROLLERS } from "../../multisig/proposals/arbitrumone/vip-014"; -import { VTOKENS as ARBITRUMONE_VTOKENS } from "../../multisig/proposals/arbitrumone/vip-014"; -import { POOL_REGISTRY as ARBITRUMONE_POOL_REGISTRY } from "../../multisig/proposals/arbitrumone/vip-014"; -import { PSR as ARBITRUMONE_PSR } from "../../multisig/proposals/arbitrumone/vip-014"; -import { CONVERTERS as ETHEREUM_CONVERTERS } from "../../multisig/proposals/ethereum/vip-061"; -import { CONVERTER_NETWORK as ETHEREUM_CONVERTER_NETWORK } from "../../multisig/proposals/ethereum/vip-061"; -import { PLP as ETHEREUM_PLP, PRIME as ETHEREUM_PRIME } from "../../multisig/proposals/ethereum/vip-061"; -import { REWARD_DISTRIBUTORS as ETHEREUM_REWARD_DISTRIBUTORS } from "../../multisig/proposals/ethereum/vip-061"; -import { COMPTROLLERS as ETHEREUM_COMPTROLLERS } from "../../multisig/proposals/ethereum/vip-061"; -import { VTOKENS as ETHEREUM_VTOKENS } from "../../multisig/proposals/ethereum/vip-061"; -import { POOL_REGISTRY as ETHEREUM_POOL_REGISTRY } from "../../multisig/proposals/ethereum/vip-061"; -import { PSR as ETHEREUM_PSR } from "../../multisig/proposals/ethereum/vip-061"; -import { COMPTROLLERS as OPBNBMAINNET_COMPTROLLERS } from "../../multisig/proposals/opbnbmainnet/vip-021"; -import { VTOKENS as OPBNBMAINNET_VTOKENS } from "../../multisig/proposals/opbnbmainnet/vip-021"; -import { POOL_REGISTRY as OPBNBMAINNET_POOL_REGISTRY } from "../../multisig/proposals/opbnbmainnet/vip-021"; -import { PSR as OPBNBMAINNET_PSR } from "../../multisig/proposals/opbnbmainnet/vip-021"; - -const vip372 = () => { - const meta = { - version: "v2", - title: "VIP-372", - description: `### Description`, - forDescription: "I agree that Venus Protocol should proceed with this proposal", - againstDescription: "I do not think that Venus Protocol should proceed with this proposal", - abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", - }; - return makeProposal( - [ - { - target: ETHEREUM_CONVERTER_NETWORK, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.ethereum, - }, - ...ETHEREUM_CONVERTERS.map(converter => { - return { - target: converter, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.ethereum, - }; - }), - { - target: ETHEREUM_PRIME, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.ethereum, - }, - { - target: ETHEREUM_PLP, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.ethereum, - }, - { - target: ARBITRUMONE_PRIME, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumone, - }, - { - target: ARBITRUMONE_PLP, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumone, - }, - ...ETHEREUM_REWARD_DISTRIBUTORS.map(rewardDistirbutor => { - return { - target: rewardDistirbutor, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.ethereum, - }; - }), - - ...ARBITRUMONE_REWARD_DISTRIBUTORS.map(rewardDistirbutor => { - return { - target: rewardDistirbutor, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumone, - }; - }), - { - target: ETHEREUM_PSR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.ethereum, - }, - { - target: ARBITRUMONE_PSR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumone, - }, - { - target: OPBNBMAINNET_PSR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbmainnet, - }, - { - target: ETHEREUM_POOL_REGISTRY, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.ethereum, - }, - ...ETHEREUM_COMPTROLLERS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.ethereum, - }; - }), - ...ETHEREUM_VTOKENS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.ethereum, - }; - }), - - { - target: ARBITRUMONE_POOL_REGISTRY, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumone, - }, - ...ARBITRUMONE_COMPTROLLERS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumone, - }; - }), - ...ARBITRUMONE_VTOKENS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumone, - }; - }), - - { - target: OPBNBMAINNET_POOL_REGISTRY, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbmainnet, - }, - ...OPBNBMAINNET_COMPTROLLERS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbmainnet, - }; - }), - ...OPBNBMAINNET_VTOKENS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbmainnet, - }; - }), - ], - meta, - ProposalType.REGULAR, - ); -}; -export default vip372; diff --git a/vips/vip-372/bsctestnet.ts b/vips/vip-372/bsctestnet.ts deleted file mode 100644 index 071c473a1..000000000 --- a/vips/vip-372/bsctestnet.ts +++ /dev/null @@ -1,183 +0,0 @@ -import { LzChainId, ProposalType } from "src/types"; -import { makeProposal } from "src/utils"; - -import { - PLP as ARBITRUMSEPOLIA_PLP, - PRIME as ARBITRUMSEPOLIA_PRIME, -} from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import { REWARD_DISTRIBUTORS as ARBITRUMSEPOLIA_REWARD_DISTRIBUTORS } from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import { PSR as ARBITRUMSEPOLIA_PSR } from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import { COMPTROLLERS as ARBITRUMSEPOLIA_COMPTROLLERS } from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import { VTOKENS as ARBITRUMSEPOLIA_VTOKENS } from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import { POOL_REGISTRY as ARBITRUMSEPOLIA_POOL_REGISTRY } from "../../multisig/proposals/arbitrumsepolia/vip-014"; -import { PSR as OPBNBTESTNET_PSR } from "../../multisig/proposals/opbnbtestnet/vip-021"; -import { COMPTROLLERS as OPBNBTESTNET_COMPTROLLERS } from "../../multisig/proposals/opbnbtestnet/vip-021"; -import { VTOKENS as OPBNBTESTNET_VTOKENS } from "../../multisig/proposals/opbnbtestnet/vip-021"; -import { POOL_REGISTRY as OPBNBTESTNET_POOL_REGISTRY } from "../../multisig/proposals/opbnbtestnet/vip-021"; -import { CONVERTERS as SEPOLIA_CONVERTERS } from "../../multisig/proposals/sepolia/vip-060"; -import { CONVERTER_NETWORK as SEPOLIA_CONVERTER_NETWORK } from "../../multisig/proposals/sepolia/vip-060"; -import { PLP as SEPOLIA_PLP, PRIME as SEPOLIA_PRIME } from "../../multisig/proposals/sepolia/vip-060"; -import { REWARD_DISTRIBUTORS as SEPOLIA_REWARD_DISTRIBUTORS } from "../../multisig/proposals/sepolia/vip-060"; -import { PSR as SEPOLIA_PSR } from "../../multisig/proposals/sepolia/vip-060"; -import { COMPTROLLERS as SEPOLIA_COMPTROLLERS } from "../../multisig/proposals/sepolia/vip-060"; -import { VTOKENS as SEPOLIA_VTOKENS } from "../../multisig/proposals/sepolia/vip-060"; -import { POOL_REGISTRY as SEPOLIA_POOL_REGISTRY } from "../../multisig/proposals/sepolia/vip-060"; - -const vip372 = () => { - const meta = { - version: "v2", - title: "VIP-332 accept ownership & give permissions to Normal Timelock", - description: `### Description`, - forDescription: "I agree that Venus Protocol should proceed with this proposal", - againstDescription: "I do not think that Venus Protocol should proceed with this proposal", - abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", - }; - return makeProposal( - [ - { - target: SEPOLIA_CONVERTER_NETWORK, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }, - ...SEPOLIA_CONVERTERS.map(converter => { - return { - target: converter, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }; - }), - { - target: SEPOLIA_PRIME, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }, - { - target: SEPOLIA_PLP, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }, - { - target: ARBITRUMSEPOLIA_PRIME, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: ARBITRUMSEPOLIA_PLP, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - ...SEPOLIA_REWARD_DISTRIBUTORS.map(rewardDistirbutor => { - return { - target: rewardDistirbutor, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }; - }), - - ...ARBITRUMSEPOLIA_REWARD_DISTRIBUTORS.map(rewardDistirbutor => { - return { - target: rewardDistirbutor, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }; - }), - { - target: SEPOLIA_PSR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }, - { - target: ARBITRUMSEPOLIA_PSR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: OPBNBTESTNET_PSR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }, - { - target: SEPOLIA_POOL_REGISTRY, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }, - ...SEPOLIA_COMPTROLLERS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }; - }), - ...SEPOLIA_VTOKENS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }; - }), - - { - target: ARBITRUMSEPOLIA_POOL_REGISTRY, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - ...ARBITRUMSEPOLIA_COMPTROLLERS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }; - }), - ...ARBITRUMSEPOLIA_VTOKENS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }; - }), - - { - target: OPBNBTESTNET_POOL_REGISTRY, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }, - ...OPBNBTESTNET_COMPTROLLERS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }; - }), - ...OPBNBTESTNET_VTOKENS.map(comptroller => { - return { - target: comptroller, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }; - }), - ], - meta, - ProposalType.REGULAR, - ); -}; -export default vip372; diff --git a/vips/vip-373/bscmainnet.ts b/vips/vip-373/bscmainnet.ts deleted file mode 100644 index 3e1dcd8f4..000000000 --- a/vips/vip-373/bscmainnet.ts +++ /dev/null @@ -1,186 +0,0 @@ -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { LzChainId, ProposalType } from "src/types"; -import { makeProposal } from "src/utils"; - -export const ARBITRUM_ONE_XVS_STORE = "0x507D9923c954AAD8eC530ed8Dedb75bFc893Ec5e"; -export const ETHEREUM_XVS_STORE = "0x1Db646E1Ab05571AF99e47e8F909801e5C99d37B"; -export const OPBNBMAINNET_XVS_STORE = "0xc3279442a5aCaCF0A2EcB015d1cDDBb3E0f3F775"; - -export const ETHEREUM_XVS_BRIDGE_ADMIN = "0x9C6C95632A8FB3A74f2fB4B7FfC50B003c992b96"; -export const OPBNBMAINNET_XVS_BRIDGE_ADMIN = "0x52fcE05aDbf6103d71ed2BA8Be7A317282731831"; -export const ARBITRUM_XVS_BRIDGE_ADMIN = "0xf5d81C6F7DAA3F97A6265C8441f92eFda22Ad784"; - -const ETHEREUM_CHAIN_ID = LzChainId.ethereum; -const OPBNBMAINNET_CHAIN_ID = LzChainId.opbnbmainnet; -const ARBITRUM_CHAIN_ID = LzChainId.arbitrumone; - -export const ARBITRUM_ONE_BOUND_VALIDATOR = "0x2245FA2420925Cd3C2D889Ddc5bA1aefEF0E14CF"; -export const ETHEREUM_BOUND_VALIDATOR = "0x1Cd5f336A1d28Dff445619CC63d3A0329B4d8a58"; -export const OPBNBMAINNET_BOUND_VALIDATOR = "0xd1f80C371C6E2Fa395A5574DB3E3b4dAf43dadCE"; -export const ETHEREUM_sFrxETH_ORACLE = "0x5E06A5f48692E4Fff376fDfCA9E4C0183AAADCD1"; - -const { arbitrumone, ethereum, opbnbmainnet } = NETWORK_ADDRESSES; - -const vip373 = () => { - const meta = { - version: "v2", - title: "VIP-373", - description: `### Description`, - forDescription: "I agree that Venus Protocol should proceed with this proposal", - againstDescription: "I do not think that Venus Protocol should proceed with this proposal", - abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", - }; - return makeProposal( - [ - { - target: arbitrumone.XVS_VAULT_PROXY, - signature: "_acceptAdmin()", - params: [], - dstChainId: LzChainId.arbitrumone, - }, - { - target: ethereum.XVS_VAULT_PROXY, - signature: "_acceptAdmin()", - params: [], - dstChainId: LzChainId.ethereum, - }, - { - target: opbnbmainnet.XVS_VAULT_PROXY, - signature: "_acceptAdmin()", - params: [], - dstChainId: LzChainId.opbnbmainnet, - }, - { - target: ARBITRUM_ONE_XVS_STORE, - signature: "acceptAdmin()", - params: [], - dstChainId: LzChainId.arbitrumone, - }, - { - target: ETHEREUM_XVS_STORE, - signature: "acceptAdmin()", - params: [], - dstChainId: LzChainId.ethereum, - }, - { - target: OPBNBMAINNET_XVS_STORE, - signature: "acceptAdmin()", - params: [], - dstChainId: LzChainId.opbnbmainnet, - }, - { - target: ARBITRUM_XVS_BRIDGE_ADMIN, - signature: "acceptOwnership()", - params: [], - dstChainId: ARBITRUM_CHAIN_ID, - }, - { - target: OPBNBMAINNET_XVS_BRIDGE_ADMIN, - signature: "acceptOwnership()", - params: [], - dstChainId: OPBNBMAINNET_CHAIN_ID, - }, - { - target: ETHEREUM_XVS_BRIDGE_ADMIN, - signature: "acceptOwnership()", - params: [], - dstChainId: ETHEREUM_CHAIN_ID, - }, - { - target: arbitrumone.CHAINLINK_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumone, - }, - { - target: ARBITRUM_ONE_BOUND_VALIDATOR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumone, - }, - { - target: arbitrumone.REDSTONE_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumone, - }, - { - target: arbitrumone.RESILIENT_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumone, - }, - { - target: opbnbmainnet.BINANCE_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbmainnet, - }, - { - target: opbnbmainnet.RESILIENT_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbmainnet, - }, - { - target: OPBNBMAINNET_BOUND_VALIDATOR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbmainnet, - }, - - { - target: ethereum.CHAINLINK_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.ethereum, - }, - - { - target: ethereum.REDSTONE_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.ethereum, - }, - { - target: ethereum.RESILIENT_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.ethereum, - }, - { - target: ETHEREUM_BOUND_VALIDATOR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.ethereum, - }, - { - target: ETHEREUM_sFrxETH_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.ethereum, - }, - { - target: arbitrumone.VTREASURY, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumone, - }, - { - target: opbnbmainnet.VTREASURY, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbmainnet, - }, - { - target: ethereum.VTREASURY, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.ethereum, - }, - ], - meta, - ProposalType.REGULAR, - ); -}; -export default vip373; diff --git a/vips/vip-373/bsctestnet.ts b/vips/vip-373/bsctestnet.ts deleted file mode 100644 index 7ac657f9d..000000000 --- a/vips/vip-373/bsctestnet.ts +++ /dev/null @@ -1,192 +0,0 @@ -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { LzChainId, ProposalType } from "src/types"; -import { makeProposal } from "src/utils"; - -export const SEPOLIA_ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; -export const SEPOLIA_FASTTRACK_TIMELOCK = "0x7F043F43Adb392072a3Ba0cC9c96e894C6f7e182"; -export const SEPOLIA_CRITICAL_TIMELOCK = "0xA24A7A65b8968a749841988Bd7d05F6a94329fDe"; -export const ARBITRUM_SEPOLIA_ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; -export const OPBNBTESTNET_ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; - -export const ARBITRUM_SEPOLIA_XVS_STORE = "0x4e909DA6693215dC630104715c035B159dDb67Dd"; -export const SEPOLIA_XVS_STORE = "0x03B868C7858F50900fecE4eBc851199e957b5d3D"; -export const OPBNBTESTNET_XVS_STORE = "0x06473fB3f7bF11e2E8EfEcC95aC55ABEFCb2e0A0"; - -export const SEPOLIA_XVS_BRIDGE_ADMIN = "0xd3c6bdeeadB2359F726aD4cF42EAa8B7102DAd9B"; -export const OPBNBTESTNET_XVS_BRIDGE_ADMIN = "0x19252AFD0B2F539C400aEab7d460CBFbf74c17ff"; -export const ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN = "0xc94578caCC89a29B044a0a1D54d20d48A645E5C8"; - -const SEPOLIA_CHAIN_ID = LzChainId.sepolia; -const OPBNBTESTNET_CHAIN_ID = LzChainId.opbnbtestnet; -const ARBITRUM_SEPOLIA_CHAIN_ID = LzChainId.arbitrumsepolia; - -export const ARBITRUM_SEPOLIA_BOUND_VALIDATOR = "0xfe6bc1545Cc14C131bacA97476D6035ffcC0b889"; -export const SEPOLIA_BOUND_VALIDATOR = "0x60c4Aa92eEb6884a76b309Dd8B3731ad514d6f9B"; -export const OPBNBTESTNET_BOUND_VALIDATOR = "0x049537Bb065e6253e9D8D08B45Bf6b753657A746"; -export const SEPOLIA_sFrxETH_ORACLE = "0x61EB836afA467677e6b403D504fe69D6940e7996"; - -export const ARBITRUMSEPOLIA_ACM_AGGREGATOR = "0x4fCbfE445396f31005b3Fd2F6DE2A986d6E2dCB5"; -export const OPBNBTESTNET_ACM_AGGREGATOR = "0xbDd501dB1B0D6aab299CE69ef5B86C8578947AD0"; -export const SEPOLIA_ACM_AGGREGATOR = "0x0653830c55035d678e1287b2d4550519fd263d0e"; - -export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; - -const { arbitrumsepolia, sepolia, opbnbtestnet } = NETWORK_ADDRESSES; - -const vip373 = () => { - const meta = { - version: "v2", - title: "VIP-332 accept ownership & give permissions to Normal Timelock", - description: `### Description`, - forDescription: "I agree that Venus Protocol should proceed with this proposal", - againstDescription: "I do not think that Venus Protocol should proceed with this proposal", - abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", - }; - return makeProposal( - [ - { - target: arbitrumsepolia.XVS_VAULT_PROXY, - signature: "_acceptAdmin()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: sepolia.XVS_VAULT_PROXY, - signature: "_acceptAdmin()", - params: [], - dstChainId: LzChainId.sepolia, - }, - { - target: opbnbtestnet.XVS_VAULT_PROXY, - signature: "_acceptAdmin()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }, - { - target: ARBITRUM_SEPOLIA_XVS_STORE, - signature: "acceptAdmin()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: SEPOLIA_XVS_STORE, - signature: "acceptAdmin()", - params: [], - dstChainId: LzChainId.sepolia, - }, - { - target: OPBNBTESTNET_XVS_STORE, - signature: "acceptAdmin()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }, - { - target: ARBITRUM_SEPOLIA_XVS_BRIDGE_ADMIN, - signature: "acceptOwnership()", - params: [], - dstChainId: ARBITRUM_SEPOLIA_CHAIN_ID, - }, - { - target: OPBNBTESTNET_XVS_BRIDGE_ADMIN, - signature: "acceptOwnership()", - params: [], - dstChainId: OPBNBTESTNET_CHAIN_ID, - }, - { - target: SEPOLIA_XVS_BRIDGE_ADMIN, - signature: "acceptOwnership()", - params: [], - dstChainId: SEPOLIA_CHAIN_ID, - }, - { - target: arbitrumsepolia.CHAINLINK_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: ARBITRUM_SEPOLIA_BOUND_VALIDATOR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: arbitrumsepolia.REDSTONE_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: arbitrumsepolia.RESILIENT_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: opbnbtestnet.BINANCE_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }, - { - target: opbnbtestnet.RESILIENT_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }, - { - target: OPBNBTESTNET_BOUND_VALIDATOR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }, - - { - target: sepolia.CHAINLINK_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }, - - { - target: sepolia.REDSTONE_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }, - { - target: sepolia.RESILIENT_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }, - { - target: SEPOLIA_BOUND_VALIDATOR, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }, - { - target: SEPOLIA_sFrxETH_ORACLE, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.sepolia, - }, - { - target: arbitrumsepolia.VTREASURY, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.arbitrumsepolia, - }, - { - target: opbnbtestnet.VTREASURY, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opbnbtestnet, - }, - ], - meta, - ProposalType.REGULAR, - ); -}; -export default vip373; From 9b8642ea940163fe5774f228bb9f34dd3c11601a Mon Sep 17 00:00:00 2001 From: web3rover Date: Fri, 18 Oct 2024 16:19:11 +0400 Subject: [PATCH 047/178] fix: added ACM address --- simulations/vip-371/arbitrumsepolia.ts | 2 +- simulations/vip-371/opbnbtestnet.ts | 2 +- simulations/vip-371/sepolia.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/simulations/vip-371/arbitrumsepolia.ts b/simulations/vip-371/arbitrumsepolia.ts index f92e66d3f..2daeea2f6 100644 --- a/simulations/vip-371/arbitrumsepolia.ts +++ b/simulations/vip-371/arbitrumsepolia.ts @@ -4,12 +4,12 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; -import { ACM } from "../../multisig/proposals/arbitrumsepolia/vip-014"; import vip371, { ARBITRUMSEPOLIA_ACM_AGGREGATOR, DEFAULT_ADMIN_ROLE } from "../../vips/vip-371/bsctestnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { arbitrumsepolia } = NETWORK_ADDRESSES; +const ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; forking(87457288, async () => { testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { diff --git a/simulations/vip-371/opbnbtestnet.ts b/simulations/vip-371/opbnbtestnet.ts index d9d2939c1..f01bcde94 100644 --- a/simulations/vip-371/opbnbtestnet.ts +++ b/simulations/vip-371/opbnbtestnet.ts @@ -4,12 +4,12 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; -import { ACM } from "../../multisig/proposals/opbnbtestnet/vip-021"; import vip371, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { opbnbtestnet } = NETWORK_ADDRESSES; +const ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; forking(41684455, async () => { testForkedNetworkVipCommands("vip371", await vip371(), { diff --git a/simulations/vip-371/sepolia.ts b/simulations/vip-371/sepolia.ts index b6606e0a4..108025605 100644 --- a/simulations/vip-371/sepolia.ts +++ b/simulations/vip-371/sepolia.ts @@ -4,12 +4,12 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; -import { ACM } from "../../multisig/proposals/sepolia/vip-060"; import vip371, { DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { sepolia } = NETWORK_ADDRESSES; +const ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; forking(6850243, async () => { testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { From 538bbc79241b2c5e1eff4ae186bd0a6f32b6bf36 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Fri, 18 Oct 2024 17:27:09 +0200 Subject: [PATCH 048/178] feat: add description to VIP-385 --- .../abi/VTokenCorePool.json | 0 .../{vip-381 => vip-385}/bscmainnet.ts | 4 +- .../{vip-381 => vip-385}/bsctestnet.ts | 4 +- vips/vip-381/bscmainnet.ts | 30 --------- vips/vip-381/bsctestnet.ts | 30 --------- vips/vip-385/bscmainnet.ts | 65 +++++++++++++++++++ vips/vip-385/bsctestnet.ts | 65 +++++++++++++++++++ 7 files changed, 134 insertions(+), 64 deletions(-) rename simulations/{vip-381 => vip-385}/abi/VTokenCorePool.json (100%) rename simulations/{vip-381 => vip-385}/bscmainnet.ts (94%) rename simulations/{vip-381 => vip-385}/bsctestnet.ts (93%) delete mode 100644 vips/vip-381/bscmainnet.ts delete mode 100644 vips/vip-381/bsctestnet.ts create mode 100644 vips/vip-385/bscmainnet.ts create mode 100644 vips/vip-385/bsctestnet.ts diff --git a/simulations/vip-381/abi/VTokenCorePool.json b/simulations/vip-385/abi/VTokenCorePool.json similarity index 100% rename from simulations/vip-381/abi/VTokenCorePool.json rename to simulations/vip-385/abi/VTokenCorePool.json diff --git a/simulations/vip-381/bscmainnet.ts b/simulations/vip-385/bscmainnet.ts similarity index 94% rename from simulations/vip-381/bscmainnet.ts rename to simulations/vip-385/bscmainnet.ts index d1e6d4c39..a3f67d2f2 100644 --- a/simulations/vip-381/bscmainnet.ts +++ b/simulations/vip-385/bscmainnet.ts @@ -5,7 +5,7 @@ import { expectEvents } from "src/utils"; import { forking, testVip } from "src/vip-framework"; import { checkInterestRate, checkTwoKinksInterestRate } from "src/vip-framework/checks/interestRateModel"; -import vip381, { IRM } from "../../vips/vip-381/bscmainnet"; +import vip385, { IRM } from "../../vips/vip-385/bscmainnet"; import VTOKEN_CORE_POOL_ABI from "./abi/VTokenCorePool.json"; const OLD_IRM = "0xDb8347b96c94Be24B9c077A4CDDAAD074F6480cf"; @@ -31,7 +31,7 @@ forking(43192903, async () => { }); }); - testVip("VIP-381", await vip381(), { + testVip("VIP-385", await vip385(), { callbackAfterExecution: async (txResponse: TransactionResponse) => { await expectEvents(txResponse, [VTOKEN_CORE_POOL_ABI], ["NewMarketInterestRateModel"], [1]); }, diff --git a/simulations/vip-381/bsctestnet.ts b/simulations/vip-385/bsctestnet.ts similarity index 93% rename from simulations/vip-381/bsctestnet.ts rename to simulations/vip-385/bsctestnet.ts index 84ed905e7..60c4bc309 100644 --- a/simulations/vip-381/bsctestnet.ts +++ b/simulations/vip-385/bsctestnet.ts @@ -5,7 +5,7 @@ import { expectEvents } from "src/utils"; import { forking, testVip } from "src/vip-framework"; import { checkTwoKinksInterestRate } from "src/vip-framework/checks/interestRateModel"; -import vip381, { IRM } from "../../vips/vip-381/bsctestnet"; +import vip385, { IRM } from "../../vips/vip-385/bsctestnet"; import VTOKEN_CORE_POOL_ABI from "./abi/VTokenCorePool.json"; const OLD_IRM = "0x752B56f94c8dF2c3804c0Dd213Cf607FAa9D11b1"; @@ -22,7 +22,7 @@ forking(44812630, async () => { }); }); - testVip("VIP-381", await vip381(), { + testVip("VIP-385", await vip385(), { callbackAfterExecution: async (txResponse: TransactionResponse) => { await expectEvents(txResponse, [VTOKEN_CORE_POOL_ABI], ["NewMarketInterestRateModel"], [1]); }, diff --git a/vips/vip-381/bscmainnet.ts b/vips/vip-381/bscmainnet.ts deleted file mode 100644 index 0f9e0291f..000000000 --- a/vips/vip-381/bscmainnet.ts +++ /dev/null @@ -1,30 +0,0 @@ -import { ProposalType } from "src/types"; -import { makeProposal } from "src/utils"; - -export const IRM = "0xC682145a767ca98B743B895f1Bd2D4696bC9C2eC"; -export const VBNB_ADMIN = "0x9A7890534d9d91d473F28cB97962d176e2B65f1d"; - -const vip381 = () => { - const meta = { - version: "v2", - title: "VIP-381", - description: ``, - forDescription: "I agree that Venus Protocol should proceed with this proposal", - againstDescription: "I do not think that Venus Protocol should proceed with this proposal", - abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", - }; - - return makeProposal( - [ - { - target: VBNB_ADMIN, - signature: "setInterestRateModel(address)", - params: [IRM], - }, - ], - meta, - ProposalType.FAST_TRACK, - ); -}; - -export default vip381; diff --git a/vips/vip-381/bsctestnet.ts b/vips/vip-381/bsctestnet.ts deleted file mode 100644 index 548a66c27..000000000 --- a/vips/vip-381/bsctestnet.ts +++ /dev/null @@ -1,30 +0,0 @@ -import { ProposalType } from "src/types"; -import { makeProposal } from "src/utils"; - -export const IRM = "0x86954c6fCA6B464269Aa7011B143c4D93Dfa1146"; -export const VBNB_ADMIN = "0x04109575c1dbB4ac2e59e60c783800ea10441BBe"; - -const vip381 = () => { - const meta = { - version: "v2", - title: "VIP-381", - description: ``, - forDescription: "I agree that Venus Protocol should proceed with this proposal", - againstDescription: "I do not think that Venus Protocol should proceed with this proposal", - abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", - }; - - return makeProposal( - [ - { - target: VBNB_ADMIN, - signature: "setInterestRateModel(address)", - params: [IRM], - }, - ], - meta, - ProposalType.FAST_TRACK, - ); -}; - -export default vip381; diff --git a/vips/vip-385/bscmainnet.ts b/vips/vip-385/bscmainnet.ts new file mode 100644 index 000000000..99061394a --- /dev/null +++ b/vips/vip-385/bscmainnet.ts @@ -0,0 +1,65 @@ +import { ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const IRM = "0xC682145a767ca98B743B895f1Bd2D4696bC9C2eC"; +export const VBNB_ADMIN = "0x9A7890534d9d91d473F28cB97962d176e2B65f1d"; + +const vip385 = () => { + const meta = { + version: "v2", + title: "VIP-385 [BNB Chain] Risk Parameters Adjustments (BNB)", + description: `If passed, this VIP will perform the following Risk Parameter actions suggested by the Community in this Venus community forum publication: [BNB Market 2 Kink IRC Proposal](https://community.venus.io/t/bnb-market-2-kink-irc-proposal/4588/4). + +- [BNB (Core pool)](https://bscscan.com/address/0xA07c5b74C9B40447a954e1466938b865b6BBea36): replace the interest rate contract with the new TwoKinksInterestRate contract, with the following attributes: + - First slope: + - Kink: 0.4 + - Base rate: 0 + - Multiplier: 0.225 + - Second slope: + - Kink: 0.7 + - Base: 0.21 + - Multiplier: 0.35 + - Jump multiplier: 5 + +Complete analysis and details of these recommendations are available in the above publication. + +#### Security and additional considerations + +We applied the following security procedures for this upgrade: + +- **Audits**: [Quantstamp](https://quantstamp.com/), [Certik](https://www.certik.com/), and [Fairyproof](https://www.fairyproof.com/) have audited the TwoKinksInterestRate code +- **VIP execution simulation**: in a simulation environment, validating the changes in the configurations are performed as expected +- **Deployment on testnet**: the same change has been performed on BNB Chain testnet, and used in the Venus Protocol testnet environment + +#### Audit reports + +- [Certik audit audit report](https://github.com/VenusProtocol/venus-protocol/blob/8be0034819eef313d6ffe216e5ba0f1152dbdcc0/audits/113_twoKinks_certik_20240731.pdf) (2024/07/31) +- [Quantstamp audit audit report](https://github.com/VenusProtocol/venus-protocol/blob/8be0034819eef313d6ffe216e5ba0f1152dbdcc0/audits/115_twoKinks_quantstamp_20240819.pdf) (2024/08/19) +- [Fairyproof audit report](https://github.com/VenusProtocol/venus-protocol/blob/8be0034819eef313d6ffe216e5ba0f1152dbdcc0/audits/114_twoKinks_fairyproof_20240804.pdf) (2024/08/04) + +#### References + +- [VIP simulation](https://github.com/VenusProtocol/vips/pull/406) +- [New Interest Rate contract for the vBNB market](https://bscscan.com/address/0xC682145a767ca98B743B895f1Bd2D4696bC9C2eC) +- Snapshot “[[BNB Chain] BNB Market 2 Kink IRC Proposal](https://snapshot.org/#/venus-xvs.eth/proposal/0xaf7975c6484b0fb640e3a03b667c7a5e4fb183b6b636a155c3aac67798627dde)” +- Source code of [TwoKinksInterestRateModel smart contract](https://github.com/VenusProtocol/venus-protocol/blob/main/contracts/InterestRateModels/TwoKinksInterestRateModel.sol) +- [Documentation about TwoKinksInterestRate](https://docs-v4.venus.io/technical-reference/reference-technical-articles/two-kinks-interest-rate-curve)`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + + return makeProposal( + [ + { + target: VBNB_ADMIN, + signature: "setInterestRateModel(address)", + params: [IRM], + }, + ], + meta, + ProposalType.FAST_TRACK, + ); +}; + +export default vip385; diff --git a/vips/vip-385/bsctestnet.ts b/vips/vip-385/bsctestnet.ts new file mode 100644 index 000000000..d2941a860 --- /dev/null +++ b/vips/vip-385/bsctestnet.ts @@ -0,0 +1,65 @@ +import { ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const IRM = "0x86954c6fCA6B464269Aa7011B143c4D93Dfa1146"; +export const VBNB_ADMIN = "0x04109575c1dbB4ac2e59e60c783800ea10441BBe"; + +const vip385 = () => { + const meta = { + version: "v2", + title: "VIP-385 [BNB Chain] Risk Parameters Adjustments (BNB)", + description: `If passed, this VIP will perform the following Risk Parameter actions suggested by the Community in this Venus community forum publication: [BNB Market 2 Kink IRC Proposal](https://community.venus.io/t/bnb-market-2-kink-irc-proposal/4588/4). + +- [BNB (Core pool)](https://bscscan.com/address/0xA07c5b74C9B40447a954e1466938b865b6BBea36): replace the interest rate contract with the new TwoKinksInterestRate contract, with the following attributes: + - First slope: + - Kink: 0.4 + - Base rate: 0 + - Multiplier: 0.225 + - Second slope: + - Kink: 0.7 + - Base: 0.21 + - Multiplier: 0.35 + - Jump multiplier: 5 + +Complete analysis and details of these recommendations are available in the above publication. + +#### Security and additional considerations + +We applied the following security procedures for this upgrade: + +- **Audits**: [Quantstamp](https://quantstamp.com/), [Certik](https://www.certik.com/), and [Fairyproof](https://www.fairyproof.com/) have audited the TwoKinksInterestRate code +- **VIP execution simulation**: in a simulation environment, validating the changes in the configurations are performed as expected +- **Deployment on testnet**: the same change has been performed on BNB Chain testnet, and used in the Venus Protocol testnet environment + +#### Audit reports + +- [Certik audit audit report](https://github.com/VenusProtocol/venus-protocol/blob/8be0034819eef313d6ffe216e5ba0f1152dbdcc0/audits/113_twoKinks_certik_20240731.pdf) (2024/07/31) +- [Quantstamp audit audit report](https://github.com/VenusProtocol/venus-protocol/blob/8be0034819eef313d6ffe216e5ba0f1152dbdcc0/audits/115_twoKinks_quantstamp_20240819.pdf) (2024/08/19) +- [Fairyproof audit report](https://github.com/VenusProtocol/venus-protocol/blob/8be0034819eef313d6ffe216e5ba0f1152dbdcc0/audits/114_twoKinks_fairyproof_20240804.pdf) (2024/08/04) + +#### References + +- [VIP simulation](https://github.com/VenusProtocol/vips/pull/406) +- [New Interest Rate contract for the vBNB market](https://bscscan.com/address/0xC682145a767ca98B743B895f1Bd2D4696bC9C2eC) +- Snapshot “[[BNB Chain] BNB Market 2 Kink IRC Proposal](https://snapshot.org/#/venus-xvs.eth/proposal/0xaf7975c6484b0fb640e3a03b667c7a5e4fb183b6b636a155c3aac67798627dde)” +- Source code of [TwoKinksInterestRateModel smart contract](https://github.com/VenusProtocol/venus-protocol/blob/main/contracts/InterestRateModels/TwoKinksInterestRateModel.sol) +- [Documentation about TwoKinksInterestRate](https://docs-v4.venus.io/technical-reference/reference-technical-articles/two-kinks-interest-rate-curve)`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + + return makeProposal( + [ + { + target: VBNB_ADMIN, + signature: "setInterestRateModel(address)", + params: [IRM], + }, + ], + meta, + ProposalType.FAST_TRACK, + ); +}; + +export default vip385; From 0a9903813eeaa2ca985d4bf0999cbc6c869fa716 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Mon, 21 Oct 2024 16:20:16 +0530 Subject: [PATCH 049/178] feat: vip for normal timelock on opsepolia --- multisig/proposals/opsepolia/vip-007/index.ts | 19 + .../vip-007/abi/AccessControlManagerAbi.json | 360 ++++++++++++++++++ .../simulations/opsepolia/vip-007/index.ts | 38 ++ src/networkAddresses.ts | 5 +- 4 files changed, 421 insertions(+), 1 deletion(-) create mode 100644 multisig/proposals/opsepolia/vip-007/index.ts create mode 100644 multisig/simulations/opsepolia/vip-007/abi/AccessControlManagerAbi.json create mode 100644 multisig/simulations/opsepolia/vip-007/index.ts diff --git a/multisig/proposals/opsepolia/vip-007/index.ts b/multisig/proposals/opsepolia/vip-007/index.ts new file mode 100644 index 000000000..99259ac51 --- /dev/null +++ b/multisig/proposals/opsepolia/vip-007/index.ts @@ -0,0 +1,19 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; + +import { makeProposal } from "../../../../src/utils"; + +const { opsepolia } = NETWORK_ADDRESSES; + +export const OPSEPOLIA_ACM = "0x1652E12C8ABE2f0D84466F0fc1fA4286491B3BC1"; +const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + +export const vip007 = () => { + return makeProposal([ + { + target: OPSEPOLIA_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, opsepolia.NORMAL_TIMELOCK], + }, + ]); +}; +export default vip007; diff --git a/multisig/simulations/opsepolia/vip-007/abi/AccessControlManagerAbi.json b/multisig/simulations/opsepolia/vip-007/abi/AccessControlManagerAbi.json new file mode 100644 index 000000000..4a118fcc4 --- /dev/null +++ b/multisig/simulations/opsepolia/vip-007/abi/AccessControlManagerAbi.json @@ -0,0 +1,360 @@ +[ + { + "inputs": [], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "indexed": false, + "internalType": "string", + "name": "functionSig", + "type": "string" + } + ], + "name": "PermissionGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "indexed": false, + "internalType": "string", + "name": "functionSig", + "type": "string" + } + ], + "name": "PermissionRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "bytes32", + "name": "role", + "type": "bytes32" + }, + { + "indexed": true, + "internalType": "bytes32", + "name": "previousAdminRole", + "type": "bytes32" + }, + { + "indexed": true, + "internalType": "bytes32", + "name": "newAdminRole", + "type": "bytes32" + } + ], + "name": "RoleAdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "bytes32", + "name": "role", + "type": "bytes32" + }, + { + "indexed": true, + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + } + ], + "name": "RoleGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "bytes32", + "name": "role", + "type": "bytes32" + }, + { + "indexed": true, + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + } + ], + "name": "RoleRevoked", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_ADMIN_ROLE", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "role", + "type": "bytes32" + } + ], + "name": "getRoleAdmin", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "accountToPermit", + "type": "address" + } + ], + "name": "giveCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "role", + "type": "bytes32" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "grantRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + } + ], + "name": "hasPermission", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "role", + "type": "bytes32" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "hasRole", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + } + ], + "name": "isAllowedToCall", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "role", + "type": "bytes32" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "renounceRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "accountToRevoke", + "type": "address" + } + ], + "name": "revokeCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "role", + "type": "bytes32" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "revokeRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "interfaceId", + "type": "bytes4" + } + ], + "name": "supportsInterface", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/opsepolia/vip-007/index.ts b/multisig/simulations/opsepolia/vip-007/index.ts new file mode 100644 index 000000000..71a0726ff --- /dev/null +++ b/multisig/simulations/opsepolia/vip-007/index.ts @@ -0,0 +1,38 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip007, { OPSEPOLIA_ACM } from "../../../proposals/opsepolia/vip-007"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManagerAbi.json"; + +const { opsepolia } = NETWORK_ADDRESSES; + +forking(18680626, async () => { + let acm: Contract; + let defaultAdminRole: string; + + before(async () => { + acm = await ethers.getContractAt(ACCESS_CONTROL_MANAGER_ABI, OPSEPOLIA_ACM); + defaultAdminRole = await acm.DEFAULT_ADMIN_ROLE(); + }); + + describe("Pre-VIP behaviour", async () => { + it("Normal Timelock does not has default admin role", async () => { + const hasRole = await acm.hasRole(defaultAdminRole, opsepolia.NORMAL_TIMELOCK); + expect(hasRole).equals(false); + }); + }); + + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip007()); + }); + + it("Normal Timelock has default admin role", async () => { + const hasRole = await acm.hasRole(defaultAdminRole, opsepolia.NORMAL_TIMELOCK); + expect(hasRole).equals(true); + }); + }); +}); diff --git a/src/networkAddresses.ts b/src/networkAddresses.ts index 0782d231d..0c52fb22f 100644 --- a/src/networkAddresses.ts +++ b/src/networkAddresses.ts @@ -186,7 +186,7 @@ export const NETWORK_ADDRESSES = { GENERIC_TEST_USER_ACCOUNT: "0x6f057A858171e187124ddEDF034dAc63De5dE5dB", }, opsepolia: { - NORMAL_TIMELOCK: "", // To be deployed + NORMAL_TIMELOCK: "0xdDe31d7eEEAD7Cf9790F833C4FF4c6e61404402a", // To be deployed VTREASURY: "0x5A1a12F47FA7007C9e23cf5e025F3f5d3aC7d755", GUARDIAN: "0xd57365EE4E850e881229e2F8Aa405822f289e78d", XVS_VAULT_PROXY: "0x4d344e48F02234E82D7D1dB84d0A4A18Aa43Dacc", @@ -195,6 +195,9 @@ export const NETWORK_ADDRESSES = { RESILIENT_ORACLE: "0x6c01ECa2B5C97F135406a3A5531445A7d977D28e", CHAINLINK_ORACLE: "0x493C3f543AEa37EefF17D823f27Cb1feAB9f3143", POOL_REGISTRY: "0x6538C861C7A6997602311342657b9143dD9E8152", + ENDPOINT: "0x55370E0fBB5f5b8dAeD978BA1c075a499eB107B8", + LZ_LIBRARY: "0xC6d12200b743A8F7e6b7228B8E920A71d94FA7Fb", + OMNICHAIN_GOVERNANCE_EXECUTOR: "0xC7D6D33adcdBfccD416C3aAB1878360ea8b79ac6", }, opmainnet: { NORMAL_TIMELOCK: "", // To be deployed From d5e2ffc6af4d7c95ab212c357321e38bab1901ae Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Mon, 21 Oct 2024 16:20:55 +0530 Subject: [PATCH 050/178] feat: vip for multichain governance on opsepolia --- simulations/vip-384/abi/ACMAggregator.json | 242 ++++++++ .../vip-384/abi/AccessControlManager_ABI.json | 157 +++++ .../abi/OmnichainExecutorOwner_ABI.json | 145 +++++ .../abi/OmnichainGovernanceExecutor_ABI.json | 539 ++++++++++++++++++ .../vip-384/abi/OmnichainProposalSender.json | 314 ++++++++++ simulations/vip-384/bsctestnet.ts | 55 ++ simulations/vip-384/opsepolia.ts | 151 +++++ vips/vip-384/bsctestnet.ts | 64 +++ 8 files changed, 1667 insertions(+) create mode 100644 simulations/vip-384/abi/ACMAggregator.json create mode 100644 simulations/vip-384/abi/AccessControlManager_ABI.json create mode 100644 simulations/vip-384/abi/OmnichainExecutorOwner_ABI.json create mode 100644 simulations/vip-384/abi/OmnichainGovernanceExecutor_ABI.json create mode 100644 simulations/vip-384/abi/OmnichainProposalSender.json create mode 100644 simulations/vip-384/bsctestnet.ts create mode 100644 simulations/vip-384/opsepolia.ts create mode 100644 vips/vip-384/bsctestnet.ts diff --git a/simulations/vip-384/abi/ACMAggregator.json b/simulations/vip-384/abi/ACMAggregator.json new file mode 100644 index 000000000..6650a3f3c --- /dev/null +++ b/simulations/vip-384/abi/ACMAggregator.json @@ -0,0 +1,242 @@ +[ + { + "inputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "_acm", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [], + "name": "EmptyPermissions", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "GrantPermissionsAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "GrantPermissionsExecuted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "RevokePermissionsAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "RevokePermissionsExecuted", + "type": "event" + }, + { + "inputs": [], + "name": "ACM", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "internalType": "struct ACMCommandsAggregator.Permission[]", + "name": "_permissions", + "type": "tuple[]" + } + ], + "name": "addGrantPermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "internalType": "struct ACMCommandsAggregator.Permission[]", + "name": "_permissions", + "type": "tuple[]" + } + ], + "name": "addRevokePermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "executeGrantPermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "index", + "type": "uint256" + } + ], + "name": "executeRevokePermissions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "grantPermissions", + "outputs": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "revokePermissions", + "outputs": [ + { + "internalType": "address", + "name": "contractAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "functionSig", + "type": "string" + }, + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-384/abi/AccessControlManager_ABI.json b/simulations/vip-384/abi/AccessControlManager_ABI.json new file mode 100644 index 000000000..2ef119947 --- /dev/null +++ b/simulations/vip-384/abi/AccessControlManager_ABI.json @@ -0,0 +1,157 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } + ], + "name": "RoleAdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleRevoked", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_ADMIN_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleAdmin", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToPermit", "type": "address" } + ], + "name": "giveCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "grantRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "hasPermission", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "hasRole", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "isAllowedToCall", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "renounceRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToRevoke", "type": "address" } + ], + "name": "revokeCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "revokeRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], + "name": "supportsInterface", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-384/abi/OmnichainExecutorOwner_ABI.json b/simulations/vip-384/abi/OmnichainExecutorOwner_ABI.json new file mode 100644 index 000000000..f75834e6c --- /dev/null +++ b/simulations/vip-384/abi/OmnichainExecutorOwner_ABI.json @@ -0,0 +1,145 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "omnichainGovernanceExecutor_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "string", "name": "signature", "type": "string" }, + { "indexed": false, "internalType": "bool", "name": "active", "type": "bool" } + ], + "name": "FunctionRegistryChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "stateMutability": "nonpayable", "type": "fallback" }, + { + "inputs": [], + "name": "OMNICHAIN_GOVERNANCE_EXECUTOR", + "outputs": [{ "internalType": "contract IOmnichainGovernanceExecutor", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes4", "name": "", "type": "bytes4" }], + "name": "functionRegistry", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "srcAddress_", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner_", "type": "address" }], + "name": "transferBridgeOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "string[]", "name": "signatures_", "type": "string[]" }, + { "internalType": "bool[]", "name": "active_", "type": "bool[]" } + ], + "name": "upsertSignature", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-384/abi/OmnichainGovernanceExecutor_ABI.json b/simulations/vip-384/abi/OmnichainGovernanceExecutor_ABI.json new file mode 100644 index 000000000..b40c3cf44 --- /dev/null +++ b/simulations/vip-384/abi/OmnichainGovernanceExecutor_ABI.json @@ -0,0 +1,539 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "endpoint_", "type": "address" }, + { "internalType": "address", "name": "guardian_", "type": "address" }, + { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "InvalidProposalId", "type": "error" }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "indexed": false, "internalType": "bytes", "name": "_payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "_reason", "type": "bytes" } + ], + "name": "MessageFailed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldGuardian", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newGuardian", "type": "address" } + ], + "name": "NewGuardian", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint256", "name": "id", "type": "uint256" }], + "name": "ProposalCanceled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint256", "name": "id", "type": "uint256" }], + "name": "ProposalExecuted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "id", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "eta", "type": "uint256" } + ], + "name": "ProposalQueued", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "address[]", "name": "targets", "type": "address[]" }, + { "indexed": false, "internalType": "uint256[]", "name": "values", "type": "uint256[]" }, + { "indexed": false, "internalType": "string[]", "name": "signatures", "type": "string[]" }, + { "indexed": false, "internalType": "bytes[]", "name": "calldatas", "type": "bytes[]" }, + { "indexed": false, "internalType": "uint8", "name": "proposalType", "type": "uint8" } + ], + "name": "ProposalReceived", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "srcChainId", "type": "uint16" }, + { "indexed": true, "internalType": "bytes", "name": "srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "nonce", "type": "uint64" }, + { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } + ], + "name": "ReceivePayloadFailed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "indexed": false, "internalType": "bytes32", "name": "_payloadHash", "type": "bytes32" } + ], + "name": "RetryMessageSuccess", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyReceiveLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint16", "name": "_type", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "_minDstGas", "type": "uint256" } + ], + "name": "SetMinDstGas", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "precrime", "type": "address" }], + "name": "SetPrecrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "oldSrcChainId", "type": "uint16" }, + { "indexed": true, "internalType": "uint16", "name": "newSrcChainId", "type": "uint16" } + ], + "name": "SetSrcChainId", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "", "type": "address" }, + { "indexed": false, "internalType": "uint8", "name": "", "type": "uint8" } + ], + "name": "SetTimelockPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_path", "type": "bytes" } + ], + "name": "SetTrustedRemote", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint8", "name": "routeType", "type": "uint8" }, + { "indexed": true, "internalType": "address", "name": "oldTimelock", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newTimelock", "type": "address" } + ], + "name": "TimelockAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_PAYLOAD_SIZE_LIMIT", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ITimelock[]", "name": "timelocks_", "type": "address[]" }], + "name": "addTimelocks", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "proposalId_", "type": "uint256" }], + "name": "cancel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "proposalId_", "type": "uint256" }], + "name": "execute", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "", "type": "uint16" }, + { "internalType": "bytes", "name": "", "type": "bytes" }, + { "internalType": "uint64", "name": "", "type": "uint64" } + ], + "name": "failedMessages", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } + ], + "name": "forceResumeReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_version", "type": "uint16" }, + { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "_configType", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }], + "name": "getTrustedRemoteAddress", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "guardian", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } + ], + "name": "isTrustedRemote", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "last24HourCommandsReceived", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "last24HourReceiveWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "lastProposalReceived", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "lzEndpoint", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "internalType": "bytes", "name": "_payload", "type": "bytes" } + ], + "name": "lzReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxDailyReceiveLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "", "type": "uint16" }, + { "internalType": "uint16", "name": "", "type": "uint16" } + ], + "name": "minDstGasLookup", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, + { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, + { "internalType": "bytes", "name": "_payload", "type": "bytes" } + ], + "name": "nonblockingLzReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "payloadSizeLimitLookup", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "precrime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "proposalTimelocks", + "outputs": [{ "internalType": "contract ITimelock", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "proposals", + "outputs": [ + { "internalType": "uint256", "name": "id", "type": "uint256" }, + { "internalType": "uint256", "name": "eta", "type": "uint256" }, + { "internalType": "bool", "name": "canceled", "type": "bool" }, + { "internalType": "bool", "name": "executed", "type": "bool" }, + { "internalType": "uint8", "name": "proposalType", "type": "uint8" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "queued", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "srcAddress_", "type": "bytes" }, + { "internalType": "uint64", "name": "nonce_", "type": "uint64" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" } + ], + "name": "retryMessage", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_version", "type": "uint16" }, + { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, + { "internalType": "uint256", "name": "_configType", "type": "uint256" }, + { "internalType": "bytes", "name": "_config", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newGuardian", "type": "address" }], + "name": "setGuardian", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit_", "type": "uint256" }], + "name": "setMaxDailyReceiveLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "internalType": "uint16", "name": "_packetType", "type": "uint16" }, + { "internalType": "uint256", "name": "_minGas", "type": "uint256" } + ], + "name": "setMinDstGas", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, + { "internalType": "uint256", "name": "_size", "type": "uint256" } + ], + "name": "setPayloadSizeLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "_precrime", "type": "address" }], + "name": "setPrecrime", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], + "name": "setReceiveVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }], + "name": "setSrcChainId", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "pendingAdmin_", "type": "address" }, + { "internalType": "uint8", "name": "proposalType_", "type": "uint8" } + ], + "name": "setTimelockPendingAdmin", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_path", "type": "bytes" } + ], + "name": "setTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, + { "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "srcChainId", + "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "proposalId_", "type": "uint256" }], + "name": "state", + "outputs": [{ "internalType": "enum OmnichainGovernanceExecutor.ProposalState", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } +] diff --git a/simulations/vip-384/abi/OmnichainProposalSender.json b/simulations/vip-384/abi/OmnichainProposalSender.json new file mode 100644 index 000000000..66fd4df02 --- /dev/null +++ b/simulations/vip-384/abi/OmnichainProposalSender.json @@ -0,0 +1,314 @@ +[ + { + "inputs": [ + { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } + ], + "name": "ClearPayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } + ], + "name": "ExecuteRemoteProposal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "FallbackWithdraw", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } + ], + "name": "StorePayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], + "name": "TrustedRemoteRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "LZ_ENDPOINT", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourCommandsSent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLastProposalSentTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bool", "name": "useZro_", "type": "bool" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } + ], + "name": "estimateFees", + "outputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } + ], + "name": "execute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "fallbackWithdraw", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "proposalCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], + "name": "removeTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "retryExecute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" }, + { "internalType": "bytes", "name": "config_", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "storedExecutionHashes", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } +] diff --git a/simulations/vip-384/bsctestnet.ts b/simulations/vip-384/bsctestnet.ts new file mode 100644 index 000000000..c479a82de --- /dev/null +++ b/simulations/vip-384/bsctestnet.ts @@ -0,0 +1,55 @@ +import { expect } from "chai"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId } from "src/types"; +import { expectEvents } from "src/utils"; +import { forking, testVip } from "src/vip-framework"; + +import vip384, { MAX_DAILY_LIMIT, OMNICHAIN_PROPOSAL_SENDER } from "../../vips/vip-384/bsctestnet"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +const { opsepolia } = NETWORK_ADDRESSES; +forking(44927774, async () => { + const provider = ethers.provider; + const omnichainProposalSender = new ethers.Contract( + OMNICHAIN_PROPOSAL_SENDER, + OMNICHAIN_PROPOSAL_SENDER_ABI, + provider, + ); + + describe("Pre-VIP behaviour", () => { + it("Daily limit should be 0", async () => { + expect(await omnichainProposalSender.chainIdToMaxDailyLimit(LzChainId.opsepolia)).to.equals(0); + }); + it("Trusted remote should not be set", async () => { + expect(await omnichainProposalSender.trustedRemoteLookup(LzChainId.opsepolia)).to.be.equals("0x"); + }); + }); + + testVip("vip384 give permissions to timelock", await vip384(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [ACCESS_CONTROL_MANAGER_ABI, OMNICHAIN_PROPOSAL_SENDER_ABI], + ["SetMaxDailyLimit", "SetTrustedRemoteAddress", "ExecuteRemoteProposal", "StorePayload"], + [1, 1, 1, 0], + ); + }, + }); + + describe("Post-VIP behavior", () => { + it("Daily limit should be 100 of opsepolia", async () => { + expect(await omnichainProposalSender.chainIdToMaxDailyLimit(LzChainId.opsepolia)).to.equals(MAX_DAILY_LIMIT); + }); + + it("Trusted remote should be set of opsepolia", async () => { + expect(await omnichainProposalSender.trustedRemoteLookup(LzChainId.opsepolia)).to.be.equals( + ethers.utils.solidityPack( + ["address", "address"], + [opsepolia.OMNICHAIN_GOVERNANCE_EXECUTOR, OMNICHAIN_PROPOSAL_SENDER], + ), + ); + }); + }); +}); diff --git a/simulations/vip-384/opsepolia.ts b/simulations/vip-384/opsepolia.ts new file mode 100644 index 000000000..a7dca781b --- /dev/null +++ b/simulations/vip-384/opsepolia.ts @@ -0,0 +1,151 @@ +import { expect } from "chai"; +import { BigNumber, Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId } from "src/types"; +import { expectEvents, getOmnichainProposalSenderAddress } from "src/utils"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip010 from "../../multisig/proposals/opsepolia/vip-007"; +import vip365, { + DEFAULT_ADMIN_ROLE, + OPSEPOLIA_ACM, + OPSEPOLIA_ACM_AGGREGATOR, + OPSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, +} from "../../vips/vip-384/bsctestnet"; +import ACMAggregator_ABI from "./abi/ACMAggregator.json"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; +import OMNICHAIN_EXECUTOR_OWNER_ABI from "./abi/OmnichainExecutorOwner_ABI.json"; +import OMNICHAIN_GOVERNANCE_EXECUTOR_ABI from "./abi/OmnichainGovernanceExecutor_ABI.json"; + +const { opsepolia } = NETWORK_ADDRESSES; +const FAST_TRACK_TIMELOCK = "0xb055e028b27d53a455a6c040a6952e44E9E615c4"; +const CRITICAL_TIMELOCK = "0x0E6138bE0FA1915efC73670a20A10EFd720a6Cc8"; + +forking(18850742, async () => { + const provider = ethers.provider; + let lastProposalReceived: BigNumber; + let executor: Contract; + let executorOwner: Contract; + + before(async () => { + executor = new ethers.Contract( + opsepolia.OMNICHAIN_GOVERNANCE_EXECUTOR, + OMNICHAIN_GOVERNANCE_EXECUTOR_ABI, + provider, + ); + executorOwner = new ethers.Contract(OPSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, OMNICHAIN_EXECUTOR_OWNER_ABI, provider); + lastProposalReceived = await executor.lastProposalReceived(); + await pretendExecutingVip(await vip010()); + }); + + describe("Pre-VIP behaviour", async () => { + it("Normal Timelock has default admin role on ZKsync sepolia", async () => { + const acm = await ethers.getContractAt(ACCESS_CONTROL_MANAGER_ABI, OPSEPOLIA_ACM); + const hasRole = await acm.hasRole(DEFAULT_ADMIN_ROLE, opsepolia.NORMAL_TIMELOCK); + expect(hasRole).equals(true); + }); + }); + + testForkedNetworkVipCommands("vip365 configures bridge", await vip365(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [39]); + await expectEvents(txResponse, [ACMAggregator_ABI], ["GrantPermissionsExecuted"], [1]); + }, + }); + + describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(OPSEPOLIA_ACM, ACCESS_CONTROL_MANAGER_ABI, provider); + + it("Proposal id should be incremented", async () => { + expect(await executor.lastProposalReceived()).to.be.equals(lastProposalReceived.add(1)); + }); + it("proposal should be executed", async () => { + const pId = await executor.lastProposalReceived(); + expect(await executor.state(pId)).to.be.equals(2); + }); + it("check configuration", async () => { + // Check Timelock configurations + expect(await executor.proposalTimelocks(0)).equals(opsepolia.NORMAL_TIMELOCK); + expect(await executor.proposalTimelocks(1)).equals(FAST_TRACK_TIMELOCK); + expect(await executor.proposalTimelocks(2)).equals(CRITICAL_TIMELOCK); + + // Check trusted remote + expect(await executor.trustedRemoteLookup(LzChainId.bsctestnet)).equals( + ethers.utils.solidityPack( + ["address", "address"], + [getOmnichainProposalSenderAddress(), opsepolia.OMNICHAIN_GOVERNANCE_EXECUTOR], + ), + ); + + // Check receiving limit + expect(await executor.maxDailyReceiveLimit()).equals(100); + expect(await executor.last24HourCommandsReceived()).equals(4); + + // Check function registry + const functionSignatures: string[] = [ + "forceResumeReceive(uint16,bytes)", + "pause()", + "unpause()", + "setSendVersion(uint16)", + "setReceiveVersion(uint16)", + "setMaxDailyReceiveLimit(uint256)", + "setTrustedRemoteAddress(uint16,bytes)", + "setPrecrime(address)", + "setMinDstGas(uint16,uint16,uint256)", + "setPayloadSizeLimit(uint16,uint256)", + "setConfig(uint16,uint16,uint256,bytes)", + "addTimelocks(ITimelock[])", + "setTimelockPendingAdmin(address,uint8)", + "retryMessage(uint16,bytes,uint64,bytes)", + "setGuardian(address)", + "setSrcChainId(uint16)", + ]; + const getFunctionSelector = (signature: string): string => { + return ethers.utils.keccak256(ethers.utils.toUtf8Bytes(signature)).substring(0, 10); + }; + + for (const signature of functionSignatures) { + const selector = getFunctionSelector(signature); + expect(await executorOwner.functionRegistry(selector)).equals(signature); + } + }); + it("Default admin role must be revoked from ACMAggregator contract on ZKsync sepolia", async () => { + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPSEPOLIA_ACM_AGGREGATOR)).to.be.false; + }); + it("Guardian and all timelocks are allowed to call retryMessage ", async () => { + const role = ethers.utils.solidityPack( + ["address", "string"], + [OPSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "retryMessage(uint16,bytes,uint64,bytes)"], + ); + const roleHash = ethers.utils.keccak256(role); + expect(await acm.hasRole(roleHash, opsepolia.GUARDIAN)).to.be.true; + expect(await acm.hasRole(roleHash, opsepolia.NORMAL_TIMELOCK)).to.be.true; + expect(await acm.hasRole(roleHash, FAST_TRACK_TIMELOCK)).to.be.true; + expect(await acm.hasRole(roleHash, CRITICAL_TIMELOCK)).to.be.true; + }); + + it("Guardian is allowed to call forceResumeReceive but not timelocks", async () => { + const role = ethers.utils.solidityPack( + ["address", "string"], + [OPSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "forceResumeReceive(uint16,bytes)"], + ); + const roleHash = ethers.utils.keccak256(role); + expect(await acm.hasRole(roleHash, opsepolia.GUARDIAN)).to.be.true; + expect(await acm.hasRole(roleHash, opsepolia.NORMAL_TIMELOCK)).to.be.false; + expect(await acm.hasRole(roleHash, FAST_TRACK_TIMELOCK)).to.be.false; + expect(await acm.hasRole(roleHash, CRITICAL_TIMELOCK)).to.be.false; + }); + it("Normal Timelock is allowed to call setSendVersion but not other timelocks and guardian", async () => { + const role = ethers.utils.solidityPack( + ["address", "string"], + [OPSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, "setSendVersion(uint16)"], + ); + const roleHash = ethers.utils.keccak256(role); + expect(await acm.hasRole(roleHash, opsepolia.GUARDIAN)).to.be.false; + expect(await acm.hasRole(roleHash, opsepolia.NORMAL_TIMELOCK)).to.be.true; + expect(await acm.hasRole(roleHash, FAST_TRACK_TIMELOCK)).to.be.false; + expect(await acm.hasRole(roleHash, CRITICAL_TIMELOCK)).to.be.false; + }); + }); +}); diff --git a/vips/vip-384/bsctestnet.ts b/vips/vip-384/bsctestnet.ts new file mode 100644 index 000000000..4ce3b649e --- /dev/null +++ b/vips/vip-384/bsctestnet.ts @@ -0,0 +1,64 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +const { opsepolia } = NETWORK_ADDRESSES; +export const OMNICHAIN_PROPOSAL_SENDER = "0xCfD34AEB46b1CB4779c945854d405E91D27A1899"; + +export const OPSEPOLIA_OMNICHAIN_EXECUTOR_OWNER = "0xE92E31df479BC1031B866063F65CF71B6bAC4FC6"; +export const OPSEPOLIA_ACM = "0x1652E12C8ABE2f0D84466F0fc1fA4286491B3BC1"; +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; +export const OPSEPOLIA_ACM_AGGREGATOR = "0xEEeF13364fD22b8eA6932A9ed337e2638f8E0eD6"; +export const MAX_DAILY_LIMIT = 100; + +const vip384 = () => { + const meta = { + version: "v2", + title: "VIP-384 Enable Multichain Governance on op sepolia", + description: `### Summary`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: OMNICHAIN_PROPOSAL_SENDER, + signature: "setMaxDailyLimit(uint16,uint256)", + params: [LzChainId.opsepolia, MAX_DAILY_LIMIT], + }, + { + target: OMNICHAIN_PROPOSAL_SENDER, + signature: "setTrustedRemoteAddress(uint16,bytes)", + params: [LzChainId.opsepolia, opsepolia.OMNICHAIN_GOVERNANCE_EXECUTOR], + }, + { + target: OPSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opsepolia, + }, + { + target: OPSEPOLIA_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPSEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.opsepolia, + }, + { + target: OPSEPOLIA_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.opsepolia, + }, + { + target: OPSEPOLIA_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPSEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.opsepolia, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip384; From 7253fb4f4b74dc56a05f9f8cab3edddf824ff696 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Mon, 21 Oct 2024 17:35:47 +0200 Subject: [PATCH 051/178] feat: set ID and description for VIP 386 --- simulations/vip-386/bscmainnet.ts | 7 ++++ vips/vip-382/bscmainnet.ts | 29 ----------------- vips/vip-386/bscmainnet.ts | 54 +++++++++++++++++++++++++++++++ 3 files changed, 61 insertions(+), 29 deletions(-) create mode 100644 simulations/vip-386/bscmainnet.ts delete mode 100644 vips/vip-382/bscmainnet.ts create mode 100644 vips/vip-386/bscmainnet.ts diff --git a/simulations/vip-386/bscmainnet.ts b/simulations/vip-386/bscmainnet.ts new file mode 100644 index 000000000..5863f1ef2 --- /dev/null +++ b/simulations/vip-386/bscmainnet.ts @@ -0,0 +1,7 @@ +import { forking, testVip } from "src/vip-framework"; + +import vip386 from "../../vips/vip-386/bscmainnet"; + +forking(43314681, async () => { + testVip("VIP-386", await vip386(), {}); +}); diff --git a/vips/vip-382/bscmainnet.ts b/vips/vip-382/bscmainnet.ts deleted file mode 100644 index 704825209..000000000 --- a/vips/vip-382/bscmainnet.ts +++ /dev/null @@ -1,29 +0,0 @@ -import { ProposalType } from "src/types"; -import { makeProposal } from "src/utils"; -import { FAST_TRACK_TIMELOCK } from "src/vip-framework"; - -const vip382 = () => { - const meta = { - version: "v2", - title: "VIP-382 [zkSync] Reduce the distribution speeds of the markets on zkSync", - description: ``, - forDescription: "I agree that Venus Protocol should proceed with this proposal", - againstDescription: "I do not think that Venus Protocol should proceed with this proposal", - abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", - }; - - return makeProposal( - [ - { - target: FAST_TRACK_TIMELOCK, - signature: "", - params: [], - value: "1", - }, - ], - meta, - ProposalType.FAST_TRACK, - ); -}; - -export default vip382; diff --git a/vips/vip-386/bscmainnet.ts b/vips/vip-386/bscmainnet.ts new file mode 100644 index 000000000..5900ec8bd --- /dev/null +++ b/vips/vip-386/bscmainnet.ts @@ -0,0 +1,54 @@ +import { ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; +import { FAST_TRACK_TIMELOCK } from "src/vip-framework"; + +const vip386 = () => { + const meta = { + version: "v2", + title: "VIP-386 [zkSync] XVS rewards on zkSync", + description: `#### Summary + +Following [VIP-369 [zkSync] XVS rewards on zkSync](https://app.venus.io/#/governance/proposal/369), if passed, this VIP will configure the XVS emissions in every market enabled on zkSync Era for the following 3 months (following the proposal [[ZKsync] XVS Incentives Model Proposal](https://community.venus.io/t/zksync-xvs-incentives-model-proposal/4580)). + +#### Description + +According to the proposal [[ZKsync] XVS Incentives Model Proposal](https://community.venus.io/t/zksync-xvs-incentives-model-proposal/4580), the following XVS rewards will be enabled on zkSync Era for the next 90 days: + +- **Market Emissions**: 18,000 XVS allocated as liquidity incentives, for the following markets in the Core pool on zkSync Era: + - WETH: 3,600 XVS + - WBTC: 3,600 XVS + - USDT: 2,700 XVS + - USDC.e: 5,400 XVS + - ZK: 2,700 XVS + - In every case, 80% of the XVS rewards will be for the suppliers and 20% for the borrowers + +#### References + +- [VIP simulation](https://github.com/VenusProtocol/vips/pull/409) +- Snapshot “[[ZKsync] XVS Incentives Model Proposal](https://snapshot.org/#/venus-xvs.eth/proposal/0x646fa7f813e73b6f330b9dcf0e5e88733e8b35ff59736e6ac3c54dcad6fb03d2)” +- Community proposal “[[ZKsync] XVS Incentives Model Proposal](https://community.venus.io/t/zksync-xvs-incentives-model-proposal/4580)” +- [Documentation](https://docs-v4.venus.io/) + +#### Disclaimer for zkSync Era VIPs + +Privilege commands on zkSync Era will be executed by the [Guardian wallet](https://explorer.zksync.io/address/0x751Aa759cfBB6CE71A43b48e40e1cCcFC66Ba4aa), until the [Multichain Governance](https://docs-v4.venus.io/technical-reference/reference-technical-articles/multichain-governance) contracts are fully enabled. If this VIP passes, [this](https://app.safe.global/transactions/tx?safe=zksync:0x751Aa759cfBB6CE71A43b48e40e1cCcFC66Ba4aa&id=multisig_0x751Aa759cfBB6CE71A43b48e40e1cCcFC66Ba4aa_0x51b754d3346c8849b777ce18ebb0ed0527f460dab0fbef1b219fa353def0f0b0) multisig transaction will be executed. Otherwise, it will be rejected.`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + + return makeProposal( + [ + { + target: FAST_TRACK_TIMELOCK, + signature: "", + params: [], + value: "1", + }, + ], + meta, + ProposalType.FAST_TRACK, + ); +}; + +export default vip386; From c247d244db1d23f6df6ba8c10b3e3264b6d44985 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Tue, 22 Oct 2024 13:11:10 +0530 Subject: [PATCH 052/178] refactor: update the vip number for the bsctestnet --- .../abi/ACMAggregator.json | 0 .../abi/AccessControlManager_ABI.json | 0 .../abi/OmnichainExecutorOwner_ABI.json | 0 .../abi/OmnichainGovernanceExecutor_ABI.json | 0 .../abi/OmnichainProposalSender.json | 0 .../{vip-384 => vip-387}/bsctestnet.ts | 4 +- simulations/{vip-384 => vip-387}/opsepolia.ts | 20 +++--- src/networkAddresses.ts | 2 +- src/types.ts | 12 ++-- vips/vip-387/bsctestnet.ts | 64 +++++++++++++++++++ 10 files changed, 85 insertions(+), 17 deletions(-) rename simulations/{vip-384 => vip-387}/abi/ACMAggregator.json (100%) rename simulations/{vip-384 => vip-387}/abi/AccessControlManager_ABI.json (100%) rename simulations/{vip-384 => vip-387}/abi/OmnichainExecutorOwner_ABI.json (100%) rename simulations/{vip-384 => vip-387}/abi/OmnichainGovernanceExecutor_ABI.json (100%) rename simulations/{vip-384 => vip-387}/abi/OmnichainProposalSender.json (100%) rename simulations/{vip-384 => vip-387}/bsctestnet.ts (92%) rename simulations/{vip-384 => vip-387}/opsepolia.ts (91%) create mode 100644 vips/vip-387/bsctestnet.ts diff --git a/simulations/vip-384/abi/ACMAggregator.json b/simulations/vip-387/abi/ACMAggregator.json similarity index 100% rename from simulations/vip-384/abi/ACMAggregator.json rename to simulations/vip-387/abi/ACMAggregator.json diff --git a/simulations/vip-384/abi/AccessControlManager_ABI.json b/simulations/vip-387/abi/AccessControlManager_ABI.json similarity index 100% rename from simulations/vip-384/abi/AccessControlManager_ABI.json rename to simulations/vip-387/abi/AccessControlManager_ABI.json diff --git a/simulations/vip-384/abi/OmnichainExecutorOwner_ABI.json b/simulations/vip-387/abi/OmnichainExecutorOwner_ABI.json similarity index 100% rename from simulations/vip-384/abi/OmnichainExecutorOwner_ABI.json rename to simulations/vip-387/abi/OmnichainExecutorOwner_ABI.json diff --git a/simulations/vip-384/abi/OmnichainGovernanceExecutor_ABI.json b/simulations/vip-387/abi/OmnichainGovernanceExecutor_ABI.json similarity index 100% rename from simulations/vip-384/abi/OmnichainGovernanceExecutor_ABI.json rename to simulations/vip-387/abi/OmnichainGovernanceExecutor_ABI.json diff --git a/simulations/vip-384/abi/OmnichainProposalSender.json b/simulations/vip-387/abi/OmnichainProposalSender.json similarity index 100% rename from simulations/vip-384/abi/OmnichainProposalSender.json rename to simulations/vip-387/abi/OmnichainProposalSender.json diff --git a/simulations/vip-384/bsctestnet.ts b/simulations/vip-387/bsctestnet.ts similarity index 92% rename from simulations/vip-384/bsctestnet.ts rename to simulations/vip-387/bsctestnet.ts index c479a82de..550586615 100644 --- a/simulations/vip-384/bsctestnet.ts +++ b/simulations/vip-387/bsctestnet.ts @@ -5,7 +5,7 @@ import { LzChainId } from "src/types"; import { expectEvents } from "src/utils"; import { forking, testVip } from "src/vip-framework"; -import vip384, { MAX_DAILY_LIMIT, OMNICHAIN_PROPOSAL_SENDER } from "../../vips/vip-384/bsctestnet"; +import vip387, { MAX_DAILY_LIMIT, OMNICHAIN_PROPOSAL_SENDER } from "../../vips/vip-387/bsctestnet"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; @@ -27,7 +27,7 @@ forking(44927774, async () => { }); }); - testVip("vip384 give permissions to timelock", await vip384(), { + testVip("vip387 give permissions to timelock", await vip387(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-384/opsepolia.ts b/simulations/vip-387/opsepolia.ts similarity index 91% rename from simulations/vip-384/opsepolia.ts rename to simulations/vip-387/opsepolia.ts index a7dca781b..0c3835d66 100644 --- a/simulations/vip-384/opsepolia.ts +++ b/simulations/vip-387/opsepolia.ts @@ -6,23 +6,23 @@ import { LzChainId } from "src/types"; import { expectEvents, getOmnichainProposalSenderAddress } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip010 from "../../multisig/proposals/opsepolia/vip-007"; -import vip365, { +import vip007 from "../../multisig/proposals/opsepolia/vip-007"; +import vip387, { DEFAULT_ADMIN_ROLE, OPSEPOLIA_ACM, OPSEPOLIA_ACM_AGGREGATOR, OPSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, -} from "../../vips/vip-384/bsctestnet"; +} from "../../vips/vip-387/bsctestnet"; import ACMAggregator_ABI from "./abi/ACMAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_EXECUTOR_OWNER_ABI from "./abi/OmnichainExecutorOwner_ABI.json"; import OMNICHAIN_GOVERNANCE_EXECUTOR_ABI from "./abi/OmnichainGovernanceExecutor_ABI.json"; const { opsepolia } = NETWORK_ADDRESSES; -const FAST_TRACK_TIMELOCK = "0xb055e028b27d53a455a6c040a6952e44E9E615c4"; -const CRITICAL_TIMELOCK = "0x0E6138bE0FA1915efC73670a20A10EFd720a6Cc8"; +const FAST_TRACK_TIMELOCK = "0xe0Fa35b6279dd802C382ae54c50C8B16deaC0885"; +const CRITICAL_TIMELOCK = "0x45d2263c6E0dbF84eBffB1Ee0b80aC740607990B"; -forking(18850742, async () => { +forking(18889503, async () => { const provider = ethers.provider; let lastProposalReceived: BigNumber; let executor: Contract; @@ -36,18 +36,18 @@ forking(18850742, async () => { ); executorOwner = new ethers.Contract(OPSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, OMNICHAIN_EXECUTOR_OWNER_ABI, provider); lastProposalReceived = await executor.lastProposalReceived(); - await pretendExecutingVip(await vip010()); + await pretendExecutingVip(await vip007()); }); describe("Pre-VIP behaviour", async () => { - it("Normal Timelock has default admin role on ZKsync sepolia", async () => { + it("Normal Timelock has default admin role on OP sepolia", async () => { const acm = await ethers.getContractAt(ACCESS_CONTROL_MANAGER_ABI, OPSEPOLIA_ACM); const hasRole = await acm.hasRole(DEFAULT_ADMIN_ROLE, opsepolia.NORMAL_TIMELOCK); expect(hasRole).equals(true); }); }); - testForkedNetworkVipCommands("vip365 configures bridge", await vip365(), { + testForkedNetworkVipCommands("vip387 configures bridge", await vip387(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [39]); await expectEvents(txResponse, [ACMAggregator_ABI], ["GrantPermissionsExecuted"], [1]); @@ -110,7 +110,7 @@ forking(18850742, async () => { expect(await executorOwner.functionRegistry(selector)).equals(signature); } }); - it("Default admin role must be revoked from ACMAggregator contract on ZKsync sepolia", async () => { + it("Default admin role must be revoked from ACMAggregator contract on OP sepolia", async () => { expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPSEPOLIA_ACM_AGGREGATOR)).to.be.false; }); it("Guardian and all timelocks are allowed to call retryMessage ", async () => { diff --git a/src/networkAddresses.ts b/src/networkAddresses.ts index 0c52fb22f..7fa455a9d 100644 --- a/src/networkAddresses.ts +++ b/src/networkAddresses.ts @@ -196,7 +196,7 @@ export const NETWORK_ADDRESSES = { CHAINLINK_ORACLE: "0x493C3f543AEa37EefF17D823f27Cb1feAB9f3143", POOL_REGISTRY: "0x6538C861C7A6997602311342657b9143dD9E8152", ENDPOINT: "0x55370E0fBB5f5b8dAeD978BA1c075a499eB107B8", - LZ_LIBRARY: "0xC6d12200b743A8F7e6b7228B8E920A71d94FA7Fb", + LZ_LIBRARY: "0x35AdD9321507A87471a11EBd4aE4f592d531e620", OMNICHAIN_GOVERNANCE_EXECUTOR: "0xC7D6D33adcdBfccD416C3aAB1878360ea8b79ac6", }, opmainnet: { diff --git a/src/types.ts b/src/types.ts index 0e50a3aff..288dabf3d 100644 --- a/src/types.ts +++ b/src/types.ts @@ -7,7 +7,9 @@ export type SUPPORTED_NETWORKS = | "ethereum" | "opbnbtestnet" | "opbnbmainnet" - | "zksyncsepolia"; + | "zksyncsepolia" + | "opsepolia" + | "opmainnet"; export type REMOTE_NETWORKS = | "sepolia" @@ -15,10 +17,12 @@ export type REMOTE_NETWORKS = | "opbnbtestnet" | "opbnbmainnet" | "arbitrumsepolia" - | "arbitrumone"; + | "arbitrumone" + | "opsepolia" + | "opmainnet"; -export const REMOTE_TESTNET_NETWORKS = ["sepolia", "opbnbtestnet", "arbitrumsepolia", "zksyncsepolia"]; -export const REMOTE_MAINNET_NETWORKS = ["ethereum", "opbnbmainnet", "arbitrumone", "zksyncmainnet"]; +export const REMOTE_TESTNET_NETWORKS = ["sepolia", "opbnbtestnet", "arbitrumsepolia", "zksyncsepolia", "opsepolia"]; +export const REMOTE_MAINNET_NETWORKS = ["ethereum", "opbnbmainnet", "arbitrumone", "zksyncmainnet", "opmainnet"]; export interface ProposalMeta { version: string; title: string; diff --git a/vips/vip-387/bsctestnet.ts b/vips/vip-387/bsctestnet.ts new file mode 100644 index 000000000..a6fecb028 --- /dev/null +++ b/vips/vip-387/bsctestnet.ts @@ -0,0 +1,64 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +const { opsepolia } = NETWORK_ADDRESSES; +export const OMNICHAIN_PROPOSAL_SENDER = "0xCfD34AEB46b1CB4779c945854d405E91D27A1899"; + +export const OPSEPOLIA_OMNICHAIN_EXECUTOR_OWNER = "0xE92E31df479BC1031B866063F65CF71B6bAC4FC6"; +export const OPSEPOLIA_ACM = "0x1652E12C8ABE2f0D84466F0fc1fA4286491B3BC1"; +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; +export const OPSEPOLIA_ACM_AGGREGATOR = "0xEEeF13364fD22b8eA6932A9ed337e2638f8E0eD6"; +export const MAX_DAILY_LIMIT = 100; + +const vip387 = () => { + const meta = { + version: "v2", + title: "VIP-387 Enable Multichain Governance on op sepolia", + description: `### Summary`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: OMNICHAIN_PROPOSAL_SENDER, + signature: "setMaxDailyLimit(uint16,uint256)", + params: [LzChainId.opsepolia, MAX_DAILY_LIMIT], + }, + { + target: OMNICHAIN_PROPOSAL_SENDER, + signature: "setTrustedRemoteAddress(uint16,bytes)", + params: [LzChainId.opsepolia, opsepolia.OMNICHAIN_GOVERNANCE_EXECUTOR], + }, + { + target: OPSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opsepolia, + }, + { + target: OPSEPOLIA_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPSEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.opsepolia, + }, + { + target: OPSEPOLIA_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.opsepolia, + }, + { + target: OPSEPOLIA_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPSEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.opsepolia, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip387; From 80d3955f1ba9ca4cb2d3ef7c3ef35635fe5eb4ab Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Tue, 22 Oct 2024 13:14:36 +0530 Subject: [PATCH 053/178] refactor: update vip number for the multichain governance for opsepolia --- vips/vip-384/bsctestnet.ts | 64 -------------------------------------- 1 file changed, 64 deletions(-) delete mode 100644 vips/vip-384/bsctestnet.ts diff --git a/vips/vip-384/bsctestnet.ts b/vips/vip-384/bsctestnet.ts deleted file mode 100644 index 4ce3b649e..000000000 --- a/vips/vip-384/bsctestnet.ts +++ /dev/null @@ -1,64 +0,0 @@ -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { LzChainId, ProposalType } from "src/types"; -import { makeProposal } from "src/utils"; - -const { opsepolia } = NETWORK_ADDRESSES; -export const OMNICHAIN_PROPOSAL_SENDER = "0xCfD34AEB46b1CB4779c945854d405E91D27A1899"; - -export const OPSEPOLIA_OMNICHAIN_EXECUTOR_OWNER = "0xE92E31df479BC1031B866063F65CF71B6bAC4FC6"; -export const OPSEPOLIA_ACM = "0x1652E12C8ABE2f0D84466F0fc1fA4286491B3BC1"; -export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; -export const OPSEPOLIA_ACM_AGGREGATOR = "0xEEeF13364fD22b8eA6932A9ed337e2638f8E0eD6"; -export const MAX_DAILY_LIMIT = 100; - -const vip384 = () => { - const meta = { - version: "v2", - title: "VIP-384 Enable Multichain Governance on op sepolia", - description: `### Summary`, - forDescription: "I agree that Venus Protocol should proceed with this proposal", - againstDescription: "I do not think that Venus Protocol should proceed with this proposal", - abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", - }; - return makeProposal( - [ - { - target: OMNICHAIN_PROPOSAL_SENDER, - signature: "setMaxDailyLimit(uint16,uint256)", - params: [LzChainId.opsepolia, MAX_DAILY_LIMIT], - }, - { - target: OMNICHAIN_PROPOSAL_SENDER, - signature: "setTrustedRemoteAddress(uint16,bytes)", - params: [LzChainId.opsepolia, opsepolia.OMNICHAIN_GOVERNANCE_EXECUTOR], - }, - { - target: OPSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opsepolia, - }, - { - target: OPSEPOLIA_ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, OPSEPOLIA_ACM_AGGREGATOR], - dstChainId: LzChainId.opsepolia, - }, - { - target: OPSEPOLIA_ACM_AGGREGATOR, - signature: "executeGrantPermissions(uint256)", - params: [0], - dstChainId: LzChainId.opsepolia, - }, - { - target: OPSEPOLIA_ACM, - signature: "revokeRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, OPSEPOLIA_ACM_AGGREGATOR], - dstChainId: LzChainId.opsepolia, - }, - ], - meta, - ProposalType.REGULAR, - ); -}; -export default vip384; From 311a65b315d425d36309a1e42304d89fbb3c14b8 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Tue, 22 Oct 2024 16:01:39 +0530 Subject: [PATCH 054/178] fixup: lint issues --- src/types.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/types.ts b/src/types.ts index 288dabf3d..e0462d293 100644 --- a/src/types.ts +++ b/src/types.ts @@ -18,8 +18,7 @@ export type REMOTE_NETWORKS = | "opbnbmainnet" | "arbitrumsepolia" | "arbitrumone" - | "opsepolia" - | "opmainnet"; + | "opsepolia"; export const REMOTE_TESTNET_NETWORKS = ["sepolia", "opbnbtestnet", "arbitrumsepolia", "zksyncsepolia", "opsepolia"]; export const REMOTE_MAINNET_NETWORKS = ["ethereum", "opbnbmainnet", "arbitrumone", "zksyncmainnet", "opmainnet"]; From d392efdc46cac8e921c1e9bf53f32ef9bffecf6c Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Mon, 7 Oct 2024 23:58:43 +0300 Subject: [PATCH 055/178] feat(framework): add risk parameters checks for legacy pool --- .../checks/checkRiskParameters.ts | 136 +++++++++++------- 1 file changed, 85 insertions(+), 51 deletions(-) diff --git a/src/vip-framework/checks/checkRiskParameters.ts b/src/vip-framework/checks/checkRiskParameters.ts index 29bb800e9..2000d6ede 100644 --- a/src/vip-framework/checks/checkRiskParameters.ts +++ b/src/vip-framework/checks/checkRiskParameters.ts @@ -3,7 +3,8 @@ import { BigNumber, Contract } from "ethers"; import { formatUnits, parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; -import COMPTROLLER_ABI from "../abi/il_comptroller.json"; +import LEGACY_POOL_COMPTROLLER_ABI from "../abi/comptroller.json"; +import IL_COMPTROLLER_ABI from "../abi/il_comptroller.json"; import VTOKEN_ABI from "../abi/il_vToken.json"; import { TokenSpec } from "./checkVToken"; @@ -16,6 +17,13 @@ export type RiskParameters = { protocolSeizeShare: string | BigNumber; }; +export type LegacyPoolRiskParameters = { + borrowCap: string | BigNumber; + supplyCap: string | BigNumber; + collateralFactor: string | BigNumber; + reserveFactor: string | BigNumber; +}; + const parseIfNeeded = (value: string | BigNumber, decimals: number) => { if (typeof value === "string") { return parseUnits(value, decimals); @@ -30,60 +38,86 @@ const formatIfNeeded = (value: string | BigNumber, decimals: number) => { return formatUnits(value, decimals); }; -export function checkRiskParameters( +const checkCommonRiskParameters = ( + vTokenAddress: string, + spec: { underlying: TokenSpec; comptroller?: string; symbol?: string }, + riskParameters: RiskParameters | LegacyPoolRiskParameters, +) => { + const vToken = new ethers.Contract(vTokenAddress, VTOKEN_ABI, ethers.provider); + let comptroller: Contract; + + before(async () => { + const comptrollerAddress = spec.comptroller ?? (await vToken.comptroller()); + comptroller = new ethers.Contract(comptrollerAddress, LEGACY_POOL_COMPTROLLER_ABI, ethers.provider); + }); + + it(`should set ${spec.symbol} reserve factor to ${formatIfNeeded(riskParameters.reserveFactor, 18)}`, async () => { + expect(await vToken.reserveFactorMantissa()).to.equal(parseIfNeeded(riskParameters.reserveFactor, 18)); + }); + + it(`should set ${spec.symbol} collateral factor to ${formatIfNeeded( + riskParameters.collateralFactor, + 18, + )}`, async () => { + const market = await comptroller.markets(vToken.address); + expect(market.collateralFactorMantissa).to.equal(parseIfNeeded(riskParameters.collateralFactor, 18)); + }); + + it(`should set ${spec.symbol} supply cap to ${formatIfNeeded( + riskParameters.supplyCap, + spec.underlying.decimals, + )}`, async () => { + expect(await comptroller.supplyCaps(vToken.address)).to.equal( + parseIfNeeded(riskParameters.supplyCap, spec.underlying.decimals), + ); + }); + + it(`should set ${spec.symbol} borrow cap to ${formatIfNeeded( + riskParameters.borrowCap, + spec.underlying.decimals, + )}`, async () => { + expect(await comptroller.borrowCaps(vToken.address)).to.equal( + parseIfNeeded(riskParameters.borrowCap, spec.underlying.decimals), + ); + }); +}; + +const checkILRiskParameters = ( vTokenAddress: string, spec: { underlying: TokenSpec; comptroller?: string; symbol?: string }, riskParameters: RiskParameters, +) => { + const vToken = new ethers.Contract(vTokenAddress, VTOKEN_ABI, ethers.provider); + let comptroller: Contract; + + before(async () => { + const comptrollerAddress = spec.comptroller ?? (await vToken.comptroller()); + comptroller = new ethers.Contract(comptrollerAddress, IL_COMPTROLLER_ABI, ethers.provider); + }); + + it(`should set ${spec.symbol} liquidation threshold to ${formatIfNeeded( + riskParameters.liquidationThreshold, + 18, + )}`, async () => { + const market = await comptroller.markets(vToken.address); + expect(market.liquidationThresholdMantissa).to.equal(parseIfNeeded(riskParameters.liquidationThreshold, 18)); + }); + + it(`should set ${spec.symbol} protocol seize share to ${riskParameters.protocolSeizeShare}`, async () => { + expect(await vToken.protocolSeizeShareMantissa()).to.equal(parseIfNeeded(riskParameters.protocolSeizeShare, 18)); + }); +}; + +export function checkRiskParameters( + vTokenAddress: string, + spec: { underlying: TokenSpec; comptroller?: string; symbol?: string; isLegacyPool?: boolean }, + riskParameters: RiskParameters | LegacyPoolRiskParameters, ) { describe(`${spec.symbol ?? vTokenAddress} risk parameters`, () => { - let vToken: Contract; - let comptroller: Contract; - - before(async () => { - vToken = await ethers.getContractAt(VTOKEN_ABI, vTokenAddress); - comptroller = await ethers.getContractAt(COMPTROLLER_ABI, spec.comptroller ?? (await vToken.comptroller())); - }); - - it(`should set ${spec.symbol} reserve factor to ${formatIfNeeded(riskParameters.reserveFactor, 18)}`, async () => { - expect(await vToken.reserveFactorMantissa()).to.equal(parseIfNeeded(riskParameters.reserveFactor, 18)); - }); - - it(`should set ${spec.symbol} collateral factor to ${formatIfNeeded( - riskParameters.collateralFactor, - 18, - )}`, async () => { - const market = await comptroller.markets(vTokenAddress); - expect(market.collateralFactorMantissa).to.equal(parseIfNeeded(riskParameters.collateralFactor, 18)); - }); - - it(`should set ${spec.symbol} liquidation threshold to ${formatIfNeeded( - riskParameters.liquidationThreshold, - 18, - )}`, async () => { - const market = await comptroller.markets(vTokenAddress); - expect(market.liquidationThresholdMantissa).to.equal(parseIfNeeded(riskParameters.liquidationThreshold, 18)); - }); - - it(`should set ${spec.symbol} protocol seize share to ${riskParameters.protocolSeizeShare}`, async () => { - expect(await vToken.protocolSeizeShareMantissa()).to.equal(parseIfNeeded(riskParameters.protocolSeizeShare, 18)); - }); - - it(`should set ${spec.symbol} supply cap to ${formatIfNeeded( - riskParameters.supplyCap, - spec.underlying.decimals, - )}`, async () => { - expect(await comptroller.supplyCaps(vTokenAddress)).to.equal( - parseIfNeeded(riskParameters.supplyCap, spec.underlying.decimals), - ); - }); - - it(`should set ${spec.symbol} borrow cap to ${formatIfNeeded( - riskParameters.borrowCap, - spec.underlying.decimals, - )}`, async () => { - expect(await comptroller.borrowCaps(vTokenAddress)).to.equal( - parseIfNeeded(riskParameters.borrowCap, spec.underlying.decimals), - ); - }); + checkCommonRiskParameters(vTokenAddress, spec, riskParameters); + + if (!spec.isLegacyPool) { + checkILRiskParameters(vTokenAddress, spec, riskParameters as RiskParameters); + } }); } From be0c1e8edea39df8ba0ce4fdbb4d00ab77bb3693 Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Mon, 7 Oct 2024 23:59:08 +0300 Subject: [PATCH 056/178] feat: add SolvBTC market --- simulations/vip-400/abi/ERC20.json | 295 ++ .../vip-400/abi/LegacyPoolComptroller.json | 3238 +++++++++++++++++ simulations/vip-400/abi/LegacyPoolVToken.json | 1747 +++++++++ simulations/vip-400/abi/ResilientOracle.json | 750 ++++ .../vip-400/abi/SingleTokenConverter.json | 1267 +++++++ simulations/vip-400/bscmainnet.ts | 111 + simulations/vip-400/bsctestnet.ts | 95 + vips/vip-400/bscmainnet.ts | 199 + vips/vip-400/bsctestnet.ts | 197 + 9 files changed, 7899 insertions(+) create mode 100644 simulations/vip-400/abi/ERC20.json create mode 100644 simulations/vip-400/abi/LegacyPoolComptroller.json create mode 100644 simulations/vip-400/abi/LegacyPoolVToken.json create mode 100644 simulations/vip-400/abi/ResilientOracle.json create mode 100644 simulations/vip-400/abi/SingleTokenConverter.json create mode 100644 simulations/vip-400/bscmainnet.ts create mode 100644 simulations/vip-400/bsctestnet.ts create mode 100644 vips/vip-400/bscmainnet.ts create mode 100644 vips/vip-400/bsctestnet.ts diff --git a/simulations/vip-400/abi/ERC20.json b/simulations/vip-400/abi/ERC20.json new file mode 100644 index 000000000..374b04c75 --- /dev/null +++ b/simulations/vip-400/abi/ERC20.json @@ -0,0 +1,295 @@ +[ + { + "inputs": [ + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "userAddress", "type": "address" }, + { "indexed": false, "internalType": "address payable", "name": "relayerAddress", "type": "address" }, + { "indexed": false, "internalType": "bytes", "name": "functionSignature", "type": "bytes" } + ], + "name": "MetaTransactionExecuted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } + ], + "name": "RoleAdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_ADMIN_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "ERC712_VERSION", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "PREDICATE_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "userAddress", "type": "address" }, + { "internalType": "bytes", "name": "functionSignature", "type": "bytes" }, + { "internalType": "bytes32", "name": "sigR", "type": "bytes32" }, + { "internalType": "bytes32", "name": "sigS", "type": "bytes32" }, + { "internalType": "uint8", "name": "sigV", "type": "uint8" } + ], + "name": "executeMetaTransaction", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [], + "name": "getChainId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [], + "name": "getDomainSeperator", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "getNonce", + "outputs": [{ "internalType": "uint256", "name": "nonce", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleAdmin", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "uint256", "name": "index", "type": "uint256" } + ], + "name": "getRoleMember", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleMemberCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "grantRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "hasRole", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "renounceRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "revokeRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-400/abi/LegacyPoolComptroller.json b/simulations/vip-400/abi/LegacyPoolComptroller.json new file mode 100644 index 000000000..23a10fc08 --- /dev/null +++ b/simulations/vip-400/abi/LegacyPoolComptroller.json @@ -0,0 +1,3238 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "enum ComptrollerTypes.Action", + "name": "action", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "bool", + "name": "pauseState", + "type": "bool" + } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "bool", + "name": "state", + "type": "bool" + } + ], + "name": "ActionProtocolPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "approver", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "delegate", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "approved", + "type": "bool" + } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "facetAddress", + "type": "address" + }, + { + "internalType": "enum IDiamondCut.FacetCutAction", + "name": "action", + "type": "uint8" + }, + { + "internalType": "bytes4[]", + "name": "functionSelectors", + "type": "bytes4[]" + } + ], + "indexed": false, + "internalType": "struct IDiamondCut.FacetCut[]", + "name": "_diamondCut", + "type": "tuple[]" + } + ], + "name": "DiamondCut", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "venusDelta", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "venusBorrowIndex", + "type": "uint256" + } + ], + "name": "DistributedBorrowerVenus", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "supplier", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "venusDelta", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "venusSupplyIndex", + "type": "uint256" + } + ], + "name": "DistributedSupplierVenus", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "DistributedVAIVaultVenus", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "info", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "detail", + "type": "uint256" + } + ], + "name": "Failure", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "IsForcedLiquidationEnabledForUserUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "MarketListed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "MarketUnlisted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlAddress", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlAddress", + "type": "address" + } + ], + "name": "NewAccessControl", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newBorrowCap", + "type": "uint256" + } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldCloseFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldCollateralFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldComptrollerLens", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newComptrollerLens", + "type": "address" + } + ], + "name": "NewComptrollerLens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationIncentiveMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldLiquidatorContract", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newLiquidatorContract", + "type": "address" + } + ], + "name": "NewLiquidatorContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldPauseGuardian", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newPauseGuardian", + "type": "address" + } + ], + "name": "NewPauseGuardian", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract IPrime", + "name": "oldPrimeToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract IPrime", + "name": "newPrimeToken", + "type": "address" + } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSupplyCap", + "type": "uint256" + } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldTreasuryAddress", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newTreasuryAddress", + "type": "address" + } + ], + "name": "NewTreasuryAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldTreasuryGuardian", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newTreasuryGuardian", + "type": "address" + } + ], + "name": "NewTreasuryGuardian", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldTreasuryPercent", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newTreasuryPercent", + "type": "uint256" + } + ], + "name": "NewTreasuryPercent", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VAIControllerInterface", + "name": "oldVAIController", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract VAIControllerInterface", + "name": "newVAIController", + "type": "address" + } + ], + "name": "NewVAIController", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldVAIMintRate", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newVAIMintRate", + "type": "uint256" + } + ], + "name": "NewVAIMintRate", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "vault_", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "releaseStartBlock_", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "releaseInterval_", + "type": "uint256" + } + ], + "name": "NewVAIVaultInfo", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldVenusVAIVaultRate", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newVenusVAIVaultRate", + "type": "uint256" + } + ], + "name": "NewVenusVAIVaultRate", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldXVS", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newXVS", + "type": "address" + } + ], + "name": "NewXVSToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldXVSVToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newXVSVToken", + "type": "address" + } + ], + "name": "NewXVSVToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSpeed", + "type": "uint256" + } + ], + "name": "VenusBorrowSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "recipient", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "VenusGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "holder", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "VenusSeized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSpeed", + "type": "uint256" + } + ], + "name": "VenusSupplySpeedUpdated", + "type": "event" + }, + { + "payable": true, + "stateMutability": "payable", + "type": "fallback" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract Unitroller", + "name": "unitroller", + "type": "address" + } + ], + "name": "_become", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "recipient", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "_grantXVS", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "newAccessControlAddress", + "type": "address" + } + ], + "name": "_setAccessControl", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address[]", + "name": "markets_", + "type": "address[]" + }, + { + "internalType": "enum ComptrollerTypes.Action[]", + "name": "actions_", + "type": "uint8[]" + }, + { + "internalType": "bool", + "name": "paused_", + "type": "bool" + } + ], + "name": "_setActionsPaused", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "_setCloseFactor", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + } + ], + "name": "_setCollateralFactor", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract ComptrollerLensInterface", + "name": "comptrollerLens_", + "type": "address" + } + ], + "name": "_setComptrollerLens", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "_setForcedLiquidation", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "_setForcedLiquidationForUser", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "_setLiquidationIncentive", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "newLiquidatorContract_", + "type": "address" + } + ], + "name": "_setLiquidatorContract", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newBorrowCaps", + "type": "uint256[]" + } + ], + "name": "_setMarketBorrowCaps", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newSupplyCaps", + "type": "uint256[]" + } + ], + "name": "_setMarketSupplyCaps", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "newPauseGuardian", + "type": "address" + } + ], + "name": "_setPauseGuardian", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract PriceOracle", + "name": "newOracle", + "type": "address" + } + ], + "name": "_setPriceOracle", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract IPrime", + "name": "_prime", + "type": "address" + } + ], + "name": "_setPrimeToken", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "bool", + "name": "state", + "type": "bool" + } + ], + "name": "_setProtocolPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "newTreasuryGuardian", + "type": "address" + }, + { + "internalType": "address", + "name": "newTreasuryAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "newTreasuryPercent", + "type": "uint256" + } + ], + "name": "_setTreasuryData", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract VAIControllerInterface", + "name": "vaiController_", + "type": "address" + } + ], + "name": "_setVAIController", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "newVAIMintRate", + "type": "uint256" + } + ], + "name": "_setVAIMintRate", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vault_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "releaseStartBlock_", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "minReleaseAmount_", + "type": "uint256" + } + ], + "name": "_setVAIVaultInfo", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "supplySpeeds", + "type": "uint256[]" + }, + { + "internalType": "uint256[]", + "name": "borrowSpeeds", + "type": "uint256[]" + } + ], + "name": "_setVenusSpeeds", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "venusVAIVaultRate_", + "type": "uint256" + } + ], + "name": "_setVenusVAIVaultRate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "xvs_", + "type": "address" + } + ], + "name": "_setXVSToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "xvsVToken_", + "type": "address" + } + ], + "name": "_setXVSVToken", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "_supportMarket", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "accountAssets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerTypes.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "actionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "allMarkets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "approvedDelegates", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "borrowAllowed", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "borrowCapGuardian", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "borrowCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "borrowVerify", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "checkMembership", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address[]", + "name": "holders", + "type": "address[]" + }, + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "bool", + "name": "borrowers", + "type": "bool" + }, + { + "internalType": "bool", + "name": "suppliers", + "type": "bool" + }, + { + "internalType": "bool", + "name": "collateral", + "type": "bool" + } + ], + "name": "claimVenus", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "holder", + "type": "address" + }, + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + } + ], + "name": "claimVenus", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "holder", + "type": "address" + } + ], + "name": "claimVenus", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address[]", + "name": "holders", + "type": "address[]" + }, + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "bool", + "name": "borrowers", + "type": "bool" + }, + { + "internalType": "bool", + "name": "suppliers", + "type": "bool" + } + ], + "name": "claimVenus", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "holder", + "type": "address" + } + ], + "name": "claimVenusAsCollateral", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "comptrollerImplementation", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "comptrollerLens", + "outputs": [ + { + "internalType": "contract ComptrollerLensInterface", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "facetAddress", + "type": "address" + }, + { + "internalType": "enum IDiamondCut.FacetCutAction", + "name": "action", + "type": "uint8" + }, + { + "internalType": "bytes4[]", + "name": "functionSelectors", + "type": "bytes4[]" + } + ], + "internalType": "struct IDiamondCut.FacetCut[]", + "name": "diamondCut_", + "type": "tuple[]" + } + ], + "name": "diamondCut", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address[]", + "name": "vTokens", + "type": "address[]" + } + ], + "name": "enterMarkets", + "outputs": [ + { + "internalType": "uint256[]", + "name": "", + "type": "uint256[]" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vTokenAddress", + "type": "address" + } + ], + "name": "exitMarket", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "bytes4", + "name": "functionSelector", + "type": "bytes4" + } + ], + "name": "facetAddress", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "facetAddress", + "type": "address" + }, + { + "internalType": "uint96", + "name": "functionSelectorPosition", + "type": "uint96" + } + ], + "internalType": "struct ComptrollerV13Storage.FacetAddressAndPosition", + "name": "", + "type": "tuple" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "facetAddresses", + "outputs": [ + { + "internalType": "address[]", + "name": "", + "type": "address[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "facet", + "type": "address" + } + ], + "name": "facetFunctionSelectors", + "outputs": [ + { + "internalType": "bytes4[]", + "name": "", + "type": "bytes4[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "facet", + "type": "address" + } + ], + "name": "facetPosition", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "facets", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "facetAddress", + "type": "address" + }, + { + "internalType": "bytes4[]", + "name": "functionSelectors", + "type": "bytes4[]" + } + ], + "internalType": "struct Diamond.Facet[]", + "name": "", + "type": "tuple[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getAllMarkets", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAssetsIn", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenModify", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getXVSAddress", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getXVSVTokenAddress", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isComptroller", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "pure", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "isForcedLiquidationEnabled", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "isForcedLiquidationEnabledForUser", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "name": "liquidateBorrowAllowed", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "seizeTokens", + "type": "uint256" + } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + } + ], + "name": "liquidateVAICalculateSeizeTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "liquidatorContract", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "markets", + "outputs": [ + { + "internalType": "bool", + "name": "isListed", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "collateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "isVenus", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "maxAssets", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "minReleaseAmount", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "mintAllowed", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "mintVAIGuardianPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualMintAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "mintTokens", + "type": "uint256" + } + ], + "name": "mintVerify", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "mintedVAIs", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "oracle", + "outputs": [ + { + "internalType": "contract PriceOracle", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pauseGuardian", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingComptrollerImplementation", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "prime", + "outputs": [ + { + "internalType": "contract IPrime", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "protocolPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "redeemAllowed", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "redeemVerify", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "releaseStartBlock", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "payer", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "name": "repayBorrowAllowed", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "payer", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowerIndex", + "type": "uint256" + } + ], + "name": "repayBorrowVerify", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "repayVAIGuardianPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "seizeTokens", + "type": "uint256" + } + ], + "name": "seizeAllowed", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address[]", + "name": "holders", + "type": "address[]" + }, + { + "internalType": "address", + "name": "recipient", + "type": "address" + } + ], + "name": "seizeVenus", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "seizeTokens", + "type": "uint256" + } + ], + "name": "seizeVerify", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "setMintedVAIOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "supplyCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "transferTokens", + "type": "uint256" + } + ], + "name": "transferAllowed", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "transferTokens", + "type": "uint256" + } + ], + "name": "transferVerify", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "treasuryAddress", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "treasuryGuardian", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "treasuryPercent", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "unlistMarket", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "delegate", + "type": "address" + }, + { + "internalType": "bool", + "name": "approved", + "type": "bool" + } + ], + "name": "updateDelegate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "vaiController", + "outputs": [ + { + "internalType": "contract VAIControllerInterface", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "vaiMintRate", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "vaiVaultAddress", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "venusAccrued", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "venusBorrowSpeeds", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "venusBorrowState", + "outputs": [ + { + "internalType": "uint224", + "name": "index", + "type": "uint224" + }, + { + "internalType": "uint32", + "name": "block", + "type": "uint32" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "venusBorrowerIndex", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "venusInitialIndex", + "outputs": [ + { + "internalType": "uint224", + "name": "", + "type": "uint224" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "venusSupplierIndex", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "venusSupplySpeeds", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "venusSupplyState", + "outputs": [ + { + "internalType": "uint224", + "name": "index", + "type": "uint224" + }, + { + "internalType": "uint32", + "name": "block", + "type": "uint32" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "venusVAIVaultRate", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-400/abi/LegacyPoolVToken.json b/simulations/vip-400/abi/LegacyPoolVToken.json new file mode 100644 index 000000000..61a618463 --- /dev/null +++ b/simulations/vip-400/abi/LegacyPoolVToken.json @@ -0,0 +1,1747 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "cashPrior", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "interestAccumulated", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "borrowIndex", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "totalBorrows", + "type": "uint256" + } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "accountBorrows", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "totalBorrows", + "type": "uint256" + } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "info", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "detail", + "type": "uint256" + } + ], + "name": "Failure", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "seizeTokens", + "type": "uint256" + } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "mintTokens", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "totalSupply", + "type": "uint256" + } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "payer", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "mintTokens", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "totalSupply", + "type": "uint256" + } + ], + "name": "MintBehalf", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlAddress", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlAddress", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAdmin", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAdmin", + "type": "address" + } + ], + "name": "NewAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ComptrollerInterface", + "name": "oldComptroller", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ComptrollerInterface", + "name": "newComptroller", + "type": "address" + } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldPendingAdmin", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newPendingAdmin", + "type": "address" + } + ], + "name": "NewPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldProtocolShareReserve", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newProtocolShareReserve", + "type": "address" + } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldReduceReservesBlockDelta", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newReduceReservesBlockDelta", + "type": "uint256" + } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldReserveFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newReserveFactorMantissa", + "type": "uint256" + } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "redeemAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "totalSupply", + "type": "uint256" + } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "feeAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "RedeemFee", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "payer", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "accountBorrows", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "totalBorrows", + "type": "uint256" + } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "benefactor", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "addAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newTotalReserves", + "type": "uint256" + } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "protocolShareReserve", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "reduceAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newTotalReserves", + "type": "uint256" + } + ], + "name": "ReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "constant": false, + "inputs": [], + "name": "_acceptAdmin", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "addAmount", + "type": "uint256" + } + ], + "name": "_addReserves", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "reduceAmount_", + "type": "uint256" + } + ], + "name": "_reduceReserves", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract ComptrollerInterface", + "name": "newComptroller", + "type": "address" + } + ], + "name": "_setComptroller", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel_", + "type": "address" + } + ], + "name": "_setInterestRateModel", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address payable", + "name": "newPendingAdmin", + "type": "address" + } + ], + "name": "_setPendingAdmin", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "newReserveFactorMantissa_", + "type": "uint256" + } + ], + "name": "_setReserveFactor", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "accrueInterest", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [ + { + "internalType": "address payable", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "address", + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + } + ], + "name": "balanceOfUnderlying", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "borrow", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "borrowBalanceCurrent", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "borrowBalanceStored", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "borrowBehalf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "borrowIndex", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "comptroller", + "outputs": [ + { + "internalType": "contract ComptrollerInterface", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "exchangeRateStored", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAccountSnapshot", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getCash", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "underlying_", + "type": "address" + }, + { + "internalType": "contract ComptrollerInterface", + "name": "comptroller_", + "type": "address" + }, + { + "internalType": "contract InterestRateModel", + "name": "interestRateModel_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "initialExchangeRateMantissa_", + "type": "uint256" + }, + { + "internalType": "string", + "name": "name_", + "type": "string" + }, + { + "internalType": "string", + "name": "symbol_", + "type": "string" + }, + { + "internalType": "uint8", + "name": "decimals_", + "type": "uint8" + } + ], + "name": "initialize", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "contract ComptrollerInterface", + "name": "comptroller_", + "type": "address" + }, + { + "internalType": "contract InterestRateModel", + "name": "interestRateModel_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "initialExchangeRateMantissa_", + "type": "uint256" + }, + { + "internalType": "string", + "name": "name_", + "type": "string" + }, + { + "internalType": "string", + "name": "symbol_", + "type": "string" + }, + { + "internalType": "uint8", + "name": "decimals_", + "type": "uint8" + } + ], + "name": "initialize", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "interestRateModel", + "outputs": [ + { + "internalType": "contract InterestRateModel", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isVToken", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "internalType": "contract VTokenInterface", + "name": "vTokenCollateral", + "type": "address" + } + ], + "name": "liquidateBorrow", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "mintBehalf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [ + { + "internalType": "address payable", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "protocolShareReserve", + "outputs": [ + { + "internalType": "address payable", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "redeem", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "redeemBehalf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "redeemAmount", + "type": "uint256" + } + ], + "name": "redeemUnderlying", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemAmount", + "type": "uint256" + } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "name": "repayBorrow", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "name": "repayBorrowBehalf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "seizeTokens", + "type": "uint256" + } + ], + "name": "seize", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "newAccessControlManagerAddress", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address payable", + "name": "protcolShareReserve_", + "type": "address" + } + ], + "name": "setProtocolShareReserve", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "uint256", + "name": "newReduceReservesBlockDelta_", + "type": "uint256" + } + ], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalBorrows", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalReserves", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "underlying", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-400/abi/ResilientOracle.json b/simulations/vip-400/abi/ResilientOracle.json new file mode 100644 index 000000000..04fb2fe79 --- /dev/null +++ b/simulations/vip-400/abi/ResilientOracle.json @@ -0,0 +1,750 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "previousAdmin", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAdmin", + "type": "address" + } + ], + "name": "AdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "beacon", + "type": "address" + } + ], + "name": "BeaconUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "implementation", + "type": "address" + } + ], + "name": "Upgraded", + "type": "event" + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "inputs": [], + "name": "admin", + "outputs": [ + { + "internalType": "address", + "name": "admin_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [ + { + "internalType": "address", + "name": "implementation_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + } + ], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newImplementation", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "upgradeToAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "stateMutability": "payable", + "type": "receive" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "mainOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "pivotOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "fallbackOracle", + "type": "address" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [ + { + "internalType": "contract BoundValidatorInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "getOracle", + "outputs": [ + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "bool", + "name": "enabled", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_logic", + "type": "address" + }, + { + "internalType": "address", + "name": "admin_", + "type": "address" + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes" + } + ], + "stateMutability": "payable", + "type": "constructor" + } +] diff --git a/simulations/vip-400/abi/SingleTokenConverter.json b/simulations/vip-400/abi/SingleTokenConverter.json new file mode 100644 index 000000000..1c8e0f8ec --- /dev/null +++ b/simulations/vip-400/abi/SingleTokenConverter.json @@ -0,0 +1,1267 @@ +[ + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { + "inputs": [], + "name": "AmountInMismatched", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { + "inputs": [], + "name": "AmountOutMismatched", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionConfigNotEnabled", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionEnabledOnlyForPrivateConversions", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionTokensActive", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionTokensPaused", + "type": "error" + }, + { + "inputs": [], + "name": "DeflationaryTokenNotSupported", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxIncentive", + "type": "uint256" + } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { + "inputs": [], + "name": "InputLengthMisMatch", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientInputAmount", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientOutputAmount", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientPoolLiquidity", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidConverterNetwork", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidMinimumAmountToConvert", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidToAddress", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidTokenConfigAddresses", + "type": "error" + }, + { + "inputs": [], + "name": "NonZeroIncentiveForPrivateConversion", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroValueNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldIncentive", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newIncentive", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + } + ], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + } + ], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldConverterNetwork", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "converterNetwork", + "type": "address" + } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldDestinationAddress", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "destinationAddress", + "type": "address" + } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMinAmountToConvert", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMinAmountToConvert", + "type": "uint256" + } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract ResilientOracle", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract ResilientOracle", + "name": "priceOracle", + "type": "address" + } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "token", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "token", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "tokenBalance", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "conversionConfigurations", + "outputs": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertExactTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertForExactTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [ + { + "internalType": "contract IConverterNetwork", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getAmountIn", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getAmountOut", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pauseConversion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [ + { + "internalType": "contract ResilientOracle", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "resumeConversion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address[]", + "name": "tokenAddressesOut", + "type": "address[]" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract IConverterNetwork", + "name": "converterNetwork_", + "type": "address" + } + ], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "destinationAddress_", + "type": "address" + } + ], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "minAmountToConvert_", + "type": "uint256" + } + ], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract ResilientOracle", + "name": "priceOracle_", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-400/bscmainnet.ts b/simulations/vip-400/bscmainnet.ts new file mode 100644 index 000000000..4f3586ea1 --- /dev/null +++ b/simulations/vip-400/bscmainnet.ts @@ -0,0 +1,111 @@ +import { expect } from "chai"; +import { BigNumber } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { setRedstonePrice } from "src/utils"; +import { checkRiskParameters } from "src/vip-framework/checks/checkRiskParameters"; +import { checkVToken } from "src/vip-framework/checks/checkVToken"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; +import { forking, testVip } from "src/vip-framework/index"; + +import vip400, { + EXPECTED_CONVERSION_INCENTIVE, + PROTOCOL_SHARE_RESERVE, + SOLVBTC_REDSTONE_FEED, + converterBaseAssets, + marketSpec, +} from "../../vips/vip-400/bscmainnet"; +import COMPTROLLER_ABI from "./abi/LegacyPoolComptroller.json"; +import VTOKEN_ABI from "./abi/LegacyPoolVToken.json"; +import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; +import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; + +const BLOCKS_PER_YEAR = BigNumber.from(10512000); + +const { RESILIENT_ORACLE, REDSTONE_ORACLE, ACCESS_CONTROL_MANAGER, NORMAL_TIMELOCK } = NETWORK_ADDRESSES.bscmainnet; + +forking(43338545, async () => { + const resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, ethers.provider); + const vToken = new ethers.Contract(marketSpec.vToken.address, VTOKEN_ABI, ethers.provider); + const comptroller = new ethers.Contract(marketSpec.vToken.comptroller, COMPTROLLER_ABI, ethers.provider); + + before(async () => { + await setRedstonePrice( + REDSTONE_ORACLE, + marketSpec.vToken.underlying.address, + SOLVBTC_REDSTONE_FEED, + NORMAL_TIMELOCK, + ); + }); + + describe("Pre-VIP behavior", () => { + it("check price", async () => { + await expect(resilientOracle.getPrice(marketSpec.vToken.underlying.address)).to.be.reverted; + }); + + it("should have 32 markets in the core pool", async () => { + const markets = await comptroller.getAllMarkets(); + expect(markets).to.have.lengthOf(32); + }); + }); + + testVip("VIP-400", await vip400(), {}); + + describe("Post-VIP behavior", async () => { + it("check price", async () => { + expect(await resilientOracle.getPrice(marketSpec.vToken.underlying.address)).to.be.closeTo( + parseUnits("67002.83221718", 18), + parseUnits("1", 18), + ); + expect(await resilientOracle.getUnderlyingPrice(marketSpec.vToken.address)).to.be.closeTo( + parseUnits("67002.83221718", 18), + parseUnits("1", 18), + ); + }); + + it("should have 33 markets in the core pool", async () => { + const markets = await comptroller.getAllMarkets(); + expect(markets).to.have.lengthOf(33); + }); + + it("has correct owner", async () => { + expect(await vToken.admin()).to.equal(NORMAL_TIMELOCK); + }); + + it("has correct ACM", async () => { + expect(await vToken.accessControlManager()).to.equal(ACCESS_CONTROL_MANAGER); + }); + + it("has correct initial supply", async () => { + const expectedSupply = parseUnits("0.1572404", 8); + expect(await vToken.balanceOf(marketSpec.initialSupply.vTokenReceiver)).to.equal(expectedSupply); + expect(await vToken.totalSupply()).to.equal(expectedSupply); + expect(await vToken.balanceOf(NORMAL_TIMELOCK)).to.equal(0); + }); + + it("has correct protocol share reserve", async () => { + expect(await vToken.protocolShareReserve()).equals(PROTOCOL_SHARE_RESERVE); + }); + + checkRiskParameters(marketSpec.vToken.address, marketSpec.vToken, marketSpec.riskParameters); + checkVToken(marketSpec.vToken.address, marketSpec.vToken); + checkInterestRate( + marketSpec.interestRateModel.address, + marketSpec.vToken.symbol, + marketSpec.interestRateModel, + BLOCKS_PER_YEAR, + ); + + describe("Converters", () => { + for (const [converterAddress, baseAsset] of Object.entries(converterBaseAssets)) { + const converterContract = new ethers.Contract(converterAddress, SINGLE_TOKEN_CONVERTER_ABI, ethers.provider); + const asset = marketSpec.vToken.underlying.address; + it(`should set ${EXPECTED_CONVERSION_INCENTIVE} as incentive in converter ${converterAddress}, for asset ${asset}`, async () => { + const result = await converterContract.conversionConfigurations(baseAsset, asset); + expect(result.incentive).to.equal(EXPECTED_CONVERSION_INCENTIVE); + }); + } + }); + }); +}); diff --git a/simulations/vip-400/bsctestnet.ts b/simulations/vip-400/bsctestnet.ts new file mode 100644 index 000000000..23285757d --- /dev/null +++ b/simulations/vip-400/bsctestnet.ts @@ -0,0 +1,95 @@ +import { expect } from "chai"; +import { BigNumber } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { checkRiskParameters } from "src/vip-framework/checks/checkRiskParameters"; +import { checkVToken } from "src/vip-framework/checks/checkVToken"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; +import { forking, testVip } from "src/vip-framework/index"; + +import vip400, { + EXPECTED_CONVERSION_INCENTIVE, + PROTOCOL_SHARE_RESERVE, + converterBaseAssets, + marketSpec, +} from "../../vips/vip-400/bsctestnet"; +import COMPTROLLER_ABI from "./abi/LegacyPoolComptroller.json"; +import VTOKEN_ABI from "./abi/LegacyPoolVToken.json"; +import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; +import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; + +const BLOCKS_PER_YEAR = BigNumber.from(10512000); + +const { RESILIENT_ORACLE, ACCESS_CONTROL_MANAGER, NORMAL_TIMELOCK } = NETWORK_ADDRESSES.bsctestnet; + +forking(44523500, async () => { + const resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, ethers.provider); + const vToken = new ethers.Contract(marketSpec.vToken.address, VTOKEN_ABI, ethers.provider); + const comptroller = new ethers.Contract(marketSpec.vToken.comptroller, COMPTROLLER_ABI, ethers.provider); + + describe("Pre-VIP behavior", () => { + it("check price", async () => { + await expect(resilientOracle.getPrice(marketSpec.vToken.underlying.address)).to.be.reverted; + }); + + it("should have 24 markets in the core pool", async () => { + const markets = await comptroller.getAllMarkets(); + expect(markets).to.have.lengthOf(24); + }); + }); + + testVip("VIP-400", await vip400(), {}); + + describe("Post-VIP behavior", async () => { + it("check price", async () => { + expect(await resilientOracle.getPrice(marketSpec.vToken.underlying.address)).to.be.closeTo( + parseUnits("60000", 18), + parseUnits("1", 18), + ); + expect(await resilientOracle.getUnderlyingPrice(marketSpec.vToken.address)).to.be.closeTo( + parseUnits("60000", 18), + parseUnits("1", 18), + ); + }); + + it("has correct owner", async () => { + expect(await vToken.admin()).to.equal(NORMAL_TIMELOCK); + }); + + it("has correct ACM", async () => { + expect(await vToken.accessControlManager()).to.equal(ACCESS_CONTROL_MANAGER); + }); + + it("has correct initial supply", async () => { + const expectedSupply = parseUnits("0.1572404", 8); + expect(await vToken.balanceOf(marketSpec.initialSupply.vTokenReceiver)).to.equal(expectedSupply); + expect(await vToken.totalSupply()).to.equal(expectedSupply); + expect(await vToken.balanceOf(NORMAL_TIMELOCK)).to.equal(0); + }); + + it("has correct protocol share reserve", async () => { + expect(await vToken.protocolShareReserve()).equals(PROTOCOL_SHARE_RESERVE); + }); + + checkRiskParameters(marketSpec.vToken.address, marketSpec.vToken, marketSpec.riskParameters); + checkVToken(marketSpec.vToken.address, marketSpec.vToken); + checkInterestRate( + marketSpec.interestRateModel.address, + marketSpec.vToken.symbol, + marketSpec.interestRateModel, + BLOCKS_PER_YEAR, + ); + + describe("Converters", () => { + for (const [converterAddress, baseAsset] of Object.entries(converterBaseAssets)) { + const converterContract = new ethers.Contract(converterAddress, SINGLE_TOKEN_CONVERTER_ABI, ethers.provider); + const asset = marketSpec.vToken.underlying.address; + it(`should set ${EXPECTED_CONVERSION_INCENTIVE} as incentive in converter ${converterAddress}, for asset ${asset}`, async () => { + const result = await converterContract.conversionConfigurations(baseAsset, asset); + expect(result.incentive).to.equal(EXPECTED_CONVERSION_INCENTIVE); + }); + } + }); + }); +}); diff --git a/vips/vip-400/bscmainnet.ts b/vips/vip-400/bscmainnet.ts new file mode 100644 index 000000000..80a7d61f4 --- /dev/null +++ b/vips/vip-400/bscmainnet.ts @@ -0,0 +1,199 @@ +import { BigNumberish } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; +import { NORMAL_TIMELOCK } from "src/vip-framework"; + +const { VTREASURY, RESILIENT_ORACLE, REDSTONE_ORACLE, UNITROLLER, ACCESS_CONTROL_MANAGER } = + NETWORK_ADDRESSES.bscmainnet; +export const PROTOCOL_SHARE_RESERVE = "0xCa01D5A9A248a830E9D93231e791B1afFed7c446"; +const SOLVBTC = "0x4aae823a6a0b376De6A78e74eCC5b079d38cBCf7"; +const SOLVBTC_VTOKEN = "0xf841cb62c19fCd4fF5CD0AaB5939f3140BaaC3Ea"; +export const SOLVBTC_REDSTONE_FEED = "0xF5F641fF3c7E39876A76e77E84041C300DFa4550"; +const SOLVBTC_MAX_STALE_PERIOD = 7 * 3600; // 7 hours +const REDUCE_RESERVES_BLOCK_DELTA = "28800"; + +const USDT = "0x55d398326f99059fF775485246999027B3197955"; +const USDC = "0x8AC76a51cc950d9822D68b83fE1Ad97B32Cd580d"; +const BTCB = "0x7130d2A12B9BCbFAe4f2634d864A1Ee1Ce3Ead9c"; +const XVS = "0xcF6BB5389c92Bdda8a3747Ddb454cB7a64626C63"; +const ETH = "0x2170Ed0880ac9A755fd29B2688956BD959F933F8"; +const RISK_FUND_CONVERTER = "0xA5622D276CcbB8d9BBE3D1ffd1BB11a0032E53F0"; +const USDT_PRIME_CONVERTER = "0xD9f101AA67F3D72662609a2703387242452078C3"; +const USDC_PRIME_CONVERTER = "0xa758c9C215B6c4198F0a0e3FA46395Fa15Db691b"; +const BTCB_PRIME_CONVERTER = "0xE8CeAa79f082768f99266dFd208d665d2Dd18f53"; +const ETH_PRIME_CONVERTER = "0xca430B8A97Ea918fF634162acb0b731445B8195E"; +const XVS_VAULT_CONVERTER = "0xd5b9AE835F4C59272032B3B954417179573331E0"; + +export const EXPECTED_CONVERSION_INCENTIVE = 1e14; +export const converterBaseAssets = { + [RISK_FUND_CONVERTER]: USDT, + [USDT_PRIME_CONVERTER]: USDT, + [USDC_PRIME_CONVERTER]: USDC, + [BTCB_PRIME_CONVERTER]: BTCB, + [ETH_PRIME_CONVERTER]: ETH, + [XVS_VAULT_CONVERTER]: XVS, +}; + +const configureConverters = (fromAssets: string[], incentive: BigNumberish = EXPECTED_CONVERSION_INCENTIVE) => { + enum ConversionAccessibility { + NONE = 0, + ALL = 1, + ONLY_FOR_CONVERTERS = 2, + ONLY_FOR_USERS = 3, + } + + return Object.entries(converterBaseAssets).map(([converter, baseAsset]: [string, string]) => { + const conversionConfigs = fromAssets.map(() => [incentive, ConversionAccessibility.ALL]); + return { + target: converter, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [baseAsset, fromAssets, conversionConfigs], + }; + }); +}; + +export const marketSpec = { + vToken: { + address: SOLVBTC_VTOKEN, + name: "Venus SolvBTC", + symbol: "vSolvBTC", + underlying: { + address: SOLVBTC, + decimals: 18, + symbol: "SolvBTC", + }, + decimals: 8, + exchangeRate: parseUnits("1", 28), + comptroller: UNITROLLER, + isLegacyPool: true, + }, + interestRateModel: { + address: "0xf092558eD27Df036144f6d92cC657BAc9682A324", + base: "0", + multiplier: "0.09", + jump: "2", + kink: "0.5", + }, + initialSupply: { + amount: parseUnits("0.1572404", 18), + vTokenReceiver: "0xD5bAa0C3d61Ba3f4899565f269e5f9b186AAf14B", + }, + riskParameters: { + supplyCap: parseUnits("100", 18), + borrowCap: parseUnits("55", 18), + collateralFactor: parseUnits("0.75", 18), + reserveFactor: parseUnits("0.2", 18), + }, +}; + +export const vip400 = () => { + const meta = { + version: "v2", + title: "VIP-400", + description: ``, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + + return makeProposal( + [ + // Configure Oracle + { + target: REDSTONE_ORACLE, + signature: "setTokenConfig((address,address,uint256))", + params: [[marketSpec.vToken.underlying.address, SOLVBTC_REDSTONE_FEED, SOLVBTC_MAX_STALE_PERIOD]], + }, + + { + target: RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [ + marketSpec.vToken.underlying.address, + [REDSTONE_ORACLE, ethers.constants.AddressZero, ethers.constants.AddressZero], + [true, false, false], + ], + ], + }, + + // Add Market + { + target: marketSpec.vToken.comptroller, + signature: "_supportMarket(address)", + params: [marketSpec.vToken.address], + }, + + { + target: marketSpec.vToken.comptroller, + signature: "_setMarketSupplyCaps(address[],uint256[])", + params: [[marketSpec.vToken.address], [marketSpec.riskParameters.supplyCap]], + }, + + { + target: marketSpec.vToken.comptroller, + signature: "_setMarketBorrowCaps(address[],uint256[])", + params: [[marketSpec.vToken.address], [marketSpec.riskParameters.borrowCap]], + }, + + { + target: marketSpec.vToken.comptroller, + signature: "_setCollateralFactor(address,uint256)", + params: [marketSpec.vToken.address, marketSpec.riskParameters.collateralFactor], + }, + + { + target: marketSpec.vToken.address, + signature: "setAccessControlManager(address)", + params: [ACCESS_CONTROL_MANAGER], + }, + { + target: marketSpec.vToken.address, + signature: "setProtocolShareReserve(address)", + params: [PROTOCOL_SHARE_RESERVE], + }, + + { + target: marketSpec.vToken.address, + signature: "setReduceReservesBlockDelta(uint256)", + params: [REDUCE_RESERVES_BLOCK_DELTA], + }, + { + target: marketSpec.vToken.address, + signature: "_setReserveFactor(uint256)", + params: [marketSpec.riskParameters.reserveFactor], + }, + + // Mint initial supply + { + target: VTREASURY, + signature: "withdrawTreasuryBEP20(address,uint256,address)", + params: [marketSpec.vToken.underlying.address, marketSpec.initialSupply.amount, NORMAL_TIMELOCK], + }, + { + target: marketSpec.vToken.underlying.address, + signature: "approve(address,uint256)", + params: [marketSpec.vToken.address, marketSpec.initialSupply.amount], + }, + { + target: marketSpec.vToken.address, + signature: "mintBehalf(address,uint256)", + params: [marketSpec.initialSupply.vTokenReceiver, marketSpec.initialSupply.amount], + }, + { + target: marketSpec.vToken.underlying.address, + signature: "approve(address,uint256)", + params: [marketSpec.vToken.address, 0], + }, + + ...configureConverters([marketSpec.vToken.underlying.address]), + ], + meta, + ProposalType.REGULAR, + ); +}; + +export default vip400; diff --git a/vips/vip-400/bsctestnet.ts b/vips/vip-400/bsctestnet.ts new file mode 100644 index 000000000..f23fa27ee --- /dev/null +++ b/vips/vip-400/bsctestnet.ts @@ -0,0 +1,197 @@ +import { BigNumberish } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +const { VTREASURY, RESILIENT_ORACLE, REDSTONE_ORACLE, UNITROLLER, ACCESS_CONTROL_MANAGER } = + NETWORK_ADDRESSES.bsctestnet; +export const PROTOCOL_SHARE_RESERVE = "0x25c7c7D6Bf710949fD7f03364E9BA19a1b3c10E3"; +const SOLVBTC = "0x6855E14A6df91b8E4D55163d068E9ef2530fd4CE"; +const SOLVBTC_VTOKEN = "0xA38110ae4451A86ab754695057d5B5a9BEAd0387"; +const FIXED_SOLVBTC_PRICE = parseUnits("60000", 18); +const REDUCE_RESERVES_BLOCK_DELTA = "28800"; + +const ETH = "0x98f7A83361F7Ac8765CcEBAB1425da6b341958a7"; +const USDT = "0xA11c8D9DC9b66E209Ef60F0C8D969D3CD988782c"; +const USDC = "0x16227D60f7a0e586C66B005219dfc887D13C9531"; +const BTCB = "0xA808e341e8e723DC6BA0Bb5204Bafc2330d7B8e4"; +const XVS = "0xB9e0E753630434d7863528cc73CB7AC638a7c8ff"; +const RISK_FUND_CONVERTER = "0x32Fbf7bBbd79355B86741E3181ef8c1D9bD309Bb"; +const USDT_PRIME_CONVERTER = "0xf1FA230D25fC5D6CAfe87C5A6F9e1B17Bc6F194E"; +const USDC_PRIME_CONVERTER = "0x2ecEdE6989d8646c992344fF6C97c72a3f811A13"; +const BTCB_PRIME_CONVERTER = "0x989A1993C023a45DA141928921C0dE8fD123b7d1"; +const ETH_PRIME_CONVERTER = "0xf358650A007aa12ecC8dac08CF8929Be7f72A4D9"; +const XVS_VAULT_CONVERTER = "0x258f49254C758a0E37DAb148ADDAEA851F4b02a2"; + +export const EXPECTED_CONVERSION_INCENTIVE = 1e14; +export const converterBaseAssets = { + [RISK_FUND_CONVERTER]: USDT, + [USDT_PRIME_CONVERTER]: USDT, + [USDC_PRIME_CONVERTER]: USDC, + [BTCB_PRIME_CONVERTER]: BTCB, + [ETH_PRIME_CONVERTER]: ETH, + [XVS_VAULT_CONVERTER]: XVS, +}; + +export const marketSpec = { + vToken: { + address: SOLVBTC_VTOKEN, + name: "Venus SolvBTC", + symbol: "vSolvBTC", + underlying: { + address: SOLVBTC, + decimals: 18, + symbol: "SolvBTC", + }, + decimals: 8, + exchangeRate: parseUnits("1", 28), + comptroller: UNITROLLER, + isLegacyPool: true, + }, + interestRateModel: { + address: "0x12b88631a2033c0e9afA36b295cdFCf49493E89e", + base: "0", + multiplier: "0.09", + jump: "2", + kink: "0.5", + }, + initialSupply: { + amount: parseUnits("0.1572404", 18), + vTokenReceiver: VTREASURY, + }, + riskParameters: { + supplyCap: parseUnits("100", 18), + borrowCap: parseUnits("55", 18), + collateralFactor: parseUnits("0.75", 18), + reserveFactor: parseUnits("0.2", 18), + }, +}; + +const configureConverters = (fromAssets: string[], incentive: BigNumberish = EXPECTED_CONVERSION_INCENTIVE) => { + enum ConversionAccessibility { + NONE = 0, + ALL = 1, + ONLY_FOR_CONVERTERS = 2, + ONLY_FOR_USERS = 3, + } + + return Object.entries(converterBaseAssets).map(([converter, baseAsset]: [string, string]) => { + const conversionConfigs = fromAssets.map(() => [incentive, ConversionAccessibility.ALL]); + return { + target: converter, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [baseAsset, fromAssets, conversionConfigs], + }; + }); +}; + +export const vip400 = () => { + const meta = { + version: "v2", + title: "VIP-400", + description: ``, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + + return makeProposal( + [ + // Configure Oracle + { + target: REDSTONE_ORACLE, + signature: "setDirectPrice(address,uint256)", + params: [marketSpec.vToken.underlying.address, FIXED_SOLVBTC_PRICE], + }, + + { + target: RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [ + marketSpec.vToken.underlying.address, + [REDSTONE_ORACLE, ethers.constants.AddressZero, ethers.constants.AddressZero], + [true, false, false], + ], + ], + }, + + // Add Market + { + target: marketSpec.vToken.comptroller, + signature: "_supportMarket(address)", + params: [marketSpec.vToken.address], + }, + + { + target: marketSpec.vToken.comptroller, + signature: "_setMarketSupplyCaps(address[],uint256[])", + params: [[marketSpec.vToken.address], [marketSpec.riskParameters.supplyCap]], + }, + + { + target: marketSpec.vToken.comptroller, + signature: "_setMarketBorrowCaps(address[],uint256[])", + params: [[marketSpec.vToken.address], [marketSpec.riskParameters.borrowCap]], + }, + + { + target: marketSpec.vToken.comptroller, + signature: "_setCollateralFactor(address,uint256)", + params: [marketSpec.vToken.address, marketSpec.riskParameters.collateralFactor], + }, + + { + target: marketSpec.vToken.address, + signature: "setAccessControlManager(address)", + params: [ACCESS_CONTROL_MANAGER], + }, + { + target: marketSpec.vToken.address, + signature: "setProtocolShareReserve(address)", + params: [PROTOCOL_SHARE_RESERVE], + }, + + { + target: marketSpec.vToken.address, + signature: "setReduceReservesBlockDelta(uint256)", + params: [REDUCE_RESERVES_BLOCK_DELTA], + }, + { + target: marketSpec.vToken.address, + signature: "_setReserveFactor(uint256)", + params: [marketSpec.riskParameters.reserveFactor], + }, + + // Mint initial supply + { + target: marketSpec.vToken.underlying.address, + signature: "faucet(uint256)", + params: [marketSpec.initialSupply.amount], + }, + { + target: marketSpec.vToken.underlying.address, + signature: "approve(address,uint256)", + params: [marketSpec.vToken.address, marketSpec.initialSupply.amount], + }, + { + target: marketSpec.vToken.address, + signature: "mintBehalf(address,uint256)", + params: [marketSpec.initialSupply.vTokenReceiver, marketSpec.initialSupply.amount], + }, + { + target: marketSpec.vToken.underlying.address, + signature: "approve(address,uint256)", + params: [marketSpec.vToken.address, 0], + }, + + ...configureConverters([marketSpec.vToken.underlying.address]), + ], + meta, + ProposalType.REGULAR, + ); +}; + +export default vip400; From 18fef3eb456559f3c164adf74e6856ed05be3096 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Tue, 22 Oct 2024 16:01:59 +0200 Subject: [PATCH 057/178] feat: set ID and description for the vip 387 --- .../{vip-400 => vip-387}/abi/ERC20.json | 0 .../abi/LegacyPoolComptroller.json | 0 .../abi/LegacyPoolVToken.json | 0 .../abi/ResilientOracle.json | 0 .../abi/SingleTokenConverter.json | 0 .../{vip-400 => vip-387}/bscmainnet.ts | 6 +- .../{vip-400 => vip-387}/bsctestnet.ts | 6 +- vips/{vip-400 => vip-387}/bscmainnet.ts | 55 +++++++++++++++++-- vips/{vip-400 => vip-387}/bsctestnet.ts | 6 +- 9 files changed, 60 insertions(+), 13 deletions(-) rename simulations/{vip-400 => vip-387}/abi/ERC20.json (100%) rename simulations/{vip-400 => vip-387}/abi/LegacyPoolComptroller.json (100%) rename simulations/{vip-400 => vip-387}/abi/LegacyPoolVToken.json (100%) rename simulations/{vip-400 => vip-387}/abi/ResilientOracle.json (100%) rename simulations/{vip-400 => vip-387}/abi/SingleTokenConverter.json (100%) rename simulations/{vip-400 => vip-387}/bscmainnet.ts (97%) rename simulations/{vip-400 => vip-387}/bsctestnet.ts (97%) rename vips/{vip-400 => vip-387}/bscmainnet.ts (72%) rename vips/{vip-400 => vip-387}/bsctestnet.ts (98%) diff --git a/simulations/vip-400/abi/ERC20.json b/simulations/vip-387/abi/ERC20.json similarity index 100% rename from simulations/vip-400/abi/ERC20.json rename to simulations/vip-387/abi/ERC20.json diff --git a/simulations/vip-400/abi/LegacyPoolComptroller.json b/simulations/vip-387/abi/LegacyPoolComptroller.json similarity index 100% rename from simulations/vip-400/abi/LegacyPoolComptroller.json rename to simulations/vip-387/abi/LegacyPoolComptroller.json diff --git a/simulations/vip-400/abi/LegacyPoolVToken.json b/simulations/vip-387/abi/LegacyPoolVToken.json similarity index 100% rename from simulations/vip-400/abi/LegacyPoolVToken.json rename to simulations/vip-387/abi/LegacyPoolVToken.json diff --git a/simulations/vip-400/abi/ResilientOracle.json b/simulations/vip-387/abi/ResilientOracle.json similarity index 100% rename from simulations/vip-400/abi/ResilientOracle.json rename to simulations/vip-387/abi/ResilientOracle.json diff --git a/simulations/vip-400/abi/SingleTokenConverter.json b/simulations/vip-387/abi/SingleTokenConverter.json similarity index 100% rename from simulations/vip-400/abi/SingleTokenConverter.json rename to simulations/vip-387/abi/SingleTokenConverter.json diff --git a/simulations/vip-400/bscmainnet.ts b/simulations/vip-387/bscmainnet.ts similarity index 97% rename from simulations/vip-400/bscmainnet.ts rename to simulations/vip-387/bscmainnet.ts index 4f3586ea1..dd4f7824a 100644 --- a/simulations/vip-400/bscmainnet.ts +++ b/simulations/vip-387/bscmainnet.ts @@ -9,13 +9,13 @@ import { checkVToken } from "src/vip-framework/checks/checkVToken"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; import { forking, testVip } from "src/vip-framework/index"; -import vip400, { +import vip387, { EXPECTED_CONVERSION_INCENTIVE, PROTOCOL_SHARE_RESERVE, SOLVBTC_REDSTONE_FEED, converterBaseAssets, marketSpec, -} from "../../vips/vip-400/bscmainnet"; +} from "../../vips/vip-387/bscmainnet"; import COMPTROLLER_ABI from "./abi/LegacyPoolComptroller.json"; import VTOKEN_ABI from "./abi/LegacyPoolVToken.json"; import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; @@ -50,7 +50,7 @@ forking(43338545, async () => { }); }); - testVip("VIP-400", await vip400(), {}); + testVip("VIP-387", await vip387(), {}); describe("Post-VIP behavior", async () => { it("check price", async () => { diff --git a/simulations/vip-400/bsctestnet.ts b/simulations/vip-387/bsctestnet.ts similarity index 97% rename from simulations/vip-400/bsctestnet.ts rename to simulations/vip-387/bsctestnet.ts index 23285757d..3d4950945 100644 --- a/simulations/vip-400/bsctestnet.ts +++ b/simulations/vip-387/bsctestnet.ts @@ -8,12 +8,12 @@ import { checkVToken } from "src/vip-framework/checks/checkVToken"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; import { forking, testVip } from "src/vip-framework/index"; -import vip400, { +import vip387, { EXPECTED_CONVERSION_INCENTIVE, PROTOCOL_SHARE_RESERVE, converterBaseAssets, marketSpec, -} from "../../vips/vip-400/bsctestnet"; +} from "../../vips/vip-387/bsctestnet"; import COMPTROLLER_ABI from "./abi/LegacyPoolComptroller.json"; import VTOKEN_ABI from "./abi/LegacyPoolVToken.json"; import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; @@ -39,7 +39,7 @@ forking(44523500, async () => { }); }); - testVip("VIP-400", await vip400(), {}); + testVip("VIP-387", await vip387(), {}); describe("Post-VIP behavior", async () => { it("check price", async () => { diff --git a/vips/vip-400/bscmainnet.ts b/vips/vip-387/bscmainnet.ts similarity index 72% rename from vips/vip-400/bscmainnet.ts rename to vips/vip-387/bscmainnet.ts index 80a7d61f4..c7c426d74 100644 --- a/vips/vip-400/bscmainnet.ts +++ b/vips/vip-387/bscmainnet.ts @@ -89,11 +89,58 @@ export const marketSpec = { }, }; -export const vip400 = () => { +export const vip387 = () => { const meta = { version: "v2", - title: "VIP-400", - description: ``, + title: "VIP-387 [BNB Chain] Add support for SolvBTC on Venus Core Pool", + description: `#### Summary + +If passed, this VIP will add a new market for the [SolvBTC token](https://bscscan.com/address/0x4aae823a6a0b376de6a78e74ecc5b079d38cbcf7) on Venus Core Pool. + +#### Description + +**Risk parameters** + +Following [Chaos Labs recommendations](https://community.venus.io/t/proposal-add-support-for-the-solvbtc-market-on-venus-core-pool/4525/11), the risk parameters for the new markets are: + +- Underlying token: [SolvBTC](https://bscscan.com/address/0x4aae823a6a0b376de6a78e74ecc5b079d38cbcf7) +- Borrow cap: 55 SolvBTC +- Supply cap: 100 SolvBTC +- Collateral factor: 75% +- Reserve factor: 20% + +Bootstrap liquidity: 0.1572404 SolvBTC - provided by the [SolvBTC project](https://solv.finance/). + +Interest rate curve for the new market: + +- kink: 50% +- base (yearly): 0 +- multiplier (yearly): 9% +- jump multiplier (yearly): 200% + +Oracle configuration: + +- Main oracle: [RedStoneOracle](https://bscscan.com/address/0x8455EFA4D7Ff63b8BFD96AdD889483Ea7d39B70a) +- Feed: [0xF5F641fF3c7E39876A76e77E84041C300DFa4550](https://bscscan.com/address/0xF5F641fF3c7E39876A76e77E84041C300DFa4550) + +#### Security and additional considerations + +No changes in the code are involved in this VIP. We applied the following security procedures for this upgrade: + +- **VIP execution simulation**: in a simulation environment, validating the new market is properly added to the core pool with the right parameters and the expected bootstrap liquidity +- **Deployment on testnet**: the same market has been deployed to testnet, and used in the Venus Protocol testnet deployment + +#### Deployed contracts + +- **Mainnet SolvBTC market (vSolvBTC)**: [0x3e6d2c5b235070DAD569Bc40689C589db286F445](https://bscscan.com/address/0x3e6d2c5b235070DAD569Bc40689C589db286F445) +- **Testnet SolvBTC market (vSolvBTC)**: [0xA38110ae4451A86ab754695057d5B5a9BEAd0387](https://testnet.bscscan.com/address/0xA38110ae4451A86ab754695057d5B5a9BEAd0387) + +#### References + +- [VIP simulation](https://github.com/VenusProtocol/vips/pull/407) +- [Testnet deployment](https://testnet.bscscan.com/tx/0x8a6017f351c1e8b4ae5a34419a1e17fb51366ac04b02b0aec203e67135cd1eca) +- Snapshot “[[BNB Chain] Add support for the SolvBTC market on Venus Core Pool](https://snapshot.org/#/venus-xvs.eth/proposal/0xdd06e54960ca61ba0a39a9a00d6e18f5e6ee07e1e78d416af1d3e2f5a7b79c23)” +- [Documentation](https://docs-v4.venus.io/)`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", @@ -196,4 +243,4 @@ export const vip400 = () => { ); }; -export default vip400; +export default vip387; diff --git a/vips/vip-400/bsctestnet.ts b/vips/vip-387/bsctestnet.ts similarity index 98% rename from vips/vip-400/bsctestnet.ts rename to vips/vip-387/bsctestnet.ts index f23fa27ee..aef57b04d 100644 --- a/vips/vip-400/bsctestnet.ts +++ b/vips/vip-387/bsctestnet.ts @@ -87,10 +87,10 @@ const configureConverters = (fromAssets: string[], incentive: BigNumberish = EXP }); }; -export const vip400 = () => { +export const vip387 = () => { const meta = { version: "v2", - title: "VIP-400", + title: "VIP-387", description: ``, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", @@ -194,4 +194,4 @@ export const vip400 = () => { ); }; -export default vip400; +export default vip387; From a387b3d196e0315296dfcb27237f4e96666798a6 Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 23 Oct 2024 23:02:38 +0400 Subject: [PATCH 058/178] fix: updated indexes --- simulations/vip-371/arbitrumsepolia.ts | 4 ++-- simulations/vip-371/bsctestnet.ts | 2 +- simulations/vip-371/opbnbtestnet.ts | 4 ++-- simulations/vip-371/sepolia.ts | 8 ++++---- vips/vip-371/bsctestnet.ts | 18 ++++++++++++------ 5 files changed, 21 insertions(+), 15 deletions(-) diff --git a/simulations/vip-371/arbitrumsepolia.ts b/simulations/vip-371/arbitrumsepolia.ts index 2daeea2f6..7059d7608 100644 --- a/simulations/vip-371/arbitrumsepolia.ts +++ b/simulations/vip-371/arbitrumsepolia.ts @@ -11,10 +11,10 @@ import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { arbitrumsepolia } = NETWORK_ADDRESSES; const ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; -forking(87457288, async () => { +forking(91072072, async () => { testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { callbackAfterExecution: async txResponse => { - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [88]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [194]); await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [62]); await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); diff --git a/simulations/vip-371/bsctestnet.ts b/simulations/vip-371/bsctestnet.ts index 6f8807668..adb8b4d09 100644 --- a/simulations/vip-371/bsctestnet.ts +++ b/simulations/vip-371/bsctestnet.ts @@ -3,7 +3,7 @@ import { forking, testVip } from "../../src/vip-framework"; import vip371 from "../../vips/vip-371/bsctestnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; -forking(41938696, async () => { +forking(44995536, async () => { testVip("vip371 XVS vault permission proposal", await vip371(), { callbackAfterExecution: async txResponse => { await expectEvents( diff --git a/simulations/vip-371/opbnbtestnet.ts b/simulations/vip-371/opbnbtestnet.ts index f01bcde94..c9cd967e5 100644 --- a/simulations/vip-371/opbnbtestnet.ts +++ b/simulations/vip-371/opbnbtestnet.ts @@ -11,10 +11,10 @@ import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { opbnbtestnet } = NETWORK_ADDRESSES; const ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; -forking(41684455, async () => { +forking(42828856, async () => { testForkedNetworkVipCommands("vip371", await vip371(), { callbackAfterExecution: async txResponse => { - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [74]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [154]); await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [48]); await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); diff --git a/simulations/vip-371/sepolia.ts b/simulations/vip-371/sepolia.ts index 108025605..850f566c4 100644 --- a/simulations/vip-371/sepolia.ts +++ b/simulations/vip-371/sepolia.ts @@ -11,12 +11,12 @@ import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { sepolia } = NETWORK_ADDRESSES; const ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; -forking(6850243, async () => { +forking(6930723, async () => { testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { callbackAfterExecution: async txResponse => { - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [99]); - await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [67]); - await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [223]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [77]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [2]); await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); }, }); diff --git a/vips/vip-371/bsctestnet.ts b/vips/vip-371/bsctestnet.ts index a873d5171..1097c0f20 100644 --- a/vips/vip-371/bsctestnet.ts +++ b/vips/vip-371/bsctestnet.ts @@ -31,13 +31,13 @@ const vip371 = () => { { target: ARBITRUMSEPOLIA_ACM_AGGREGATOR, signature: "executeGrantPermissions(uint256)", - params: [2], + params: [3], dstChainId: LzChainId.arbitrumsepolia, }, { target: ARBITRUMSEPOLIA_ACM_AGGREGATOR, signature: "executeRevokePermissions(uint256)", - params: [2], + params: [3], dstChainId: LzChainId.arbitrumsepolia, }, { @@ -56,13 +56,13 @@ const vip371 = () => { { target: OPBNBTESTNET_ACM_AGGREGATOR, signature: "executeGrantPermissions(uint256)", - params: [1], + params: [2], dstChainId: LzChainId.opbnbtestnet, }, { target: OPBNBTESTNET_ACM_AGGREGATOR, signature: "executeRevokePermissions(uint256)", - params: [1], + params: [2], dstChainId: LzChainId.opbnbtestnet, }, { @@ -81,13 +81,19 @@ const vip371 = () => { { target: SEPOLIA_ACM_AGGREGATOR, signature: "executeGrantPermissions(uint256)", - params: [1], + params: [2], + dstChainId: LzChainId.sepolia, + }, + { + target: SEPOLIA_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [3], dstChainId: LzChainId.sepolia, }, { target: SEPOLIA_ACM_AGGREGATOR, signature: "executeRevokePermissions(uint256)", - params: [1], + params: [2], dstChainId: LzChainId.sepolia, }, { From af06fb067f725255137ea7e957b4068a1d9f6893 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Thu, 24 Oct 2024 15:01:35 +0530 Subject: [PATCH 059/178] feat: update supply and borrow rate for LTC and AAVE market on core pool bsc mainnet --- simulations/vip-391/abi/Comptroller.json | 954 +++++++++++++++++++++++ simulations/vip-391/bscmainnet.ts | 68 ++ vips/vip-391/bscmainnet.ts | 59 ++ 3 files changed, 1081 insertions(+) create mode 100644 simulations/vip-391/abi/Comptroller.json create mode 100644 simulations/vip-391/bscmainnet.ts create mode 100644 vips/vip-391/bscmainnet.ts diff --git a/simulations/vip-391/abi/Comptroller.json b/simulations/vip-391/abi/Comptroller.json new file mode 100644 index 000000000..ad25568bc --- /dev/null +++ b/simulations/vip-391/abi/Comptroller.json @@ -0,0 +1,954 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "ActionPaused", + "type": "error" + }, + { "inputs": [], "name": "BorrowActionNotPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "BorrowCapIsNotZero", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { "inputs": [], "name": "CollateralFactorIsNotZero", "type": "error" }, + { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, + { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, + { "inputs": [], "name": "EnterMarketActionNotPaused", "type": "error" }, + { "inputs": [], "name": "ExitMarketActionNotPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, + { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, + { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, + { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, + { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, + { "inputs": [], "name": "LiquidateActionNotPaused", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { "inputs": [], "name": "MintActionNotPaused", "type": "error" }, + { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "PriceError", + "type": "error" + }, + { "inputs": [], "name": "RedeemActionNotPaused", "type": "error" }, + { "inputs": [], "name": "RepayActionNotPaused", "type": "error" }, + { "inputs": [], "name": "SeizeActionNotPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "SupplyCapIsNotZero", "type": "error" }, + { "inputs": [], "name": "TooMuchRepay", "type": "error" }, + { "inputs": [], "name": "TransferActionNotPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "expectedSender", "type": "address" }, + { "internalType": "address", "name": "actualSender", "type": "address" } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, + { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "MarketUnlisted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "accountAssets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "actionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allMarkets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "approvedDelegates", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "borrowCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "contract VToken", "name": "vToken", "type": "address" } + ], + "name": "checkMembership", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], + "name": "enterMarkets", + "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], + "name": "exitMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAssetsIn", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getBorrowingPower", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "vTokenModify", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isForcedLiquidationEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "isMarketListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [ + { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "bool", "name": "isListed", "type": "bool" }, + { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "seizerContract", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, + { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, + { "internalType": "bool", "name": "paused", "type": "bool" } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "supplyCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "unlistMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "delegate", "type": "address" }, + { "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-391/bscmainnet.ts b/simulations/vip-391/bscmainnet.ts new file mode 100644 index 000000000..20ad92f0b --- /dev/null +++ b/simulations/vip-391/bscmainnet.ts @@ -0,0 +1,68 @@ +import { expect } from "chai"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { expectEvents } from "src/utils"; +import { forking, testVip } from "src/vip-framework"; + +import { + CORE_COMPTROLLER, + vAAVE, + vAAVE_BORROW_CAP, + vLTC, + vLTC_BORROW_CAP, + vLTC_SUPPLY_CAP, + vip391, +} from "../../vips/vip-391/bscmainnet"; +import COMPTROLLER_ABI from "./abi/Comptroller.json"; + +const vAAVE_SUPPLY_CAP = parseUnits("20000", 18); +const vLTC_SUPPLY_CAP_PREV = parseUnits("120000", 18); +const vLTC_BORROW_CAP_PREV = parseUnits("10000", 18); +const vAAVE_BORROW_CAP_PREV = parseUnits("2000", 18); + +forking(43368825, async () => { + const provider = ethers.provider; + const coreComptroller = new ethers.Contract(CORE_COMPTROLLER, COMPTROLLER_ABI, provider); + + describe("Pre-VIP behavior", async () => { + it("check supply and borrow cap for LTC", async () => { + const supplyCap = await coreComptroller.supplyCaps(vLTC); + const borrowCap = await coreComptroller.borrowCaps(vLTC); + + expect(supplyCap).to.eq(vLTC_SUPPLY_CAP_PREV); + expect(borrowCap).to.eq(vLTC_BORROW_CAP_PREV); + }); + + it("check supply and borrow cap for AAVE", async () => { + const supplyCap = await coreComptroller.supplyCaps(vAAVE); + const borrowCap = await coreComptroller.borrowCaps(vAAVE); + + expect(supplyCap).to.eq(vAAVE_SUPPLY_CAP); + expect(borrowCap).to.eq(vAAVE_BORROW_CAP_PREV); + }); + }); + + testVip("VIP-391", await vip391(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [COMPTROLLER_ABI], ["NewBorrowCap", "NewSupplyCap"], [2, 1]); + }, + }); + + describe("Post-VIP behavior", async () => { + it("check supply and borrow cap for LTC", async () => { + const supplyCap = await coreComptroller.supplyCaps(vLTC); + const borrowCap = await coreComptroller.borrowCaps(vLTC); + + expect(supplyCap).to.eq(vLTC_SUPPLY_CAP); + expect(borrowCap).to.eq(vLTC_BORROW_CAP); + }); + + it("check supply and borrow cap for AAVE", async () => { + const supplyCap = await coreComptroller.supplyCaps(vAAVE); + const borrowCap = await coreComptroller.borrowCaps(vAAVE); + + expect(supplyCap).to.eq(vAAVE_SUPPLY_CAP); + expect(borrowCap).to.eq(vAAVE_BORROW_CAP); + }); + }); +}); diff --git a/vips/vip-391/bscmainnet.ts b/vips/vip-391/bscmainnet.ts new file mode 100644 index 000000000..5c2fc6a0a --- /dev/null +++ b/vips/vip-391/bscmainnet.ts @@ -0,0 +1,59 @@ +import { parseUnits } from "ethers/lib/utils"; +import { ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const CORE_COMPTROLLER = "0xfD36E2c2a6789Db23113685031d7F16329158384"; +export const vLTC = "0x57A5297F2cB2c0AaC9D554660acd6D385Ab50c6B"; +export const vAAVE = "0x26DA28954763B92139ED49283625ceCAf52C6f94"; + +export const vLTC_SUPPLY_CAP = parseUnits("240000", 18); +export const vLTC_BORROW_CAP = parseUnits("20000", 18); +export const vAAVE_BORROW_CAP = parseUnits("3000", 18); + +export const vip391 = () => { + const meta = { + version: "v2", + title: "VIP-391 Risk Parameters Adjustment (LTC, AAVE)", + description: `If passed, this VIP will perform the following actions as per Chaos Labs’ latest recommendations in this Venus community forum publication. + +It would update the following caps on BNB Chain, following this forum publication: [Chaos Labs - ] + +- [LTC (Core pool)](https://bscscan.com/address/0x57A5297F2cB2c0AaC9D554660acd6D385Ab50c6B): + - increase supply cap from 120K LTC to 240K LTC + - increase borrow cap from 10K LTC to 20K LTC +- [AAVE (Core pool)](https://bscscan.com/address/0x26DA28954763B92139ED49283625ceCAf52C6f94): + - increase borrow cap from 2K AAVE to 3K AAVE + +Review the Chaos Labs’ recommendations for a deeper analysis. + +VIP simulation: +`, + forDescription: "Execute this proposal", + againstDescription: "Do not execute this proposal", + abstainDescription: "Indifferent to execution", + }; + + return makeProposal( + [ + { + target: CORE_COMPTROLLER, + signature: "_setMarketSupplyCaps(address[],uint256[])", + params: [[vLTC], [vLTC_SUPPLY_CAP]], + }, + { + target: CORE_COMPTROLLER, + signature: "_setMarketBorrowCaps(address[],uint256[])", + params: [[vLTC], [vLTC_BORROW_CAP]], + }, + { + target: CORE_COMPTROLLER, + signature: "_setMarketBorrowCaps(address[],uint256[])", + params: [[vAAVE], [vAAVE_BORROW_CAP]], + }, + ], + meta, + ProposalType.FAST_TRACK, + ); +}; + +export default vip391; From cfc9ab71af48a9fb88c20fc078d1bd081dd76078 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Thu, 24 Oct 2024 15:43:45 +0530 Subject: [PATCH 060/178] refactor: update the vip number --- simulations/{vip-387 => vip-389}/abi/ACMAggregator.json | 0 .../{vip-387 => vip-389}/abi/AccessControlManager_ABI.json | 0 .../abi/OmnichainExecutorOwner_ABI.json | 0 .../abi/OmnichainGovernanceExecutor_ABI.json | 0 .../{vip-387 => vip-389}/abi/OmnichainProposalSender.json | 0 simulations/{vip-387 => vip-389}/bsctestnet.ts | 4 ++-- simulations/{vip-387 => vip-389}/opsepolia.ts | 6 +++--- vips/{vip-387 => vip-389}/bsctestnet.ts | 6 +++--- 8 files changed, 8 insertions(+), 8 deletions(-) rename simulations/{vip-387 => vip-389}/abi/ACMAggregator.json (100%) rename simulations/{vip-387 => vip-389}/abi/AccessControlManager_ABI.json (100%) rename simulations/{vip-387 => vip-389}/abi/OmnichainExecutorOwner_ABI.json (100%) rename simulations/{vip-387 => vip-389}/abi/OmnichainGovernanceExecutor_ABI.json (100%) rename simulations/{vip-387 => vip-389}/abi/OmnichainProposalSender.json (100%) rename simulations/{vip-387 => vip-389}/bsctestnet.ts (92%) rename simulations/{vip-387 => vip-389}/opsepolia.ts (98%) rename vips/{vip-387 => vip-389}/bsctestnet.ts (95%) diff --git a/simulations/vip-387/abi/ACMAggregator.json b/simulations/vip-389/abi/ACMAggregator.json similarity index 100% rename from simulations/vip-387/abi/ACMAggregator.json rename to simulations/vip-389/abi/ACMAggregator.json diff --git a/simulations/vip-387/abi/AccessControlManager_ABI.json b/simulations/vip-389/abi/AccessControlManager_ABI.json similarity index 100% rename from simulations/vip-387/abi/AccessControlManager_ABI.json rename to simulations/vip-389/abi/AccessControlManager_ABI.json diff --git a/simulations/vip-387/abi/OmnichainExecutorOwner_ABI.json b/simulations/vip-389/abi/OmnichainExecutorOwner_ABI.json similarity index 100% rename from simulations/vip-387/abi/OmnichainExecutorOwner_ABI.json rename to simulations/vip-389/abi/OmnichainExecutorOwner_ABI.json diff --git a/simulations/vip-387/abi/OmnichainGovernanceExecutor_ABI.json b/simulations/vip-389/abi/OmnichainGovernanceExecutor_ABI.json similarity index 100% rename from simulations/vip-387/abi/OmnichainGovernanceExecutor_ABI.json rename to simulations/vip-389/abi/OmnichainGovernanceExecutor_ABI.json diff --git a/simulations/vip-387/abi/OmnichainProposalSender.json b/simulations/vip-389/abi/OmnichainProposalSender.json similarity index 100% rename from simulations/vip-387/abi/OmnichainProposalSender.json rename to simulations/vip-389/abi/OmnichainProposalSender.json diff --git a/simulations/vip-387/bsctestnet.ts b/simulations/vip-389/bsctestnet.ts similarity index 92% rename from simulations/vip-387/bsctestnet.ts rename to simulations/vip-389/bsctestnet.ts index 550586615..2b40b3f10 100644 --- a/simulations/vip-387/bsctestnet.ts +++ b/simulations/vip-389/bsctestnet.ts @@ -5,7 +5,7 @@ import { LzChainId } from "src/types"; import { expectEvents } from "src/utils"; import { forking, testVip } from "src/vip-framework"; -import vip387, { MAX_DAILY_LIMIT, OMNICHAIN_PROPOSAL_SENDER } from "../../vips/vip-387/bsctestnet"; +import vip389, { MAX_DAILY_LIMIT, OMNICHAIN_PROPOSAL_SENDER } from "../../vips/vip-389/bsctestnet"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; @@ -27,7 +27,7 @@ forking(44927774, async () => { }); }); - testVip("vip387 give permissions to timelock", await vip387(), { + testVip("vip389 give permissions to timelock", await vip389(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-387/opsepolia.ts b/simulations/vip-389/opsepolia.ts similarity index 98% rename from simulations/vip-387/opsepolia.ts rename to simulations/vip-389/opsepolia.ts index 0c3835d66..5eecb837a 100644 --- a/simulations/vip-387/opsepolia.ts +++ b/simulations/vip-389/opsepolia.ts @@ -7,12 +7,12 @@ import { expectEvents, getOmnichainProposalSenderAddress } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; import vip007 from "../../multisig/proposals/opsepolia/vip-007"; -import vip387, { +import vip389, { DEFAULT_ADMIN_ROLE, OPSEPOLIA_ACM, OPSEPOLIA_ACM_AGGREGATOR, OPSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, -} from "../../vips/vip-387/bsctestnet"; +} from "../../vips/vip-389/bsctestnet"; import ACMAggregator_ABI from "./abi/ACMAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_EXECUTOR_OWNER_ABI from "./abi/OmnichainExecutorOwner_ABI.json"; @@ -47,7 +47,7 @@ forking(18889503, async () => { }); }); - testForkedNetworkVipCommands("vip387 configures bridge", await vip387(), { + testForkedNetworkVipCommands("vip389 configures bridge", await vip389(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [39]); await expectEvents(txResponse, [ACMAggregator_ABI], ["GrantPermissionsExecuted"], [1]); diff --git a/vips/vip-387/bsctestnet.ts b/vips/vip-389/bsctestnet.ts similarity index 95% rename from vips/vip-387/bsctestnet.ts rename to vips/vip-389/bsctestnet.ts index a6fecb028..c906452a2 100644 --- a/vips/vip-387/bsctestnet.ts +++ b/vips/vip-389/bsctestnet.ts @@ -11,10 +11,10 @@ export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000 export const OPSEPOLIA_ACM_AGGREGATOR = "0xEEeF13364fD22b8eA6932A9ed337e2638f8E0eD6"; export const MAX_DAILY_LIMIT = 100; -const vip387 = () => { +const vip389 = () => { const meta = { version: "v2", - title: "VIP-387 Enable Multichain Governance on op sepolia", + title: "VIP-389 Enable Multichain Governance on op sepolia", description: `### Summary`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", @@ -61,4 +61,4 @@ const vip387 = () => { ProposalType.REGULAR, ); }; -export default vip387; +export default vip389; From f2e5568fc387f7e3f5d03f0ed076ccf44e899767 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Fri, 25 Oct 2024 11:25:53 +0530 Subject: [PATCH 061/178] fix: pr comments --- vips/vip-391/bscmainnet.ts | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/vips/vip-391/bscmainnet.ts b/vips/vip-391/bscmainnet.ts index 5c2fc6a0a..70aaf7f5b 100644 --- a/vips/vip-391/bscmainnet.ts +++ b/vips/vip-391/bscmainnet.ts @@ -43,13 +43,8 @@ VIP simulation: { target: CORE_COMPTROLLER, signature: "_setMarketBorrowCaps(address[],uint256[])", - params: [[vLTC], [vLTC_BORROW_CAP]], - }, - { - target: CORE_COMPTROLLER, - signature: "_setMarketBorrowCaps(address[],uint256[])", - params: [[vAAVE], [vAAVE_BORROW_CAP]], - }, + params: [[vLTC, vAAVE], [vLTC_BORROW_CAP, vAAVE_BORROW_CAP]], + } ], meta, ProposalType.FAST_TRACK, From 4c4888f85bd927df1755876e4d6bcd284e086cbc Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Fri, 25 Oct 2024 11:29:56 +0530 Subject: [PATCH 062/178] fix: lint issues --- vips/vip-391/bscmainnet.ts | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/vips/vip-391/bscmainnet.ts b/vips/vip-391/bscmainnet.ts index 70aaf7f5b..2a649d3ae 100644 --- a/vips/vip-391/bscmainnet.ts +++ b/vips/vip-391/bscmainnet.ts @@ -43,8 +43,11 @@ VIP simulation: { target: CORE_COMPTROLLER, signature: "_setMarketBorrowCaps(address[],uint256[])", - params: [[vLTC, vAAVE], [vLTC_BORROW_CAP, vAAVE_BORROW_CAP]], - } + params: [ + [vLTC, vAAVE], + [vLTC_BORROW_CAP, vAAVE_BORROW_CAP], + ], + }, ], meta, ProposalType.FAST_TRACK, From fbb7326d7324efa787f9aba1b0f94e2b41bcda12 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Fri, 25 Oct 2024 14:37:41 +0530 Subject: [PATCH 063/178] feat: update supply cap and collateral factor for TWT on Defi pool bsc mainnet --- ...{Comptroller.json => CoreComptroller.json} | 0 simulations/vip-391/abi/DefiComptroller.json | 2121 +++++++++++++++++ simulations/vip-391/bscmainnet.ts | 112 +- vips/vip-391/bscmainnet.ts | 36 +- 4 files changed, 2227 insertions(+), 42 deletions(-) rename simulations/vip-391/abi/{Comptroller.json => CoreComptroller.json} (100%) create mode 100644 simulations/vip-391/abi/DefiComptroller.json diff --git a/simulations/vip-391/abi/Comptroller.json b/simulations/vip-391/abi/CoreComptroller.json similarity index 100% rename from simulations/vip-391/abi/Comptroller.json rename to simulations/vip-391/abi/CoreComptroller.json diff --git a/simulations/vip-391/abi/DefiComptroller.json b/simulations/vip-391/abi/DefiComptroller.json new file mode 100644 index 000000000..d1801efd8 --- /dev/null +++ b/simulations/vip-391/abi/DefiComptroller.json @@ -0,0 +1,2121 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "poolRegistry_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum Action", + "name": "action", + "type": "uint8" + } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [], + "name": "BorrowActionNotPaused", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [], + "name": "BorrowCapIsNotZero", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedLessThanOrEqualTo", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { + "inputs": [], + "name": "CollateralFactorIsNotZero", + "type": "error" + }, + { + "inputs": [], + "name": "ComptrollerMismatch", + "type": "error" + }, + { + "inputs": [], + "name": "DelegationStatusUnchanged", + "type": "error" + }, + { + "inputs": [], + "name": "EnterMarketActionNotPaused", + "type": "error" + }, + { + "inputs": [], + "name": "ExitMarketActionNotPaused", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "collateralToSeize", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "availableCollateral", + "type": "uint256" + } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientLiquidity", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientShortfall", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidCollateralFactor", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidLiquidationThreshold", + "type": "error" + }, + { + "inputs": [], + "name": "LiquidateActionNotPaused", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "loopsLimit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "requiredLoops", + "type": "uint256" + } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedGreaterThan", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { + "inputs": [], + "name": "MintActionNotPaused", + "type": "error" + }, + { + "inputs": [], + "name": "NonzeroBorrowBalance", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [], + "name": "RedeemActionNotPaused", + "type": "error" + }, + { + "inputs": [], + "name": "RepayActionNotPaused", + "type": "error" + }, + { + "inputs": [], + "name": "SeizeActionNotPaused", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { + "inputs": [], + "name": "SupplyCapIsNotZero", + "type": "error" + }, + { + "inputs": [], + "name": "TooMuchRepay", + "type": "error" + }, + { + "inputs": [], + "name": "TransferActionNotPaused", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "expectedSender", + "type": "address" + }, + { + "internalType": "address", + "name": "actualSender", + "type": "address" + } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "enum Action", + "name": "action", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "bool", + "name": "pauseState", + "type": "bool" + } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "approver", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "delegate", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "approved", + "type": "bool" + } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "MarketUnlisted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMaxLoopsLimit", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newmaxLoopsLimit", + "type": "uint256" + } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newBorrowCap", + "type": "uint256" + } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldCloseFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldCollateralFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationIncentiveMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationThresholdMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMinLiquidatableCollateral", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract IPrime", + "name": "oldPrimeToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract IPrime", + "name": "newPrimeToken", + "type": "address" + } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "rewardsDistributor", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "rewardToken", + "type": "address" + } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSupplyCap", + "type": "uint256" + } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "accountAssets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum Action", + "name": "action", + "type": "uint8" + } + ], + "name": "actionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract RewardsDistributor", + "name": "_rewardsDistributor", + "type": "address" + } + ], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "allMarkets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "approvedDelegates", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "borrowCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "checkMembership", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "vTokens", + "type": "address[]" + } + ], + "name": "enterMarkets", + "outputs": [ + { + "internalType": "uint256[]", + "name": "", + "type": "uint256[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenAddress", + "type": "address" + } + ], + "name": "exitMarket", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAssetsIn", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getBorrowingPower", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenModify", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [ + { + "internalType": "contract RewardsDistributor[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "rewardToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "supplySpeed", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowSpeed", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "loopLimit", + "type": "uint256" + }, + { + "internalType": "address", + "name": "accessControlManager", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "isForcedLiquidationEnabled", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isMarketListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "components": [ + { + "internalType": "contract VToken", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "seizeTokens", + "type": "uint256" + } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokensToSeize", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "markets", + "outputs": [ + { + "internalType": "bool", + "name": "isListed", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "collateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidationThresholdMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualMintAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "mintTokens", + "type": "uint256" + } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [ + { + "internalType": "contract ResilientOracleInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "skipLiquidityCheck", + "type": "bool" + } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "seizerContract", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "transferTokens", + "type": "uint256" + } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [ + { + "internalType": "contract IPrime", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "payer", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowerIndex", + "type": "uint256" + } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "seizeTokens", + "type": "uint256" + } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "marketsList", + "type": "address[]" + }, + { + "internalType": "enum Action[]", + "name": "actionsList", + "type": "uint8[]" + }, + { + "internalType": "bool", + "name": "paused", + "type": "bool" + } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newBorrowCaps", + "type": "uint256[]" + } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newSupplyCaps", + "type": "uint256[]" + } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "limit", + "type": "uint256" + } + ], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract ResilientOracleInterface", + "name": "newOracle", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract IPrime", + "name": "_prime", + "type": "address" + } + ], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "supplyCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "transferTokens", + "type": "uint256" + } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "unlistMarket", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "delegate", + "type": "address" + }, + { + "internalType": "bool", + "name": "approved", + "type": "bool" + } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-391/bscmainnet.ts b/simulations/vip-391/bscmainnet.ts index 20ad92f0b..05c306aa5 100644 --- a/simulations/vip-391/bscmainnet.ts +++ b/simulations/vip-391/bscmainnet.ts @@ -6,63 +6,109 @@ import { forking, testVip } from "src/vip-framework"; import { CORE_COMPTROLLER, - vAAVE, - vAAVE_BORROW_CAP, - vLTC, - vLTC_BORROW_CAP, - vLTC_SUPPLY_CAP, + DEFI_COMPTROLLER, + vAAVE_CORE, + vAAVE_CORE_BORROW_CAP, + vLTC_CORE, + vLTC_CORE_BORROW_CAP, + vLTC_CORE_SUPPLY_CAP, + vTWT_DEFI, + vTWT_DEFI_COLLATERAL_FACTOR, + vTWT_DEFI_SUPPLY_CAP, vip391, } from "../../vips/vip-391/bscmainnet"; -import COMPTROLLER_ABI from "./abi/Comptroller.json"; +import CORE_COMPTROLLER_ABI from "./abi/CoreComptroller.json"; +import DEFI_COMPTROLLER_ABI from "./abi/CoreComptroller.json"; -const vAAVE_SUPPLY_CAP = parseUnits("20000", 18); -const vLTC_SUPPLY_CAP_PREV = parseUnits("120000", 18); -const vLTC_BORROW_CAP_PREV = parseUnits("10000", 18); -const vAAVE_BORROW_CAP_PREV = parseUnits("2000", 18); +const vAAVE_CORE_SUPPLY_CAP = parseUnits("20000", 18); +const vLTC_CORE_SUPPLY_CAP_PREV = parseUnits("120000", 18); +const vLTC_CORE_BORROW_CAP_PREV = parseUnits("10000", 18); +const vAAVE_CORE_BORROW_CAP_PREV = parseUnits("2000", 18); +const vTWT_DEFI_COLLATERAL_FACTOR_PREV = parseUnits("0.5", 18); +const vTWT_DEFI_SUPPLY_CAP_PREV = parseUnits("3000000", 18); +const vTWT_DEFI_LIQUIDATION_THRESHOLD = parseUnits("0.6", 18); +const vTWT_DEFI_BORROW_CAP = parseUnits("100000", 18); -forking(43368825, async () => { +forking(43422150, async () => { const provider = ethers.provider; - const coreComptroller = new ethers.Contract(CORE_COMPTROLLER, COMPTROLLER_ABI, provider); + const coreComptroller = new ethers.Contract(CORE_COMPTROLLER, CORE_COMPTROLLER_ABI, provider); + const defiComptroller = new ethers.Contract(DEFI_COMPTROLLER, DEFI_COMPTROLLER_ABI, provider); describe("Pre-VIP behavior", async () => { - it("check supply and borrow cap for LTC", async () => { - const supplyCap = await coreComptroller.supplyCaps(vLTC); - const borrowCap = await coreComptroller.borrowCaps(vLTC); + describe("CORE pool checks", () => { + it("check supply and borrow cap for LTC", async () => { + const supplyCap = await coreComptroller.supplyCaps(vLTC_CORE); + const borrowCap = await coreComptroller.borrowCaps(vLTC_CORE); - expect(supplyCap).to.eq(vLTC_SUPPLY_CAP_PREV); - expect(borrowCap).to.eq(vLTC_BORROW_CAP_PREV); + expect(supplyCap).to.eq(vLTC_CORE_SUPPLY_CAP_PREV); + expect(borrowCap).to.eq(vLTC_CORE_BORROW_CAP_PREV); + }); + + it("check supply and borrow cap for AAVE", async () => { + const supplyCap = await coreComptroller.supplyCaps(vAAVE_CORE); + const borrowCap = await coreComptroller.borrowCaps(vAAVE_CORE); + + expect(supplyCap).to.eq(vAAVE_CORE_SUPPLY_CAP); + expect(borrowCap).to.eq(vAAVE_CORE_BORROW_CAP_PREV); + }); }); - it("check supply and borrow cap for AAVE", async () => { - const supplyCap = await coreComptroller.supplyCaps(vAAVE); - const borrowCap = await coreComptroller.borrowCaps(vAAVE); + describe("DEFI pool", () => { + it("check supply and borrow cap for TWT", async () => { + const supplyCap = await defiComptroller.supplyCaps(vTWT_DEFI); + const borrowCap = await defiComptroller.borrowCaps(vTWT_DEFI); + + expect(supplyCap).to.eq(vTWT_DEFI_SUPPLY_CAP_PREV); + expect(borrowCap).to.eq(vTWT_DEFI_BORROW_CAP); + }); - expect(supplyCap).to.eq(vAAVE_SUPPLY_CAP); - expect(borrowCap).to.eq(vAAVE_BORROW_CAP_PREV); + it("Collateral factor and liquidation threshold for TWT", async () => { + const twtMarket = await defiComptroller.markets(vTWT_DEFI); + expect(twtMarket.collateralFactorMantissa).to.eq(vTWT_DEFI_COLLATERAL_FACTOR_PREV); + expect(twtMarket.liquidationThresholdMantissa).to.eq(vTWT_DEFI_LIQUIDATION_THRESHOLD); + }); }); }); testVip("VIP-391", await vip391(), { callbackAfterExecution: async txResponse => { - await expectEvents(txResponse, [COMPTROLLER_ABI], ["NewBorrowCap", "NewSupplyCap"], [2, 1]); + await expectEvents(txResponse, [CORE_COMPTROLLER_ABI], ["NewBorrowCap", "NewSupplyCap"], [2, 2]); }, }); describe("Post-VIP behavior", async () => { - it("check supply and borrow cap for LTC", async () => { - const supplyCap = await coreComptroller.supplyCaps(vLTC); - const borrowCap = await coreComptroller.borrowCaps(vLTC); + describe("CORE pool checks", () => { + it("check supply and borrow cap for LTC", async () => { + const supplyCap = await coreComptroller.supplyCaps(vLTC_CORE); + const borrowCap = await coreComptroller.borrowCaps(vLTC_CORE); - expect(supplyCap).to.eq(vLTC_SUPPLY_CAP); - expect(borrowCap).to.eq(vLTC_BORROW_CAP); + expect(supplyCap).to.eq(vLTC_CORE_SUPPLY_CAP); + expect(borrowCap).to.eq(vLTC_CORE_BORROW_CAP); + }); + + it("check supply and borrow cap for AAVE", async () => { + const supplyCap = await coreComptroller.supplyCaps(vAAVE_CORE); + const borrowCap = await coreComptroller.borrowCaps(vAAVE_CORE); + + expect(supplyCap).to.eq(vAAVE_CORE_SUPPLY_CAP); + expect(borrowCap).to.eq(vAAVE_CORE_BORROW_CAP); + }); }); - it("check supply and borrow cap for AAVE", async () => { - const supplyCap = await coreComptroller.supplyCaps(vAAVE); - const borrowCap = await coreComptroller.borrowCaps(vAAVE); + describe("DEFI pool", () => { + it("check supply and borrow cap for TWT", async () => { + const supplyCap = await defiComptroller.supplyCaps(vTWT_DEFI); + const borrowCap = await defiComptroller.borrowCaps(vTWT_DEFI); + + expect(supplyCap).to.eq(vTWT_DEFI_SUPPLY_CAP); + expect(borrowCap).to.eq(vTWT_DEFI_BORROW_CAP); + }); - expect(supplyCap).to.eq(vAAVE_SUPPLY_CAP); - expect(borrowCap).to.eq(vAAVE_BORROW_CAP); + it("Collateral factor and liquidation threshold for TWT", async () => { + const twtMarket = await defiComptroller.markets(vTWT_DEFI); + expect(twtMarket.collateralFactorMantissa).to.eq(vTWT_DEFI_COLLATERAL_FACTOR); + expect(twtMarket.liquidationThresholdMantissa).to.eq(vTWT_DEFI_LIQUIDATION_THRESHOLD); + }); }); }); }); diff --git a/vips/vip-391/bscmainnet.ts b/vips/vip-391/bscmainnet.ts index 2a649d3ae..5a59f6c1f 100644 --- a/vips/vip-391/bscmainnet.ts +++ b/vips/vip-391/bscmainnet.ts @@ -3,17 +3,22 @@ import { ProposalType } from "src/types"; import { makeProposal } from "src/utils"; export const CORE_COMPTROLLER = "0xfD36E2c2a6789Db23113685031d7F16329158384"; -export const vLTC = "0x57A5297F2cB2c0AaC9D554660acd6D385Ab50c6B"; -export const vAAVE = "0x26DA28954763B92139ED49283625ceCAf52C6f94"; +export const DEFI_COMPTROLLER = "0x3344417c9360b963ca93A4e8305361AEde340Ab9"; +export const vLTC_CORE = "0x57A5297F2cB2c0AaC9D554660acd6D385Ab50c6B"; +export const vAAVE_CORE = "0x26DA28954763B92139ED49283625ceCAf52C6f94"; +export const vTWT_DEFI = "0x736bf1D21A28b5DC19A1aC8cA71Fc2856C23c03F"; -export const vLTC_SUPPLY_CAP = parseUnits("240000", 18); -export const vLTC_BORROW_CAP = parseUnits("20000", 18); -export const vAAVE_BORROW_CAP = parseUnits("3000", 18); +export const vLTC_CORE_SUPPLY_CAP = parseUnits("240000", 18); +export const vLTC_CORE_BORROW_CAP = parseUnits("20000", 18); +export const vAAVE_CORE_BORROW_CAP = parseUnits("3000", 18); +export const vTWT_DEFI_SUPPLY_CAP = parseUnits("700000", 18); +export const vTWT_DEFI_COLLATERAL_FACTOR = 0; +export const vTWT_DEFI_LIQUIDATION_THRESHOLD = parseUnits("0.6", 18); export const vip391 = () => { const meta = { version: "v2", - title: "VIP-391 Risk Parameters Adjustment (LTC, AAVE)", + title: "VIP-391 Risk Parameters Adjustment (LTC, AAVE on Core pool and TWT on Defi pool)", description: `If passed, this VIP will perform the following actions as per Chaos Labs’ latest recommendations in this Venus community forum publication. It would update the following caps on BNB Chain, following this forum publication: [Chaos Labs - ] @@ -23,6 +28,9 @@ It would update the following caps on BNB Chain, following this forum publicatio - increase borrow cap from 10K LTC to 20K LTC - [AAVE (Core pool)](https://bscscan.com/address/0x26DA28954763B92139ED49283625ceCAf52C6f94): - increase borrow cap from 2K AAVE to 3K AAVE +- [TWT (Defi pool)](https://bscscan.com/address/0x736bf1D21A28b5DC19A1aC8cA71Fc2856C23c03F): + - decrease collateral factor from 50% to 0% + - increase supply cap from 300K TWT to 700K TWT Review the Chaos Labs’ recommendations for a deeper analysis. @@ -38,16 +46,26 @@ VIP simulation: { target: CORE_COMPTROLLER, signature: "_setMarketSupplyCaps(address[],uint256[])", - params: [[vLTC], [vLTC_SUPPLY_CAP]], + params: [[vLTC_CORE], [vLTC_CORE_SUPPLY_CAP]], }, { target: CORE_COMPTROLLER, signature: "_setMarketBorrowCaps(address[],uint256[])", params: [ - [vLTC, vAAVE], - [vLTC_BORROW_CAP, vAAVE_BORROW_CAP], + [vLTC_CORE, vAAVE_CORE], + [vLTC_CORE_BORROW_CAP, vAAVE_CORE_BORROW_CAP], ], }, + { + target: DEFI_COMPTROLLER, + signature: "setMarketSupplyCaps(address[],uint256[])", + params: [[vTWT_DEFI], [vTWT_DEFI_SUPPLY_CAP]], + }, + { + target: DEFI_COMPTROLLER, + signature: "setCollateralFactor(address,uint256,uint256)", + params: [vTWT_DEFI, vTWT_DEFI_COLLATERAL_FACTOR, vTWT_DEFI_LIQUIDATION_THRESHOLD], + }, ], meta, ProposalType.FAST_TRACK, From 91823aebd48b634c2c9374819438f76279f06354 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Fri, 25 Oct 2024 12:54:00 +0200 Subject: [PATCH 064/178] feat: set ID and description for the VIP 388 --- .../abi/CoreComptroller.json | 0 .../abi/DefiComptroller.json | 0 .../{vip-391 => vip-388}/bscmainnet.ts | 6 ++-- vips/{vip-391 => vip-388}/bscmainnet.ts | 30 ++++++++++--------- 4 files changed, 19 insertions(+), 17 deletions(-) rename simulations/{vip-391 => vip-388}/abi/CoreComptroller.json (100%) rename simulations/{vip-391 => vip-388}/abi/DefiComptroller.json (100%) rename simulations/{vip-391 => vip-388}/bscmainnet.ts (98%) rename vips/{vip-391 => vip-388}/bscmainnet.ts (70%) diff --git a/simulations/vip-391/abi/CoreComptroller.json b/simulations/vip-388/abi/CoreComptroller.json similarity index 100% rename from simulations/vip-391/abi/CoreComptroller.json rename to simulations/vip-388/abi/CoreComptroller.json diff --git a/simulations/vip-391/abi/DefiComptroller.json b/simulations/vip-388/abi/DefiComptroller.json similarity index 100% rename from simulations/vip-391/abi/DefiComptroller.json rename to simulations/vip-388/abi/DefiComptroller.json diff --git a/simulations/vip-391/bscmainnet.ts b/simulations/vip-388/bscmainnet.ts similarity index 98% rename from simulations/vip-391/bscmainnet.ts rename to simulations/vip-388/bscmainnet.ts index 05c306aa5..a1d805ddf 100644 --- a/simulations/vip-391/bscmainnet.ts +++ b/simulations/vip-388/bscmainnet.ts @@ -15,8 +15,8 @@ import { vTWT_DEFI, vTWT_DEFI_COLLATERAL_FACTOR, vTWT_DEFI_SUPPLY_CAP, - vip391, -} from "../../vips/vip-391/bscmainnet"; + vip388, +} from "../../vips/vip-388/bscmainnet"; import CORE_COMPTROLLER_ABI from "./abi/CoreComptroller.json"; import DEFI_COMPTROLLER_ABI from "./abi/CoreComptroller.json"; @@ -70,7 +70,7 @@ forking(43422150, async () => { }); }); - testVip("VIP-391", await vip391(), { + testVip("VIP-388", await vip388(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [CORE_COMPTROLLER_ABI], ["NewBorrowCap", "NewSupplyCap"], [2, 2]); }, diff --git a/vips/vip-391/bscmainnet.ts b/vips/vip-388/bscmainnet.ts similarity index 70% rename from vips/vip-391/bscmainnet.ts rename to vips/vip-388/bscmainnet.ts index 5a59f6c1f..d61c09f0a 100644 --- a/vips/vip-391/bscmainnet.ts +++ b/vips/vip-388/bscmainnet.ts @@ -15,27 +15,29 @@ export const vTWT_DEFI_SUPPLY_CAP = parseUnits("700000", 18); export const vTWT_DEFI_COLLATERAL_FACTOR = 0; export const vTWT_DEFI_LIQUIDATION_THRESHOLD = parseUnits("0.6", 18); -export const vip391 = () => { +export const vip388 = () => { const meta = { version: "v2", - title: "VIP-391 Risk Parameters Adjustment (LTC, AAVE on Core pool and TWT on Defi pool)", - description: `If passed, this VIP will perform the following actions as per Chaos Labs’ latest recommendations in this Venus community forum publication. + title: "VIP-388 [BNB Chain] Risk Parameters Adjustments (LTC, AAVE, TWT)", + description: `If passed, this VIP will perform the following actions as per Chaos Labs’ latest recommendations in this Venus community forum publication: -It would update the following caps on BNB Chain, following this forum publication: [Chaos Labs - ] +[Chaos Labs - Risk Parameter Updates - 10/23/24](https://community.venus.io/t/chaos-labs-risk-parameter-updates-10-23-24/4668) - [LTC (Core pool)](https://bscscan.com/address/0x57A5297F2cB2c0AaC9D554660acd6D385Ab50c6B): - - increase supply cap from 120K LTC to 240K LTC - - increase borrow cap from 10K LTC to 20K LTC + - Increase supply cap, from 120K LTC to 240K LTC + - Increase borrow cap, from 10K LTC to 20K LTC - [AAVE (Core pool)](https://bscscan.com/address/0x26DA28954763B92139ED49283625ceCAf52C6f94): - - increase borrow cap from 2K AAVE to 3K AAVE -- [TWT (Defi pool)](https://bscscan.com/address/0x736bf1D21A28b5DC19A1aC8cA71Fc2856C23c03F): - - decrease collateral factor from 50% to 0% - - increase supply cap from 300K TWT to 700K TWT + - Increase borrow cap, from 2K AAVE to 3K AAVE -Review the Chaos Labs’ recommendations for a deeper analysis. +[TWT Migration Specifications](https://community.venus.io/t/chaos-labs-risk-parameter-updates-10-08-24/4606/7) -VIP simulation: -`, +- [TWT (DeFi pool)](https://bscscan.com/address/0x736bf1D21A28b5DC19A1aC8cA71Fc2856C23c03F): + - Set collateral factor to 0% (from 50%). Keep the liquidation threshold at 60% + - Decrease supply cap, from 3M TWT to 700K TWT + +Complete analysis and details of these recommendations are available in the above publications. + +VIP simulation: [https://github.com/VenusProtocol/vips/pull/415](https://github.com/VenusProtocol/vips/pull/415)`, forDescription: "Execute this proposal", againstDescription: "Do not execute this proposal", abstainDescription: "Indifferent to execution", @@ -72,4 +74,4 @@ VIP simulation: ); }; -export default vip391; +export default vip388; From 9e732e9be4d5ea820376126121f4e40602bb22bb Mon Sep 17 00:00:00 2001 From: web3rover Date: Fri, 25 Oct 2024 18:44:59 +0400 Subject: [PATCH 065/178] fix: added mainnet vip --- simulations/vip-371/arbitrumone.ts | 46 +++++++++++++++++ simulations/vip-371/bscmainnet.ts | 17 +++++++ simulations/vip-371/opbnbmainnet.ts | 46 +++++++++++++++++ vips/vip-371/bscmainnet.ts | 77 +++++++++++++++++++++++++++++ 4 files changed, 186 insertions(+) create mode 100644 simulations/vip-371/arbitrumone.ts create mode 100644 simulations/vip-371/bscmainnet.ts create mode 100644 simulations/vip-371/opbnbmainnet.ts create mode 100644 vips/vip-371/bscmainnet.ts diff --git a/simulations/vip-371/arbitrumone.ts b/simulations/vip-371/arbitrumone.ts new file mode 100644 index 000000000..db4c76796 --- /dev/null +++ b/simulations/vip-371/arbitrumone.ts @@ -0,0 +1,46 @@ +import { expect } from "chai"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; +import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip371, { ARBITRUM_ACM_AGGREGATOR, DEFAULT_ADMIN_ROLE } from "../../vips/vip-371/bscmainnet"; +import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; + +const { arbitrumone } = NETWORK_ADDRESSES; +const ACM = "0xD9dD18EB0cf10CbA837677f28A8F9Bda4bc2b157"; + +forking(267530159, async () => { + testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [190]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [52]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); + }, + }); + + describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); + + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, ARBITRUM_ACM_AGGREGATOR)).to.be.false; + }); + + it("check few permissions", async () => { + const role1 = ethers.utils.solidityPack(["address", "string"], [arbitrumone.RESILIENT_ORACLE, "pause()"]); + + const roleHash = ethers.utils.keccak256(role1); + expect(await acm.hasRole(roleHash, arbitrumone.NORMAL_TIMELOCK)).to.be.true; + + const role2 = ethers.utils.solidityPack( + ["address", "string"], + [arbitrumone.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], + ); + + const roleHash2 = ethers.utils.keccak256(role2); + expect(await acm.hasRole(roleHash2, arbitrumone.NORMAL_TIMELOCK)).to.be.true; + }); + }); +}); diff --git a/simulations/vip-371/bscmainnet.ts b/simulations/vip-371/bscmainnet.ts new file mode 100644 index 000000000..2f9aa2b7a --- /dev/null +++ b/simulations/vip-371/bscmainnet.ts @@ -0,0 +1,17 @@ +import { expectEvents } from "../../src/utils"; +import { forking, testVip } from "../../src/vip-framework"; +import vip371 from "../../vips/vip-371/bscmainnet"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +forking(43428406, async () => { + testVip("vip371 XVS vault permission proposal", await vip371(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [2, 0], + ); + }, + }); +}); diff --git a/simulations/vip-371/opbnbmainnet.ts b/simulations/vip-371/opbnbmainnet.ts new file mode 100644 index 000000000..43c888575 --- /dev/null +++ b/simulations/vip-371/opbnbmainnet.ts @@ -0,0 +1,46 @@ +import { expect } from "chai"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; +import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip371, { DEFAULT_ADMIN_ROLE, OPBNBMAINNET_ACM_AGGREGATOR } from "../../vips/vip-371/bscmainnet"; +import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; + +const { opbnbmainnet } = NETWORK_ADDRESSES; +const ACM = "0xA60Deae5344F1152426cA440fb6552eA0e3005D6"; + +forking(38111847, async () => { + testForkedNetworkVipCommands("vip371", await vip371(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [140]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [35]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); + }, + }); + + describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); + + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBMAINNET_ACM_AGGREGATOR)).to.be.false; + }); + + it("check few permissions", async () => { + const role1 = ethers.utils.solidityPack(["address", "string"], [opbnbmainnet.RESILIENT_ORACLE, "pause()"]); + + const roleHash = ethers.utils.keccak256(role1); + expect(await acm.hasRole(roleHash, opbnbmainnet.NORMAL_TIMELOCK)).to.be.true; + + const role2 = ethers.utils.solidityPack( + ["address", "string"], + [opbnbmainnet.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], + ); + + const roleHash2 = ethers.utils.keccak256(role2); + expect(await acm.hasRole(roleHash2, opbnbmainnet.NORMAL_TIMELOCK)).to.be.true; + }); + }); +}); diff --git a/vips/vip-371/bscmainnet.ts b/vips/vip-371/bscmainnet.ts new file mode 100644 index 000000000..7aa7a8b74 --- /dev/null +++ b/vips/vip-371/bscmainnet.ts @@ -0,0 +1,77 @@ +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const ARBITRUM_ACM = "0xD9dD18EB0cf10CbA837677f28A8F9Bda4bc2b157"; +export const OPBNBMAINNET_ACM = "0xA60Deae5344F1152426cA440fb6552eA0e3005D6"; + +export const ARBITRUM_ACM_AGGREGATOR = "0x74AFeA28456a683b8fF907699Ff77138edef00f3"; +export const OPBNBMAINNET_ACM_AGGREGATOR = "0x6dB5e303289fea2E83F7d442470210045592AD93"; + +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + +const vip371 = () => { + const meta = { + version: "v2", + title: "VIP-371 grant Timelocks and revoke permissions for Guardian in Arbitrum, opBNB and Ethereum", + description: `### Description`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: ARBITRUM_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ARBITRUM_ACM_AGGREGATOR], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ARBITRUM_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ARBITRUM_ACM_AGGREGATOR, + signature: "executeRevokePermissions(uint256)", + params: [0], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ARBITRUM_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ARBITRUM_ACM_AGGREGATOR], + dstChainId: LzChainId.arbitrumone, + }, + + { + target: OPBNBMAINNET_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPBNBMAINNET_ACM_AGGREGATOR], + dstChainId: LzChainId.opbnbmainnet, + }, + { + target: OPBNBMAINNET_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.opbnbmainnet, + }, + { + target: OPBNBMAINNET_ACM_AGGREGATOR, + signature: "executeRevokePermissions(uint256)", + params: [0], + dstChainId: LzChainId.opbnbmainnet, + }, + { + target: OPBNBMAINNET_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPBNBMAINNET_ACM_AGGREGATOR], + dstChainId: LzChainId.opbnbmainnet, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip371; From f0f1192e7971c50ae7defedb0bfd60bc9ae9968c Mon Sep 17 00:00:00 2001 From: web3rover Date: Fri, 25 Oct 2024 19:04:29 +0400 Subject: [PATCH 066/178] fix: ethereum vip --- simulations/vip-371/bscmainnet.ts | 2 +- simulations/vip-371/ethereum.ts | 45 +++++++++++++++++++++++++++++++ vips/vip-371/bscmainnet.ts | 33 +++++++++++++++++++++++ 3 files changed, 79 insertions(+), 1 deletion(-) create mode 100644 simulations/vip-371/ethereum.ts diff --git a/simulations/vip-371/bscmainnet.ts b/simulations/vip-371/bscmainnet.ts index 2f9aa2b7a..89e8b7c94 100644 --- a/simulations/vip-371/bscmainnet.ts +++ b/simulations/vip-371/bscmainnet.ts @@ -10,7 +10,7 @@ forking(43428406, async () => { txResponse, [OMNICHAIN_PROPOSAL_SENDER_ABI], ["ExecuteRemoteProposal", "StorePayload"], - [2, 0], + [3, 0], ); }, }); diff --git a/simulations/vip-371/ethereum.ts b/simulations/vip-371/ethereum.ts new file mode 100644 index 000000000..fbf4509b7 --- /dev/null +++ b/simulations/vip-371/ethereum.ts @@ -0,0 +1,45 @@ +import { expect } from "chai"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; +import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip371, { DEFAULT_ADMIN_ROLE, ETHEREUM_ACM_AGGREGATOR } from "../../vips/vip-371/bscmainnet"; +import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; + +const { ethereum } = NETWORK_ADDRESSES; +const ACM = "0x230058da2D23eb8836EC5DB7037ef7250c56E25E"; + +forking(21043354, async () => { + testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [214]); + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [67]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [2]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["RevokePermissionsExecuted"], [1]); + }, + }); + + describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, ETHEREUM_ACM_AGGREGATOR)).to.be.false; + }); + + it("check few permissions", async () => { + const role1 = ethers.utils.solidityPack(["address", "string"], [ethereum.RESILIENT_ORACLE, "pause()"]); + + const roleHash = ethers.utils.keccak256(role1); + expect(await acm.hasRole(roleHash, ethereum.NORMAL_TIMELOCK)).to.be.true; + + const role2 = ethers.utils.solidityPack( + ["address", "string"], + [ethereum.XVS_VAULT_PROXY, "set(address,uint256,uint256)"], + ); + + const roleHash2 = ethers.utils.keccak256(role2); + expect(await acm.hasRole(roleHash2, ethereum.NORMAL_TIMELOCK)).to.be.true; + }); + }); +}); diff --git a/vips/vip-371/bscmainnet.ts b/vips/vip-371/bscmainnet.ts index 7aa7a8b74..8f9184b6f 100644 --- a/vips/vip-371/bscmainnet.ts +++ b/vips/vip-371/bscmainnet.ts @@ -3,9 +3,11 @@ import { makeProposal } from "src/utils"; export const ARBITRUM_ACM = "0xD9dD18EB0cf10CbA837677f28A8F9Bda4bc2b157"; export const OPBNBMAINNET_ACM = "0xA60Deae5344F1152426cA440fb6552eA0e3005D6"; +export const ETHEREUM_ACM = "0x230058da2D23eb8836EC5DB7037ef7250c56E25E"; export const ARBITRUM_ACM_AGGREGATOR = "0x74AFeA28456a683b8fF907699Ff77138edef00f3"; export const OPBNBMAINNET_ACM_AGGREGATOR = "0x6dB5e303289fea2E83F7d442470210045592AD93"; +export const ETHEREUM_ACM_AGGREGATOR = "0xb78772bed6995551b64e54Cdb8e09800d86C73ee"; export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; @@ -69,6 +71,37 @@ const vip371 = () => { params: [DEFAULT_ADMIN_ROLE, OPBNBMAINNET_ACM_AGGREGATOR], dstChainId: LzChainId.opbnbmainnet, }, + + { + target: ETHEREUM_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ETHEREUM_ACM_AGGREGATOR], + dstChainId: LzChainId.ethereum, + }, + { + target: ETHEREUM_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.ethereum, + }, + { + target: ETHEREUM_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [1], + dstChainId: LzChainId.ethereum, + }, + { + target: ETHEREUM_ACM_AGGREGATOR, + signature: "executeRevokePermissions(uint256)", + params: [0], + dstChainId: LzChainId.ethereum, + }, + { + target: ETHEREUM_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ETHEREUM_ACM_AGGREGATOR], + dstChainId: LzChainId.ethereum, + }, ], meta, ProposalType.REGULAR, From 3ccdd7491a4d760f8666cc602c2032d779102d04 Mon Sep 17 00:00:00 2001 From: web3rover Date: Mon, 28 Oct 2024 12:32:44 +0400 Subject: [PATCH 067/178] fix: added additional simulations --- simulations/vip-371/arbitrumone.ts | 18 ++++++++++++++++++ simulations/vip-371/ethereum.ts | 15 +++++++++++++++ simulations/vip-371/opbnbmainnet.ts | 18 ++++++++++++++++++ 3 files changed, 51 insertions(+) diff --git a/simulations/vip-371/arbitrumone.ts b/simulations/vip-371/arbitrumone.ts index db4c76796..e1491a3b4 100644 --- a/simulations/vip-371/arbitrumone.ts +++ b/simulations/vip-371/arbitrumone.ts @@ -10,6 +10,8 @@ import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { arbitrumone } = NETWORK_ADDRESSES; const ACM = "0xD9dD18EB0cf10CbA837677f28A8F9Bda4bc2b157"; +const FAST_TRACK_TIMELOCK = "0x2286a9B2a5246218f2fC1F380383f45BDfCE3E04"; +const CRITICAL_TIMELOCK = "0x181E4f8F21D087bF02Ea2F64D5e550849FBca674"; forking(267530159, async () => { testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { @@ -41,6 +43,22 @@ forking(267530159, async () => { const roleHash2 = ethers.utils.keccak256(role2); expect(await acm.hasRole(roleHash2, arbitrumone.NORMAL_TIMELOCK)).to.be.true; + + const role3 = ethers.utils.solidityPack( + ["address", "string"], + [arbitrumone.XVS, "migrateMinterTokens(address,address)"], + ); + + const roleHash3 = ethers.utils.keccak256(role3); + expect(await acm.hasRole(roleHash3, FAST_TRACK_TIMELOCK)).to.be.true; + + const role4 = ethers.utils.solidityPack( + ["address", "string"], + [arbitrumone.XVS, "updateBlacklist(address,bool)"], + ); + + const roleHash4 = ethers.utils.keccak256(role4); + expect(await acm.hasRole(roleHash4, CRITICAL_TIMELOCK)).to.be.true; }); }); }); diff --git a/simulations/vip-371/ethereum.ts b/simulations/vip-371/ethereum.ts index fbf4509b7..f19da2827 100644 --- a/simulations/vip-371/ethereum.ts +++ b/simulations/vip-371/ethereum.ts @@ -10,6 +10,8 @@ import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { ethereum } = NETWORK_ADDRESSES; const ACM = "0x230058da2D23eb8836EC5DB7037ef7250c56E25E"; +const FAST_TRACK_TIMELOCK = "0x8764F50616B62a99A997876C2DEAaa04554C5B2E"; +const CRITICAL_TIMELOCK = "0xeB9b85342c34F65af734C7bd4a149c86c472bC00"; forking(21043354, async () => { testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { @@ -40,6 +42,19 @@ forking(21043354, async () => { const roleHash2 = ethers.utils.keccak256(role2); expect(await acm.hasRole(roleHash2, ethereum.NORMAL_TIMELOCK)).to.be.true; + + const role3 = ethers.utils.solidityPack( + ["address", "string"], + [ethereum.XVS, "migrateMinterTokens(address,address)"], + ); + + const roleHash3 = ethers.utils.keccak256(role3); + expect(await acm.hasRole(roleHash3, FAST_TRACK_TIMELOCK)).to.be.true; + + const role4 = ethers.utils.solidityPack(["address", "string"], [ethereum.XVS, "updateBlacklist(address,bool)"]); + + const roleHash4 = ethers.utils.keccak256(role4); + expect(await acm.hasRole(roleHash4, CRITICAL_TIMELOCK)).to.be.true; }); }); }); diff --git a/simulations/vip-371/opbnbmainnet.ts b/simulations/vip-371/opbnbmainnet.ts index 43c888575..21d9b96aa 100644 --- a/simulations/vip-371/opbnbmainnet.ts +++ b/simulations/vip-371/opbnbmainnet.ts @@ -10,6 +10,8 @@ import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; const { opbnbmainnet } = NETWORK_ADDRESSES; const ACM = "0xA60Deae5344F1152426cA440fb6552eA0e3005D6"; +const FAST_TRACK_TIMELOCK = "0xEdD04Ecef0850e834833789576A1d435e7207C0d"; +const CRITICAL_TIMELOCK = "0xA7DD2b15B24377296F11c702e758cd9141AB34AA"; forking(38111847, async () => { testForkedNetworkVipCommands("vip371", await vip371(), { @@ -41,6 +43,22 @@ forking(38111847, async () => { const roleHash2 = ethers.utils.keccak256(role2); expect(await acm.hasRole(roleHash2, opbnbmainnet.NORMAL_TIMELOCK)).to.be.true; + + const role3 = ethers.utils.solidityPack( + ["address", "string"], + [opbnbmainnet.XVS, "migrateMinterTokens(address,address)"], + ); + + const roleHash3 = ethers.utils.keccak256(role3); + expect(await acm.hasRole(roleHash3, FAST_TRACK_TIMELOCK)).to.be.true; + + const role4 = ethers.utils.solidityPack( + ["address", "string"], + [opbnbmainnet.XVS, "updateBlacklist(address,bool)"], + ); + + const roleHash4 = ethers.utils.keccak256(role4); + expect(await acm.hasRole(roleHash4, CRITICAL_TIMELOCK)).to.be.true; }); }); }); From 4abee281b86502750220bcda8a4c261559ef4f4a Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Mon, 28 Oct 2024 19:45:44 +0530 Subject: [PATCH 068/178] refactor: update vip number --- .../proposals/arbitrumsepolia/{vip-016 => vip-014}/index.ts | 4 ++-- .../arbitrumsepolia/{vip-016 => vip-014}/abi/xvs.json | 0 .../{vip-016 => vip-014}/abi/xvsProxyOFTDest.json | 0 .../arbitrumsepolia/{vip-016 => vip-014}/index.ts | 6 +++--- 4 files changed, 5 insertions(+), 5 deletions(-) rename multisig/proposals/arbitrumsepolia/{vip-016 => vip-014}/index.ts (97%) rename multisig/simulations/arbitrumsepolia/{vip-016 => vip-014}/abi/xvs.json (100%) rename multisig/simulations/arbitrumsepolia/{vip-016 => vip-014}/abi/xvsProxyOFTDest.json (100%) rename multisig/simulations/arbitrumsepolia/{vip-016 => vip-014}/index.ts (97%) diff --git a/multisig/proposals/arbitrumsepolia/vip-016/index.ts b/multisig/proposals/arbitrumsepolia/vip-014/index.ts similarity index 97% rename from multisig/proposals/arbitrumsepolia/vip-016/index.ts rename to multisig/proposals/arbitrumsepolia/vip-014/index.ts index 638d9e7b9..43560a24f 100644 --- a/multisig/proposals/arbitrumsepolia/vip-016/index.ts +++ b/multisig/proposals/arbitrumsepolia/vip-014/index.ts @@ -11,7 +11,7 @@ export const SINGLE_RECEIVE_LIMIT = parseUnits("10200", 18); export const MAX_DAILY_RECEIVE_LIMIT = parseUnits("51000", 18); export const OP_SEPOLIA_TRUSTED_REMOTE = "0x79a36dc9a43d05db4747c59c02f48ed500e47df1"; -const vip016 = () => { +const vip014 = () => { return makeProposal([ { target: XVS_BRIDGE_ADMIN, @@ -46,4 +46,4 @@ const vip016 = () => { ]); }; -export default vip016; +export default vip014; diff --git a/multisig/simulations/arbitrumsepolia/vip-016/abi/xvs.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/xvs.json similarity index 100% rename from multisig/simulations/arbitrumsepolia/vip-016/abi/xvs.json rename to multisig/simulations/arbitrumsepolia/vip-014/abi/xvs.json diff --git a/multisig/simulations/arbitrumsepolia/vip-016/abi/xvsProxyOFTDest.json b/multisig/simulations/arbitrumsepolia/vip-014/abi/xvsProxyOFTDest.json similarity index 100% rename from multisig/simulations/arbitrumsepolia/vip-016/abi/xvsProxyOFTDest.json rename to multisig/simulations/arbitrumsepolia/vip-014/abi/xvsProxyOFTDest.json diff --git a/multisig/simulations/arbitrumsepolia/vip-016/index.ts b/multisig/simulations/arbitrumsepolia/vip-014/index.ts similarity index 97% rename from multisig/simulations/arbitrumsepolia/vip-016/index.ts rename to multisig/simulations/arbitrumsepolia/vip-014/index.ts index f735cd0da..3dd9c55c3 100644 --- a/multisig/simulations/arbitrumsepolia/vip-016/index.ts +++ b/multisig/simulations/arbitrumsepolia/vip-014/index.ts @@ -7,13 +7,13 @@ import { LzChainId } from "src/types"; import { initMainnetUser } from "src/utils"; import { forking, pretendExecutingVip } from "src/vip-framework"; -import vip016, { +import vip014, { MAX_DAILY_RECEIVE_LIMIT, MAX_DAILY_SEND_LIMIT, OP_SEPOLIA_TRUSTED_REMOTE, SINGLE_RECEIVE_LIMIT, SINGLE_SEND_LIMIT, -} from "../../../proposals/arbitrumsepolia/vip-016"; +} from "../../../proposals/arbitrumsepolia/vip-014"; import XVS_ABI from "./abi/xvs.json"; import XVS_BRIDGE_ABI from "./abi/xvsProxyOFTDest.json"; @@ -40,7 +40,7 @@ forking(79930177, async () => { describe("Post-Execution state", () => { before(async () => { - await pretendExecutingVip(await vip016()); + await pretendExecutingVip(await vip014()); }); it("Should match trusted remote address", async () => { From f74cd588e7b253e841a193417088b00da2c36214 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Mon, 28 Oct 2024 19:46:41 +0530 Subject: [PATCH 069/178] feat: add market to prime on arbitrum sepolia --- .../arbitrumsepolia/vip-015/index.ts | 65 + .../vip-015/abi/ILComptroller.json | 929 ++++++++++ .../arbitrumsepolia/vip-015/abi/Prime.json | 1551 +++++++++++++++++ .../vip-015/abi/PrimeLiquidityProvider.json | 385 ++++ .../arbitrumsepolia/vip-015/index.ts | 91 + 5 files changed, 3021 insertions(+) create mode 100644 multisig/proposals/arbitrumsepolia/vip-015/index.ts create mode 100644 multisig/simulations/arbitrumsepolia/vip-015/abi/ILComptroller.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-015/abi/Prime.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-015/abi/PrimeLiquidityProvider.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-015/index.ts diff --git a/multisig/proposals/arbitrumsepolia/vip-015/index.ts b/multisig/proposals/arbitrumsepolia/vip-015/index.ts new file mode 100644 index 000000000..320f30898 --- /dev/null +++ b/multisig/proposals/arbitrumsepolia/vip-015/index.ts @@ -0,0 +1,65 @@ +import { ethers } from "hardhat"; +import { makeProposal } from "src/utils"; + +export const COMPTROLLER_CORE = "0x006D44b6f5927b3eD83bD0c1C36Fb1A3BaCaC208"; +export const COMPTROLLER_LST = "0x3D04F926b2a165BBa17FBfccCCB61513634fa5e4"; +export const PRIME = "0xAdB04AC4942683bc41E27d18234C8DC884786E89"; +export const PLP = "0xE82c2c10F55D3268126C29ec813dC6F086904694"; + +export const USDT = "0xf3118a17863996B9F2A073c9A66Faaa664355cf8"; +export const USDC = "0x86f096B1D970990091319835faF3Ee011708eAe8"; +export const WBTC = "0xFb8d93FD3Cf18386a5564bb5619cD1FdB130dF7D"; +export const WETH = "0x980B62Da83eFf3D4576C647993b0c1D7faf17c73"; + +export const VUSDT_CORE = "0xdEFbf0F9Ab6CdDd0a1FdDC894b358D0c0a39B052"; +export const VUSDC_CORE = "0xd9d1e754464eFc7493B177d2c7be04816E089b4C"; +export const VWBTC_CORE = "0x49FB90A5815904649C44B87001a160C1301D6a2C"; +export const VWETH_LST = "0xd7057250b439c0849377bB6C3263eb8f9cf49d98"; + +const vip015 = () => { + return makeProposal([ + { + target: PLP, + signature: "initializeTokens(address[])", + params: [[WETH, WBTC, USDC, USDT]], + }, + { + target: PLP, + signature: "setTokensDistributionSpeed(address[],uint256[])", + params: [ + [WETH, WBTC, USDC, USDT], + [0, 0, 0, 0], + ], + }, + { + target: PRIME, + signature: "addMarket(address,address,uint256,uint256)", + params: [COMPTROLLER_CORE, VWBTC_CORE, ethers.utils.parseEther("2"), ethers.utils.parseEther("4")], + }, + { + target: PRIME, + signature: "addMarket(address,address,uint256,uint256)", + params: [COMPTROLLER_CORE, VUSDC_CORE, ethers.utils.parseEther("2"), ethers.utils.parseEther("4")], + }, + { + target: PRIME, + signature: "addMarket(address,address,uint256,uint256)", + params: [COMPTROLLER_CORE, VUSDT_CORE, ethers.utils.parseEther("2"), ethers.utils.parseEther("4")], + }, + { + target: PRIME, + signature: "addMarket(address,address,uint256,uint256)", + params: [COMPTROLLER_LST, VWETH_LST, ethers.utils.parseEther("2"), ethers.utils.parseEther("4")], + }, + { + target: PRIME, + signature: "setLimit(uint256,uint256)", + params: [ + 0, // irrevocable + 500, // revocable + ], + }, + ]); +}; + +export default vip015; diff --git a/multisig/simulations/arbitrumsepolia/vip-015/abi/ILComptroller.json b/multisig/simulations/arbitrumsepolia/vip-015/abi/ILComptroller.json new file mode 100644 index 000000000..56890d9b3 --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-015/abi/ILComptroller.json @@ -0,0 +1,929 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum ComptrollerStorage.Action", "name": "action", "type": "uint8" } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, + { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, + { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, + { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, + { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, + { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "TooMuchRepay", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "expectedSender", "type": "address" }, + { "internalType": "address", "name": "actualSender", "type": "address" } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "enum ComptrollerStorage.Action", "name": "action", "type": "uint8" }, + { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "accountAssets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum ComptrollerStorage.Action", "name": "action", "type": "uint8" } + ], + "name": "actionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allMarkets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "approvedDelegates", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "borrowCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "contract VToken", "name": "vToken", "type": "address" } + ], + "name": "checkMembership", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], + "name": "enterMarkets", + "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], + "name": "exitMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAssetsIn", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getBorrowingPower", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "vTokenModify", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isForcedLiquidationEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "isMarketListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [ + { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "bool", "name": "isListed", "type": "bool" }, + { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "seizerContract", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, + { "internalType": "enum ComptrollerStorage.Action[]", "name": "actionsList", "type": "uint8[]" }, + { "internalType": "bool", "name": "paused", "type": "bool" } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "supplyCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "delegate", "type": "address" }, + { "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-015/abi/Prime.json b/multisig/simulations/arbitrumsepolia/vip-015/abi/Prime.json new file mode 100644 index 000000000..971299cad --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-015/abi/Prime.json @@ -0,0 +1,1551 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "_wbnb", + "type": "address" + }, + { + "internalType": "address", + "name": "_vbnb", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_blocksPerYear", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_stakingPeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_minimumStakedXVS", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_maximumXVSCap", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [], + "name": "AssetAlreadyExists", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "int256", + "name": "x", + "type": "int256" + } + ], + "name": "ExpTooLarge", + "type": "error" + }, + { + "inputs": [], + "name": "IneligibleToClaim", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidAddress", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidAlphaArguments", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidBlocksPerYear", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidCaller", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidComptroller", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidFixedPoint", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "n", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "d", + "type": "uint256" + } + ], + "name": "InvalidFraction", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidLength", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidLimit", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidVToken", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "int256", + "name": "x", + "type": "int256" + } + ], + "name": "LnNonRealResult", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "int256", + "name": "x", + "type": "int256" + } + ], + "name": "LnTooLarge", + "type": "error" + }, + { + "inputs": [], + "name": "MarketAlreadyExists", + "type": "error" + }, + { + "inputs": [], + "name": "MarketNotSupported", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "loopsLimit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "requiredLoops", + "type": "uint256" + } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [], + "name": "NoScoreUpdatesRequired", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "UserHasNoPrimeToken", + "type": "error" + }, + { + "inputs": [], + "name": "WaitMoreTime", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint128", + "name": "oldNumerator", + "type": "uint128" + }, + { + "indexed": true, + "internalType": "uint128", + "name": "oldDenominator", + "type": "uint128" + }, + { + "indexed": true, + "internalType": "uint128", + "name": "newNumerator", + "type": "uint128" + }, + { + "indexed": false, + "internalType": "uint128", + "name": "newDenominator", + "type": "uint128" + } + ], + "name": "AlphaUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "Burn", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "InterestClaimed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "supplyMultiplier", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "borrowMultiplier", + "type": "uint256" + } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMaxLoopsLimit", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newmaxLoopsLimit", + "type": "uint256" + } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "isIrrevocable", + "type": "bool" + } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "oldIrrevocableLimit", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "oldRevocableLimit", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "newIrrevocableLimit", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newRevocableLimit", + "type": "uint256" + } + ], + "name": "MintLimitsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "oldSupplyMultiplier", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "oldBorrowMultiplier", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSupplyMultiplier", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newBorrowMultiplier", + "type": "uint256" + } + ], + "name": "MultiplierUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "timestamp", + "type": "uint256" + } + ], + "name": "StakedAtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "TokenUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "UserScoreUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "BLOCKS_PER_YEAR", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MAXIMUM_XVS_CAP", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MINIMUM_STAKED_XVS", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "STAKING_PERIOD", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "VBNB", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WBNB", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "accrueInterest", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "accrueInterestAndUpdateScore", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "supplyMultiplier", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowMultiplier", + "type": "uint256" + } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "alphaDenominator", + "outputs": [ + { + "internalType": "uint128", + "name": "", + "type": "uint128" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "alphaNumerator", + "outputs": [ + { + "internalType": "uint128", + "name": "", + "type": "uint128" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "calculateAPR", + "outputs": [ + { + "internalType": "uint256", + "name": "supplyAPR", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAPR", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "claim", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "claimInterest", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "claimInterest", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "claimTimeRemaining", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrow", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supply", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "xvsStaked", + "type": "uint256" + } + ], + "name": "estimateAPR", + "outputs": [ + { + "internalType": "uint256", + "name": "supplyAPR", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAPR", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [ + { + "internalType": "address[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "getInterestAccrued", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "getPendingInterests", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "internalType": "struct PrimeStorageV1.PendingInterest[]", + "name": "pendingInterests", + "type": "tuple[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "xvsVault_", + "type": "address" + }, + { + "internalType": "address", + "name": "xvsVaultRewardToken_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "xvsVaultPoolId_", + "type": "uint256" + }, + { + "internalType": "uint128", + "name": "alphaNumerator_", + "type": "uint128" + }, + { + "internalType": "uint128", + "name": "alphaDenominator_", + "type": "uint128" + }, + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + }, + { + "internalType": "address", + "name": "primeLiquidityProvider_", + "type": "address" + }, + { + "internalType": "address", + "name": "comptroller_", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "loopsLimit_", + "type": "uint256" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "interests", + "outputs": [ + { + "internalType": "uint256", + "name": "accrued", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "score", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "rewardIndex", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "irrevocableLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "isScoreUpdated", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bool", + "name": "isIrrevocable", + "type": "bool" + }, + { + "internalType": "address[]", + "name": "users", + "type": "address[]" + } + ], + "name": "issue", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "markets", + "outputs": [ + { + "internalType": "uint256", + "name": "supplyMultiplier", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowMultiplier", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "rewardIndex", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sumOfMembersScore", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "exists", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "nextScoreUpdateRoundId", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [ + { + "internalType": "contract ResilientOracleInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingScoreUpdates", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "primeLiquidityProvider", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "revocableLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_irrevocableLimit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_revocableLimit", + "type": "uint256" + } + ], + "name": "setLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "loopsLimit", + "type": "uint256" + } + ], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "users", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "timestamps", + "type": "uint256[]" + } + ], + "name": "setStakedAt", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "stakedAt", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "togglePause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "tokens", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "internalType": "bool", + "name": "isIrrevocable", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalIrrevocable", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalRevocable", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalScoreUpdatesRequired", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "unreleasedPLPIncome", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint128", + "name": "_alphaNumerator", + "type": "uint128" + }, + { + "internalType": "uint128", + "name": "_alphaDenominator", + "type": "uint128" + } + ], + "name": "updateAlpha", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "supplyMultiplier", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowMultiplier", + "type": "uint256" + } + ], + "name": "updateMultipliers", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "users", + "type": "address[]" + } + ], + "name": "updateScores", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "vTokenForAsset", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "xvsUpdated", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-015/abi/PrimeLiquidityProvider.json b/multisig/simulations/arbitrumsepolia/vip-015/abi/PrimeLiquidityProvider.json new file mode 100644 index 000000000..02ca8e0bf --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-015/abi/PrimeLiquidityProvider.json @@ -0,0 +1,385 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "_timeBased", "type": "bool" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, + { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "balance", "type": "uint256" } + ], + "name": "InsufficientBalance", + "type": "error" + }, + { "inputs": [], "name": "InvalidArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidCaller", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "speed", "type": "uint256" }, + { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } + ], + "name": "InvalidDistributionSpeed", + "type": "error" + }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenAlreadyInitialized", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "TokenNotInitialized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "MaxTokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } + ], + "name": "PrimeTokenUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenDistributionInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "TokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokenTransferredToPrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokensAccrued", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "accrueTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "getEffectiveDistributionSpeed", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], + "name": "initializeTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "lastAccruedBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastAccruedBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "maxTokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } + ], + "name": "setMaxTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } + ], + "name": "setTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "tokenAmountAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-015/index.ts b/multisig/simulations/arbitrumsepolia/vip-015/index.ts new file mode 100644 index 000000000..a65c516a6 --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-015/index.ts @@ -0,0 +1,91 @@ +/* eslint-disable @typescript-eslint/no-unused-vars */ +import { expect } from "chai"; +import { BigNumber, Contract, Signer } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { initMainnetUser } from "src/utils"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip015, { + COMPTROLLER_CORE, + COMPTROLLER_LST, + PLP, + PRIME, + USDC, + USDT, + VUSDC_CORE, + VUSDT_CORE, + VWBTC_CORE, + VWETH_LST, + WBTC, + WETH, +} from "../../../proposals/arbitrumsepolia/vip-015"; +import COMPTROLLER_ABI from "./abi/ILComptroller.json"; +import PRIME_ABI from "./abi/Prime.json"; +import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; + +forking(92376372, async () => { + const provider = ethers.provider; + let prime: Contract; + let plp: Contract; + + describe("Pre-VIP behaviour", () => { + before(async () => { + prime = new ethers.Contract(PRIME, PRIME_ABI, provider); + plp = new ethers.Contract(PLP, PLP_ABI, provider); + }); + + it("Plp should not contain tokens", async () => { + plp = new ethers.Contract(PLP, PLP_ABI, provider); + + expect(await plp.lastAccruedBlockOrSecond(USDT)).to.be.equal(0); + expect(await plp.lastAccruedBlockOrSecond(USDC)).to.be.equal(0); + expect(await plp.lastAccruedBlockOrSecond(WETH)).to.be.equal(0); + expect(await plp.lastAccruedBlockOrSecond(WBTC)).to.be.equal(0); + }); + + it("Prime should have not contain number of revocable and irrevocable tokens", async () => { + expect(await prime.irrevocableLimit()).to.equal(0); + expect(await prime.revocableLimit()).to.equal(0); + }); + }); + + describe("Post-VIP behavior", () => { + let prime: Contract; + let plp: Contract; + + before(async () => { + await pretendExecutingVip(await vip015()); + + prime = new ethers.Contract(PRIME, PRIME_ABI, provider); + plp = new ethers.Contract(PLP, PLP_ABI, provider); + }); + + it("Comptroller lst and core should have correct Prime token address", async () => { + const comptrollerCore = new ethers.Contract(COMPTROLLER_CORE, COMPTROLLER_ABI, provider); + expect(await comptrollerCore.prime()).to.be.equal(PRIME); + + const comptrollerLst = new ethers.Contract(COMPTROLLER_LST, COMPTROLLER_ABI, provider); + expect(await comptrollerLst.prime()).to.be.equal(PRIME); + }); + + it("Prime should contain correct markets", async () => { + expect((await prime.markets(VUSDC_CORE))[4]).to.be.equal(true); + expect((await prime.markets(VUSDT_CORE))[4]).to.be.equal(true); + expect((await prime.markets(VWBTC_CORE))[4]).to.be.equal(true); + expect((await prime.markets(VWETH_LST))[4]).to.be.equal(true); + }); + + it("Prime should have correct number of revocable and irrevocable tokens", async () => { + expect(await prime.irrevocableLimit()).to.equal(0); + expect(await prime.revocableLimit()).to.equal(500); + }); + + it("Plp should have correct tokens", async () => { + expect(await plp.lastAccruedBlockOrSecond(USDT)).to.be.gt(0); + expect(await plp.lastAccruedBlockOrSecond(USDC)).to.be.gt(0); + expect(await plp.lastAccruedBlockOrSecond(WETH)).to.be.gt(0); + expect(await plp.lastAccruedBlockOrSecond(WBTC)).to.be.gt(0); + }); + }); +}); From e0da97632e67f30b42399c8d09928fd6a0d00cfe Mon Sep 17 00:00:00 2001 From: Corey Rice Date: Fri, 25 Oct 2024 15:06:27 +0100 Subject: [PATCH 070/178] feat: support checking transactions for multisig proposals --- src/utils.ts | 2 +- src/vip-framework/index.ts | 16 ++++++++++++---- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/src/utils.ts b/src/utils.ts index 9f4ab7b09..c6cbe9867 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -405,7 +405,7 @@ export const expectEvents = async ( const getNamedEvents = (abi: string | JsonFragment[]) => { const iface = new ethers.utils.Interface(abi); // @ts-expect-error @TODO type is wrong - return receipt.events + return (receipt.events || receipt.logs) .map((it: { topics: string[]; data: string }) => { try { return iface.parseLog(it).name; diff --git a/src/vip-framework/index.ts b/src/vip-framework/index.ts index ff4bc7343..1da070d2f 100644 --- a/src/vip-framework/index.ts +++ b/src/vip-framework/index.ts @@ -59,7 +59,11 @@ export interface TestingOptions { callbackAfterExecution?: (trx: TransactionResponse) => void; } -const executeCommand = async (timelock: SignerWithAddress, proposal: Proposal, commandIdx: number): Promise => { +const executeCommand = async ( + timelock: SignerWithAddress, + proposal: Proposal, + commandIdx: number, +): Promise => { const encodeMethodCall = (signature: string, params: any[]): string => { if (signature === "") { return "0x"; @@ -90,22 +94,25 @@ const executeCommand = async (timelock: SignerWithAddress, proposal: Proposal, c txnParams.gasLimit = gas.mul(proposal.gasLimitMultiplicationFactor[commandIdx]); } - await timelock.sendTransaction(txnParams); + const tx = await timelock.sendTransaction(txnParams); + return tx; }; export const pretendExecutingVip = async (proposal: Proposal, sender: string = GUARDIAN) => { const impersonatedTimelock = await initMainnetUser(sender, ethers.utils.parseEther("4.0")); console.log("===== Simulating vip ====="); - + const txResponses = []; const bar = new cliProgress.SingleBar({}, cliProgress.Presets.shades_classic); bar.start(proposal.signatures.length, 0); for (let i = 0; i < proposal.signatures.length; ++i) { - await executeCommand(impersonatedTimelock, proposal, i); + const txResponse = await executeCommand(impersonatedTimelock, proposal, i); + txResponses.push(txResponse); bar.update(i + 1); } bar.stop(); + return txResponses; }; export const testVip = (description: string, proposal: Proposal, options: TestingOptions = {}) => { @@ -116,6 +123,7 @@ export const testVip = (description: string, proposal: Proposal, options: Testin const governanceFixture = async (): Promise => { const proposerAddress = options.proposer ?? DEFAULT_PROPOSER_ADDRESS; + const supporterAddress = options.supporter ?? DEFAULT_SUPPORTER_ADDRESS; const timelockAddress = { [ProposalType.REGULAR]: NORMAL_TIMELOCK, From 801f28aee43f3bcba4f40a587d2cbaf359922a9c Mon Sep 17 00:00:00 2001 From: Corey Rice Date: Fri, 25 Oct 2024 15:06:50 +0100 Subject: [PATCH 071/178] feat: vip for adding incentives to ethereum token converters --- multisig/proposals/ethereum/vip-067/index.ts | 95 ++ .../vip-067/abi/SingleTokenConverter.json | 1381 +++++++++++++++++ .../simulations/ethereum/vip-067/index.ts | 102 ++ vips/vip-389/bscmainnet.ts | 50 + 4 files changed, 1628 insertions(+) create mode 100644 multisig/proposals/ethereum/vip-067/index.ts create mode 100644 multisig/simulations/ethereum/vip-067/abi/SingleTokenConverter.json create mode 100644 multisig/simulations/ethereum/vip-067/index.ts create mode 100644 vips/vip-389/bscmainnet.ts diff --git a/multisig/proposals/ethereum/vip-067/index.ts b/multisig/proposals/ethereum/vip-067/index.ts new file mode 100644 index 000000000..005486084 --- /dev/null +++ b/multisig/proposals/ethereum/vip-067/index.ts @@ -0,0 +1,95 @@ +import { makeProposal } from "../../../../src/utils"; + +type IncentiveAndAccessibility = [number, number]; + +export const USDT = "0xdAC17F958D2ee523a2206206994597C13D831ec7"; +export const USDC = "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"; +export const WETH = "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2"; +export const WBTC = "0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599"; +const CRV_USD = "0xf939E0A03FB07F59A73314E73794Be0E57ac1b4E"; +const DAI = "0x6B175474E89094C44Da98b954EedeAC495271d0F"; +const TUSD = "0x0000000000085d4780B73119b644AE5ecd22b376"; +const SFRAXETH = "0xac3E018457B222d93114458476f3E3416Abbe38F"; +const WEETH = "0xCd5fE23C85820F7B72D0926FC9b05b43E359b7ee"; +const SFRAX = "0xA663B02CF0a4b149d2aD41910CB81e23e1c41c32"; +const FRAX = "0x853d955aCEf822Db058eb8505911ED77F175b99e"; +const WSTETH = "0x7f39C581F595B53c5cb19bD0b3f8dA6c935E2Ca0"; +const CRV = "0xD533a949740bb3306d119CC777fa900bA034cd52"; +const PTweETHDEC24 = "0x6ee2b5E19ECBa773a352E5B21415Dc419A700d1d"; +const rsETH = "0xA1290d69c65A6Fe4DF752f95823fae25cB99e5A7"; +const ezETH = "0xbf5495Efe5DB9ce00f80364C8B423567e58d2110"; +const weETHs = "0x917ceE801a67f933F2e6b33fC0cD1ED2d5909D88"; + +export const ETHEREUM_ASSETS = [ + CRV_USD, + USDT, + USDC, + WETH, + WBTC, + DAI, + TUSD, + SFRAXETH, + WEETH, + SFRAX, + FRAX, + WSTETH, + CRV, + PTweETHDEC24, + rsETH, + ezETH, + weETHs, +]; + +export const XVS = "0xd3CC9d8f3689B83c91b7B59cAB4946B063EB894A"; +export const USDC_PRIME_CONVERTER = "0xcEB9503f10B781E30213c0b320bCf3b3cE54216E"; +export const USDT_PRIME_CONVERTER = "0x4f55cb0a24D5542a3478B0E284259A6B850B06BD"; +export const WBTC_PRIME_CONVERTER = "0xDcCDE673Cd8988745dA384A7083B0bd22085dEA0"; +export const WETH_PRIME_CONVERTER = "0xb8fD67f215117FADeF06447Af31590309750529D"; +export const XVS_VAULT_CONVERTER = "0x1FD30e761C3296fE36D9067b1e398FD97B4C0407"; + +// Function to filter assets based on a base asset +const filterAssets = (assets: string[], baseAsset: string) => assets.filter(asset => asset !== baseAsset); + +function getIncentiveAndAccessibility(length: number): IncentiveAndAccessibility[] { + const incentivesAndAccessibility = new Array(length); + incentivesAndAccessibility.fill([1e14, 1]); + return incentivesAndAccessibility; +} + +export const usdcConverterAssets = filterAssets(ETHEREUM_ASSETS, USDC); +export const usdtConverterAssets = filterAssets(ETHEREUM_ASSETS, USDT); +export const wbtcConverterAssets = filterAssets(ETHEREUM_ASSETS, WBTC); +export const wethConverterAssets = filterAssets(ETHEREUM_ASSETS, WETH); +export const xvsConverterAssets = filterAssets(ETHEREUM_ASSETS, XVS); + +export const vip067 = () => { + return makeProposal([ + { + target: USDC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [USDC, usdcConverterAssets, getIncentiveAndAccessibility(usdcConverterAssets.length)], + }, + { + target: USDT_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [USDT, usdtConverterAssets, getIncentiveAndAccessibility(usdtConverterAssets.length)], + }, + { + target: WBTC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [WBTC, wbtcConverterAssets, getIncentiveAndAccessibility(wbtcConverterAssets.length)], + }, + { + target: WETH_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [WETH, wethConverterAssets, getIncentiveAndAccessibility(wethConverterAssets.length)], + }, + { + target: XVS_VAULT_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [XVS, xvsConverterAssets, getIncentiveAndAccessibility(xvsConverterAssets.length)], + }, + ]); +}; + +export default vip067; diff --git a/multisig/simulations/ethereum/vip-067/abi/SingleTokenConverter.json b/multisig/simulations/ethereum/vip-067/abi/SingleTokenConverter.json new file mode 100644 index 000000000..c8d0f7077 --- /dev/null +++ b/multisig/simulations/ethereum/vip-067/abi/SingleTokenConverter.json @@ -0,0 +1,1381 @@ +[ + { + "inputs": [], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { + "inputs": [], + "name": "AmountInMismatched", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { + "inputs": [], + "name": "AmountOutMismatched", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionConfigNotEnabled", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionEnabledOnlyForPrivateConversions", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionTokensActive", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionTokensPaused", + "type": "error" + }, + { + "inputs": [], + "name": "DeflationaryTokenNotSupported", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxIncentive", + "type": "uint256" + } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { + "inputs": [], + "name": "InputLengthMisMatch", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientInputAmount", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientOutputAmount", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientPoolLiquidity", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidConverterNetwork", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidMinimumAmountToConvert", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidToAddress", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidTokenConfigAddresses", + "type": "error" + }, + { + "inputs": [], + "name": "NonZeroIncentiveForPrivateConversion", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroValueNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "AssetTransferredToDestination", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldBaseAsset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newBaseAsset", + "type": "address" + } + ], + "name": "BaseAssetUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldIncentive", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newIncentive", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + } + ], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + } + ], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldConverterNetwork", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "converterNetwork", + "type": "address" + } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldDestinationAddress", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "destinationAddress", + "type": "address" + } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMinAmountToConvert", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMinAmountToConvert", + "type": "uint256" + } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract ResilientOracle", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract ResilientOracle", + "name": "priceOracle", + "type": "address" + } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "token", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "tokenBalance", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "baseAsset", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "conversionConfigurations", + "outputs": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertExactTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertForExactTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [ + { + "internalType": "contract IConverterNetwork", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getAmountIn", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getAmountOut", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + }, + { + "internalType": "contract ResilientOracle", + "name": "priceOracle_", + "type": "address" + }, + { + "internalType": "address", + "name": "destinationAddress_", + "type": "address" + }, + { + "internalType": "address", + "name": "baseAsset_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "minAmountToConvert_", + "type": "uint256" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pauseConversion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [ + { + "internalType": "contract ResilientOracle", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "resumeConversion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "baseAsset_", + "type": "address" + } + ], + "name": "setBaseAsset", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address[]", + "name": "tokenAddressesOut", + "type": "address[]" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract IConverterNetwork", + "name": "converterNetwork_", + "type": "address" + } + ], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "destinationAddress_", + "type": "address" + } + ], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "minAmountToConvert_", + "type": "uint256" + } + ], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract ResilientOracle", + "name": "priceOracle_", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-067/index.ts b/multisig/simulations/ethereum/vip-067/index.ts new file mode 100644 index 000000000..68f6e2d81 --- /dev/null +++ b/multisig/simulations/ethereum/vip-067/index.ts @@ -0,0 +1,102 @@ +/* eslint-disable @typescript-eslint/no-unused-vars */ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { expectEvents } from "src/utils"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip067, { + USDC, + USDC_PRIME_CONVERTER, + USDT, + USDT_PRIME_CONVERTER, + WBTC, + WBTC_PRIME_CONVERTER, + WETH, + WETH_PRIME_CONVERTER, + XVS, + XVS_VAULT_CONVERTER, + usdcConverterAssets, + usdtConverterAssets, + wbtcConverterAssets, + wethConverterAssets, + xvsConverterAssets, +} from "../../../proposals/ethereum/vip-067"; +import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; + +const getAndCompareConverterPreStates = async ( + baseAsset: string, + assets: string[], + converter: Contract, + state: [number, number], +) => { + for (const asset of assets) { + const result = await converter.conversionConfigurations(baseAsset, asset); + expect(result[0]).to.equal(state[0]); + expect(result[1]).to.equal(state[1]); + } +}; + +const getAndCompareConverterStates = async ( + baseAsset: string, + assets: string[], + converter: Contract, + state: [number, number], +) => { + for (const asset of assets) { + const result = await converter.conversionConfigurations(baseAsset, asset); + expect(result[0]).to.equal(state[0]); + expect(result[1]).to.equal(state[1]); + } +}; + +forking(21041502, async () => { + const provider = ethers.provider; + let wethPrimeConverter: Contract; + let wbtcPrimeConverter: Contract; + let usdtPrimeConverter: Contract; + let usdcPrimeConverter: Contract; + let xvsVaultConverter: Contract; + + before(async () => { + usdcPrimeConverter = new ethers.Contract(USDC_PRIME_CONVERTER, SINGLE_TOKEN_CONVERTER_ABI, provider); + usdtPrimeConverter = new ethers.Contract(USDT_PRIME_CONVERTER, SINGLE_TOKEN_CONVERTER_ABI, provider); + xvsVaultConverter = new ethers.Contract(XVS_VAULT_CONVERTER, SINGLE_TOKEN_CONVERTER_ABI, provider); + wethPrimeConverter = new ethers.Contract(WETH_PRIME_CONVERTER, SINGLE_TOKEN_CONVERTER_ABI, provider); + wbtcPrimeConverter = new ethers.Contract(WBTC_PRIME_CONVERTER, SINGLE_TOKEN_CONVERTER_ABI, provider); + }); + + describe("VIP-067", async () => { + it("Check pre vip incentives and conversionAccess for all conversion configs before the execution of VIP", async () => { + await getAndCompareConverterPreStates(USDC, usdcConverterAssets, usdcPrimeConverter, [0, 1]); + + await getAndCompareConverterPreStates(USDT, usdtConverterAssets, usdtPrimeConverter, [0, 1]); + + await getAndCompareConverterPreStates(WBTC, wbtcConverterAssets, wbtcPrimeConverter, [0, 1]); + + await getAndCompareConverterPreStates(WETH, wethConverterAssets, wethPrimeConverter, [0, 1]); + + await getAndCompareConverterPreStates(XVS, xvsConverterAssets, xvsVaultConverter, [0, 1]); + }); + + it("should execute VIP-067", async () => { + const txResponses = await pretendExecutingVip(await vip067()); + for (const txResponse of txResponses.slice(0, 4)) { + await expectEvents(txResponse, [SINGLE_TOKEN_CONVERTER_ABI], ["ConversionConfigUpdated"], [16]); + } + await expectEvents(txResponses[4], [SINGLE_TOKEN_CONVERTER_ABI], ["ConversionConfigUpdated"], [17]); + }); + + it("Get and compare the values for the incentives and conversionAccess for all conversion configs after the execution of VIP", async () => { + await getAndCompareConverterStates(USDC, usdcConverterAssets, usdcPrimeConverter, [1e14, 1]); + + await getAndCompareConverterStates(USDT, usdtConverterAssets, usdtPrimeConverter, [1e14, 1]); + + await getAndCompareConverterStates(WBTC, wbtcConverterAssets, wbtcPrimeConverter, [1e14, 1]); + + await getAndCompareConverterStates(WETH, wethConverterAssets, wethPrimeConverter, [1e14, 1]); + + await getAndCompareConverterStates(XVS, xvsConverterAssets, xvsVaultConverter, [1e14, 1]); + }); + }); +}); diff --git a/vips/vip-389/bscmainnet.ts b/vips/vip-389/bscmainnet.ts new file mode 100644 index 000000000..d26820576 --- /dev/null +++ b/vips/vip-389/bscmainnet.ts @@ -0,0 +1,50 @@ +import { ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +const NORMAL_TIMELOCK = "0x939bD8d64c0A9583A7Dcea9933f7b21697ab6396"; + +export const vip389 = () => { + const meta = { + version: "v2", + title: "VIP-389 Incentives for Token Converters", + description: `#### Summary + +If passed, this VIP will perform the following actions: + +- set to 0.01% the incentive for every conversion pair in every Token Converter contract used by the Venus Protocol on Ethereum Chainnet, following the [Chaos Labs recommendations](https://community.venus.io/t/chaos-labs-ethereum-token-converter-10-24-24/4673). + +#### Description + +Token Converters are permissionless: anyone is able to perform a conversion on those contracts. Incentives on the Token Converters should create arbitrage opportunities, returning on each conversion slightly more than the expected amounts only considering the oracle prices of the tokens involved, or requiring fewer tokens than expected (depending on the type of conversion set by the caller). The community is expected to take advantage of these arbitrages and operate the Token Converter contracts fluidly because they should be economically profitable. + +#### References + +- [VIP Simulation](https://github.com/VenusProtocol/vips/pull/) +- [Token Converters documentation](https://docs-v4.venus.io/whats-new/token-converter) +- [Technical article about Token Converters](https://docs-v4.venus.io/technical-reference/reference-technical-articles/token-converters) +- [Addresses of the deployed Token Converter contracts](https://docs-v4.venus.io/deployed-contracts/token-converters) +- [Chaos Labs recommendation](https://community.venus.io/) + +#### Disclaimer for Ethereum VIPs + +Privilege commands on Ethereum will be executed by the [Guardian wallet](https://etherscan.io/address/0x285960C5B22fD66A736C7136967A3eB15e93CC67), until the [Multichain Governance](https://docs-v4.venus.io/technical-reference/reference-technical-articles/multichain-governance) contracts are deployed. If this VIP passes, [this](https://app.safe.global/transactions/tx?safe=eth:0x285960C5B22fD66A736C7136967A3eB15e93CC67&id=multisig_0x285960C5B22fD66A736C7136967A3eB15e93CC67_0xb8066698a60f8c9f47c1cc8de33b428ad986a68d52393777d35ebe70f3ace1aa) multisig transaction will be executed. Otherwise, it will be rejected.`, + forDescription: "Execute this proposal", + againstDescription: "Do not execute this proposal", + abstainDescription: "Indifferent to execution", + }; + + return makeProposal( + [ + { + target: NORMAL_TIMELOCK, + signature: "", + params: [], + value: "1", + }, + ], + meta, + ProposalType.REGULAR, + ); +}; + +export default vip389; From 6bd74aef59f4603515d43f992ab6de2623262820 Mon Sep 17 00:00:00 2001 From: Corey Rice Date: Mon, 28 Oct 2024 17:53:13 +0100 Subject: [PATCH 072/178] fix: update VIP-390 with final changes --- simulations/vip-390/bscmainnet.ts | 7 ++++++ vips/{vip-389 => vip-390}/bscmainnet.ts | 29 ++++++++++++------------- 2 files changed, 21 insertions(+), 15 deletions(-) create mode 100644 simulations/vip-390/bscmainnet.ts rename vips/{vip-389 => vip-390}/bscmainnet.ts (51%) diff --git a/simulations/vip-390/bscmainnet.ts b/simulations/vip-390/bscmainnet.ts new file mode 100644 index 000000000..53e3c28b6 --- /dev/null +++ b/simulations/vip-390/bscmainnet.ts @@ -0,0 +1,7 @@ +import { forking, testVip } from "src/vip-framework"; + +import vip390 from "../../vips/vip-390/bscmainnet"; + +forking(43517108, async () => { + testVip("VIP-390", await vip390(), {}); +}); diff --git a/vips/vip-389/bscmainnet.ts b/vips/vip-390/bscmainnet.ts similarity index 51% rename from vips/vip-389/bscmainnet.ts rename to vips/vip-390/bscmainnet.ts index d26820576..f64d53e37 100644 --- a/vips/vip-389/bscmainnet.ts +++ b/vips/vip-390/bscmainnet.ts @@ -1,33 +1,32 @@ import { ProposalType } from "src/types"; import { makeProposal } from "src/utils"; +import { FAST_TRACK_TIMELOCK } from "src/vip-framework"; -const NORMAL_TIMELOCK = "0x939bD8d64c0A9583A7Dcea9933f7b21697ab6396"; - -export const vip389 = () => { +export const vip390 = () => { const meta = { version: "v2", - title: "VIP-389 Incentives for Token Converters", + title: "VIP-390 [Ethereum] Incentives for Token Converters", description: `#### Summary -If passed, this VIP will perform the following actions: - -- set to 0.01% the incentive for every conversion pair in every Token Converter contract used by the Venus Protocol on Ethereum Chainnet, following the [Chaos Labs recommendations](https://community.venus.io/t/chaos-labs-ethereum-token-converter-10-24-24/4673). +If passed, this VIP will set to 0.01% the incentive for every conversion pair in every Token Converter contract used by the Venus Protocol on Ethereum, following the [Chaos Labs recommendations](https://community.venus.io/t/chaos-labs-ethereum-token-converter-10-24-24/4673). #### Description -Token Converters are permissionless: anyone is able to perform a conversion on those contracts. Incentives on the Token Converters should create arbitrage opportunities, returning on each conversion slightly more than the expected amounts only considering the oracle prices of the tokens involved, or requiring fewer tokens than expected (depending on the type of conversion set by the caller). The community is expected to take advantage of these arbitrages and operate the Token Converter contracts fluidly because they should be economically profitable. +Token Converters are permissionless: anyone is able to perform a conversion on those contracts. Incentives on the Token Converters should create arbitrage opportunities, returning on each conversion slightly more than the expected amounts only considering the oracle prices of the tokens involved, or requiring fewer tokens than expected (depending on the type of conversion set by the caller). The community is expected to take advantage of these arbitrages and operate the Token Converter contracts fluently because they should be economically profitable. + +This VIP is similar to [VIP-350 Incentives for Token Converters](https://app.venus.io/#/governance/proposal/350?chainId=56), configuring the same incentive on Ethereum. #### References -- [VIP Simulation](https://github.com/VenusProtocol/vips/pull/) +- [VIP Simulation](https://github.com/VenusProtocol/vips/pull/416) - [Token Converters documentation](https://docs-v4.venus.io/whats-new/token-converter) - [Technical article about Token Converters](https://docs-v4.venus.io/technical-reference/reference-technical-articles/token-converters) -- [Addresses of the deployed Token Converter contracts](https://docs-v4.venus.io/deployed-contracts/token-converters) -- [Chaos Labs recommendation](https://community.venus.io/) +- [Addresses of the deployed Token Converter contracts](https://docs-v4.venus.io/deployed-contracts/token-converters#ethereum) +- [Chaos Labs recommendations](https://community.venus.io/t/chaos-labs-ethereum-token-converter-10-24-24/4673) #### Disclaimer for Ethereum VIPs -Privilege commands on Ethereum will be executed by the [Guardian wallet](https://etherscan.io/address/0x285960C5B22fD66A736C7136967A3eB15e93CC67), until the [Multichain Governance](https://docs-v4.venus.io/technical-reference/reference-technical-articles/multichain-governance) contracts are deployed. If this VIP passes, [this](https://app.safe.global/transactions/tx?safe=eth:0x285960C5B22fD66A736C7136967A3eB15e93CC67&id=multisig_0x285960C5B22fD66A736C7136967A3eB15e93CC67_0xb8066698a60f8c9f47c1cc8de33b428ad986a68d52393777d35ebe70f3ace1aa) multisig transaction will be executed. Otherwise, it will be rejected.`, +Privilege commands on Ethereum will be executed by the [Guardian wallet](https://etherscan.io/address/0x285960C5B22fD66A736C7136967A3eB15e93CC67), until the [Multichain Governance](https://docs-v4.venus.io/technical-reference/reference-technical-articles/multichain-governance) contracts are fully enabled. If this VIP passes, [this](https://app.safe.global/transactions/tx?safe=eth:0x285960C5B22fD66A736C7136967A3eB15e93CC67&id=multisig_0x285960C5B22fD66A736C7136967A3eB15e93CC67_0xb8066698a60f8c9f47c1cc8de33b428ad986a68d52393777d35ebe70f3ace1aa) multisig transaction will be executed. Otherwise, it will be rejected.`, forDescription: "Execute this proposal", againstDescription: "Do not execute this proposal", abstainDescription: "Indifferent to execution", @@ -36,15 +35,15 @@ Privilege commands on Ethereum will be executed by the [Guardian wallet](https:/ return makeProposal( [ { - target: NORMAL_TIMELOCK, + target: FAST_TRACK_TIMELOCK, signature: "", params: [], value: "1", }, ], meta, - ProposalType.REGULAR, + ProposalType.FAST_TRACK, ); }; -export default vip389; +export default vip390; From 06c24a5c1bd8fbfbdcbe18a2392851ad7f311a67 Mon Sep 17 00:00:00 2001 From: web3rover Date: Mon, 28 Oct 2024 22:53:00 +0400 Subject: [PATCH 073/178] fix: added sepolia vip --- simulations/vip-389/abi/PoolRegistry.json | 310 ++++ simulations/vip-389/abi/PrimeConverter.json | 587 +++++++ simulations/vip-389/abi/ResilientOracle.json | 301 ++++ simulations/vip-389/abi/comptroller.json | 1496 ++++++++++++++++++ simulations/vip-389/abi/erc20.json | 134 ++ simulations/vip-389/abi/vToken.json | 861 ++++++++++ simulations/vip-389/sepolia.ts | 125 ++ vips/vip-389/bsctestnet.ts | 132 ++ 8 files changed, 3946 insertions(+) create mode 100644 simulations/vip-389/abi/PoolRegistry.json create mode 100644 simulations/vip-389/abi/PrimeConverter.json create mode 100644 simulations/vip-389/abi/ResilientOracle.json create mode 100644 simulations/vip-389/abi/comptroller.json create mode 100644 simulations/vip-389/abi/erc20.json create mode 100644 simulations/vip-389/abi/vToken.json create mode 100644 simulations/vip-389/sepolia.ts create mode 100644 vips/vip-389/bsctestnet.ts diff --git a/simulations/vip-389/abi/PoolRegistry.json b/simulations/vip-389/abi/PoolRegistry.json new file mode 100644 index 000000000..8f15277d2 --- /dev/null +++ b/simulations/vip-389/abi/PoolRegistry.json @@ -0,0 +1,310 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "vTokenAddress", "type": "address" } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "oldMetadata", + "type": "tuple" + }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "newMetadata", + "type": "tuple" + } + ], + "name": "PoolMetadataUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "oldName", "type": "string" }, + { "indexed": false, "internalType": "string", "name": "newName", "type": "string" } + ], + "name": "PoolNameSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPool", + "name": "pool", + "type": "tuple" + } + ], + "name": "PoolRegistered", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "collateralFactor", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThreshold", "type": "uint256" }, + { "internalType": "uint256", "name": "initialSupply", "type": "uint256" }, + { "internalType": "address", "name": "vTokenReceiver", "type": "address" }, + { "internalType": "uint256", "name": "supplyCap", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCap", "type": "uint256" } + ], + "internalType": "struct PoolRegistry.AddMarketInput", + "name": "input", + "type": "tuple" + } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "contract Comptroller", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "closeFactor", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationIncentive", "type": "uint256" }, + { "internalType": "uint256", "name": "minLiquidatableCollateral", "type": "uint256" } + ], + "name": "addPool", + "outputs": [{ "internalType": "uint256", "name": "index", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getAllPools", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool[]", + "name": "", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "comptroller", "type": "address" }], + "name": "getPoolByComptroller", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPoolsSupportedByAsset", + "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "getVTokenForAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "comptroller", "type": "address" }], + "name": "getVenusPoolMetadata", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "metadata", + "outputs": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "string", "name": "name", "type": "string" } + ], + "name": "setPoolName", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "metadata_", + "type": "tuple" + } + ], + "name": "updatePoolMetadata", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-389/abi/PrimeConverter.json b/simulations/vip-389/abi/PrimeConverter.json new file mode 100644 index 000000000..8ea10cc8d --- /dev/null +++ b/simulations/vip-389/abi/PrimeConverter.json @@ -0,0 +1,587 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { "inputs": [], "name": "AmountInMismatched", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, + { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, + { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, + { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, + { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, + { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, + { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, + { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, + { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, + { "inputs": [], "name": "InvalidToAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, + { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetTransferredToDestination", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } + ], + "name": "BaseAssetUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, + { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "baseAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "conversionConfigurations", + "outputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, + { "internalType": "address", "name": "destinationAddress_", "type": "address" }, + { "internalType": "address", "name": "baseAsset_", "type": "address" }, + { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], + "name": "setBaseAsset", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-389/abi/ResilientOracle.json b/simulations/vip-389/abi/ResilientOracle.json new file mode 100644 index 000000000..e2f944a9d --- /dev/null +++ b/simulations/vip-389/abi/ResilientOracle.json @@ -0,0 +1,301 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "nativeMarketAddress", "type": "address" }, + { "internalType": "address", "name": "vaiAddress", "type": "address" }, + { "internalType": "contract BoundValidatorInterface", "name": "_boundValidator", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "role", "type": "uint256" }, + { "indexed": true, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "oracle", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "role", "type": "uint256" } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "mainOracle", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "pivotOracle", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "fallbackOracle", "type": "address" } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [{ "internalType": "contract BoundValidatorInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" } + ], + "name": "getOracle", + "outputs": [ + { "internalType": "address", "name": "oracle", "type": "address" }, + { "internalType": "bool", "name": "enabled", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getUnderlyingPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address", "name": "oracle", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-389/abi/comptroller.json b/simulations/vip-389/abi/comptroller.json new file mode 100644 index 000000000..fafe7b35e --- /dev/null +++ b/simulations/vip-389/abi/comptroller.json @@ -0,0 +1,1496 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "poolRegistry_", + "type": "address" + }, + { + "internalType": "address", + "name": "accessControl_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedLessThanOrEqualTo", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { + "inputs": [], + "name": "ComptrollerMismatch", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "collateralToSeize", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "availableCollateral", + "type": "uint256" + } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientLiquidity", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientShortfall", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidCollateralFactor", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidLiquidationThreshold", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedGreaterThan", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { + "inputs": [], + "name": "NonzeroBorrowBalance", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { + "inputs": [], + "name": "TooMuchRepay", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "expectedSender", + "type": "address" + }, + { + "internalType": "address", + "name": "actualSender", + "type": "address" + } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "bool", + "name": "pauseState", + "type": "bool" + } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newBorrowCap", + "type": "uint256" + } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldCloseFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldCollateralFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationIncentiveMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationThresholdMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMinLiquidatableCollateral", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "rewardsDistributor", + "type": "address" + } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSupplyCap", + "type": "uint256" + } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControl", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "accountAssets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "actionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract RewardsDistributor", + "name": "_rewardsDistributor", + "type": "address" + } + ], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "allMarkets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "borrowCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "checkMembership", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "vTokens", + "type": "address[]" + } + ], + "name": "enterMarkets", + "outputs": [ + { + "internalType": "uint256[]", + "name": "", + "type": "uint256[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenAddress", + "type": "address" + } + ], + "name": "exitMarket", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAssetsIn", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenModify", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [ + { + "internalType": "contract RewardsDistributor[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "rewardToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "supplySpeed", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowSpeed", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isDeprecated", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isMarketListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "components": [ + { + "internalType": "contract VToken", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokensToSeize", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "markets", + "outputs": [ + { + "internalType": "bool", + "name": "isListed", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "collateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidationThresholdMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [ + { + "internalType": "contract PriceOracle", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "skipLiquidityCheck", + "type": "bool" + } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "seizerContract", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "transferTokens", + "type": "uint256" + } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "marketsList", + "type": "address[]" + }, + { + "internalType": "enum ComptrollerStorage.Action[]", + "name": "actionsList", + "type": "uint8[]" + }, + { + "internalType": "bool", + "name": "paused", + "type": "bool" + } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newBorrowCaps", + "type": "uint256[]" + } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newSupplyCaps", + "type": "uint256[]" + } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract PriceOracle", + "name": "newOracle", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "supplyCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-389/abi/erc20.json b/simulations/vip-389/abi/erc20.json new file mode 100644 index 000000000..3a509c9c4 --- /dev/null +++ b/simulations/vip-389/abi/erc20.json @@ -0,0 +1,134 @@ +[ + { + "inputs": [ + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "name": "faucet", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "from", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-389/abi/vToken.json b/simulations/vip-389/abi/vToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/simulations/vip-389/abi/vToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-389/sepolia.ts b/simulations/vip-389/sepolia.ts new file mode 100644 index 000000000..3a7840fb1 --- /dev/null +++ b/simulations/vip-389/sepolia.ts @@ -0,0 +1,125 @@ +import { expect } from "chai"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; +import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip389, { BORROW_CAP, + CORE_COMPTROLLER, + SUPPLY_CAP, + vEIGEN, + EIGEN, + PRICE } from "../../vips/vip-389/bsctestnet"; +import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; +import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; +import COMPTROLLER_ABI from "./abi/comptroller.json"; +import ERC20_ABI from "./abi/erc20.json"; +import VTOKEN_ABI from "./abi/vToken.json"; +import { BigNumber, Contract } from "ethers"; +import { impersonateAccount, setBalance } from "@nomicfoundation/hardhat-network-helpers"; +import { parseUnits } from "ethers/lib/utils"; +import { checkVToken } from "src/vip-framework/checks/checkVToken"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; + +const { sepolia } = NETWORK_ADDRESSES; +const PROTOCOL_SHARE_RESERVE = "0xbea70755cc3555708ca11219adB0db4C80F6721B"; + +forking(6964722, async () => { + let resilientOracle: Contract; + let poolRegistry: Contract; + let vEIGENContract: Contract; + let comptroller: Contract; + let eigenContract: Contract; + + before(async () => { + // await impersonateAccount(sepolia.NORMAL_TIMELOCK); + // await setBalance(sepolia.NORMAL_TIMELOCK, parseUnits("1000", 18)); + + resilientOracle = await ethers.getContractAt(RESILIENT_ORACLE_ABI, sepolia.RESILIENT_ORACLE); + poolRegistry = await ethers.getContractAt(POOL_REGISTRY_ABI, sepolia.POOL_REGISTRY); + vEIGENContract = await ethers.getContractAt(VTOKEN_ABI, vEIGEN); + comptroller = await ethers.getContractAt(COMPTROLLER_ABI, CORE_COMPTROLLER); + eigenContract = await ethers.getContractAt(ERC20_ABI, EIGEN, await ethers.getSigner(sepolia.NORMAL_TIMELOCK)); + }); + + testForkedNetworkVipCommands("vip389", await vip389()); + + describe("Post-VIP behavior", async () => { + it("check price", async () => { + expect(await resilientOracle.getPrice(EIGEN)).to.be.equal(PRICE); + expect(await resilientOracle.getUnderlyingPrice(vEIGEN)).to.be.equal( + PRICE + ); + }); + + it("should have 12 markets in core pool", async () => { + const poolVTokens = await comptroller.getAllMarkets(); + expect(poolVTokens).to.have.lengthOf(12); + }); + + it("should add vEIGEN to the pool", async () => { + const registeredVToken = await poolRegistry.getVTokenForAsset(comptroller.address, EIGEN); + expect(registeredVToken).to.equal(vEIGEN); + }); + + it("check ownership", async () => { + expect(await vEIGENContract.owner()).to.equal(sepolia.GUARDIAN); + }); + + it("check supply", async () => { + const expectedSupply = parseUnits("0.00000005", 18); + expect(await vEIGENContract.balanceOf(sepolia.VTREASURY)).to.equal(expectedSupply); + }); + + it("check borrow and supply caps", async () => { + expect(await comptroller.borrowCaps(vEIGEN)).equals(BORROW_CAP); + expect(await comptroller.supplyCaps(vEIGEN)).equals(SUPPLY_CAP); + }); + + it("should set vEIGEN collateral factor to 50% and Liquidation threshold to 60%", async () => { + const market = await comptroller.markets(vEIGEN); + expect(market.collateralFactorMantissa).to.equal(parseUnits("0.5", 18)); + expect(market.liquidationThresholdMantissa).to.equal(parseUnits("0.6", 18)); + }); + + it("check protocol share reserve", async () => { + expect(await vEIGENContract.protocolShareReserve()).equals(PROTOCOL_SHARE_RESERVE); + }); + + it("check reserve factor", async () => { + expect(await vEIGENContract.reserveFactorMantissa()).equals(parseUnits("0.25", 18)); + }); + + it("check protocol seize share", async () => { + expect(await vEIGENContract.protocolSeizeShareMantissa()).equals(parseUnits("0.01", 18)); + }); + + it("check vToken", async () => { + checkVToken(vEIGEN, { + name: "Venus EIGEN", + symbol: "vEIGEN", + decimals: 8, + underlying: EIGEN, + exchangeRate: parseUnits("10000000000", 18), + comptroller: CORE_COMPTROLLER, + }); + }); + + it("check IR", async () => { + const IR = await vEIGENContract.interestRateModel(); + checkInterestRate( + IR, + "vEIGENContract_Core", + { base: "0.02", multiplier: "0.15", jump: "3", kink: "0.45" }, + BigNumber.from(2628000), + ); + }); + + // it("check Pool", async () => { + // await eigenContract.faucet(parseUnits("100", 18)); + // await checkIsolatedPoolsComptrollers({ + // [CORE_COMPTROLLER]: sepolia.NORMAL_TIMELOCK, + // }); + // }); + }); +}); \ No newline at end of file diff --git a/vips/vip-389/bsctestnet.ts b/vips/vip-389/bsctestnet.ts new file mode 100644 index 000000000..fa79465f6 --- /dev/null +++ b/vips/vip-389/bsctestnet.ts @@ -0,0 +1,132 @@ +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +const { sepolia } = NETWORK_ADDRESSES; + +export const EIGEN = "0xf140594470Bff436aE82F2116ab8a438671C6e83"; +const INITIAL_SUPPLY = parseUnits("500", 18); +export const SUPPLY_CAP = parseUnits("3000000", 18); +export const BORROW_CAP = parseUnits("1500000", 18); +const CF = parseUnits("0.5", 18); +const LT = parseUnits("0.6", 18); +export const vEIGEN = "0x6DB4aDbA8F144a57a397b57183BF619e957040B1"; +export const CORE_COMPTROLLER = "0x7Aa39ab4BcA897F403425C9C6FDbd0f882Be0D70"; +export const PRICE = parseUnits("3.5", 18); + +export const USDT_PRIME_CONVERTER = "0x3716C24EA86A67cAf890d7C9e4C4505cDDC2F8A2"; +export const USDC_PRIME_CONVERTER = "0x511a559a699cBd665546a1F75908f7E9454Bfc67"; +export const WBTC_PRIME_CONVERTER = "0x8a3937F27921e859db3FDA05729CbCea8cfd82AE"; +export const WETH_PRIME_CONVERTER = "0x274a834eFFA8D5479502dD6e78925Bc04ae82B46"; +export const XVS_VAULT_CONVERTER = "0xc203bfA9dCB0B5fEC510Db644A494Ff7f4968ed2"; +export const BaseAssets = [ + "0x8d412FD0bc5d826615065B931171Eed10F5AF266", // USDT USDTPrimeConverter BaseAsset + "0x772d68929655ce7234C8C94256526ddA66Ef641E", // USDC USDCPrimeConverter BaseAsset + "0x92A2928f5634BEa89A195e7BeCF0f0FEEDAB885b", // WBTC WBTCPrimeConverter BaseAsset + "0x7b79995e5f793A07Bc00c21412e50Ecae098E7f9", // WETH WETHPrimeConverter BaseAsset + "0x66ebd019E86e0af5f228a0439EBB33f045CBe63E", // XVS XVSPrimeConverter BaseAsset +]; + +const vip389 = () => { + const meta = { + version: "v2", + title: "VIP-389", + description: `### Description`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: sepolia.CHAINLINK_ORACLE, + signature: "setDirectPrice(address,uint256)", + params: [EIGEN, PRICE], + dstChainId: LzChainId.sepolia, + }, + { + target: sepolia.RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [EIGEN, [sepolia.CHAINLINK_ORACLE, ethers.constants.AddressZero, ethers.constants.AddressZero], [true, false, false]], + ], + dstChainId: LzChainId.sepolia, + }, + + // Add Market + { + target: EIGEN, + signature: "faucet(uint256)", + params: [INITIAL_SUPPLY], + dstChainId: LzChainId.sepolia, + }, + { + target: EIGEN, + signature: "approve(address,uint256)", + params: [sepolia.POOL_REGISTRY, 0], + dstChainId: LzChainId.sepolia, + }, + { + target: EIGEN, + signature: "approve(address,uint256)", + params: [sepolia.POOL_REGISTRY, INITIAL_SUPPLY], + dstChainId: LzChainId.sepolia, + }, + { + target: vEIGEN, + signature: "setReduceReservesBlockDelta(uint256)", + params: ["7200"], + dstChainId: LzChainId.sepolia, + }, + { + target: sepolia.POOL_REGISTRY, + signature: "addMarket((address,uint256,uint256,uint256,address,uint256,uint256))", + params: [[vEIGEN, CF, LT, INITIAL_SUPPLY, sepolia.VTREASURY, SUPPLY_CAP, BORROW_CAP]], + dstChainId: LzChainId.sepolia, + }, + { + target: vEIGEN, + signature: "setProtocolSeizeShare(uint256)", + params: [parseUnits("0.01", 18)], + dstChainId: LzChainId.sepolia, + }, + + // Conversion config + { + target: USDT_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[0], [EIGEN], [[0, 1]]], + dstChainId: LzChainId.sepolia, + }, + { + target: USDC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[1], [EIGEN], [[0, 1]]], + dstChainId: LzChainId.sepolia, + }, + { + target: WBTC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[2], [EIGEN], [[0, 1]]], + dstChainId: LzChainId.sepolia, + }, + { + target: WETH_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[3], [EIGEN], [[0, 1]]], + dstChainId: LzChainId.sepolia, + }, + { + target: XVS_VAULT_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[4], [EIGEN], [[0, 1]]], + dstChainId: LzChainId.sepolia, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip389; \ No newline at end of file From bc44168895e5eb988b9dc3ae7daeabeb1e012204 Mon Sep 17 00:00:00 2001 From: web3rover Date: Tue, 29 Oct 2024 12:35:51 +0400 Subject: [PATCH 074/178] fix: added addendum vips --- simulations/vip-371/opbnbtestnet-addendum.ts | 40 ++++++++++++ simulations/vip-371/sepolia-addendum.ts | 47 ++++++++++++++ vips/vip-371/bsctestnet-addendum.ts | 65 ++++++++++++++++++++ 3 files changed, 152 insertions(+) create mode 100644 simulations/vip-371/opbnbtestnet-addendum.ts create mode 100644 simulations/vip-371/sepolia-addendum.ts create mode 100644 vips/vip-371/bsctestnet-addendum.ts diff --git a/simulations/vip-371/opbnbtestnet-addendum.ts b/simulations/vip-371/opbnbtestnet-addendum.ts new file mode 100644 index 000000000..628355410 --- /dev/null +++ b/simulations/vip-371/opbnbtestnet-addendum.ts @@ -0,0 +1,40 @@ +import { expect } from "chai"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; +import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip371, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet-addendum"; +import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; + +const { opbnbtestnet } = NETWORK_ADDRESSES; +const ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; +const BOUND_VALIDATOR = "0x049537Bb065e6253e9D8D08B45Bf6b753657A746"; + +forking(43312025, async () => { + testForkedNetworkVipCommands("vip371", await vip371(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [1]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); + }, + }); + + describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); + + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR)).to.be.false; + }); + + it("check few permissions", async () => { + const role1 = ethers.utils.solidityPack( + ["address", "string"], + [BOUND_VALIDATOR, "setValidateConfig(ValidateConfig)"], + ); + + const roleHash = ethers.utils.keccak256(role1); + expect(await acm.hasRole(roleHash, opbnbtestnet.NORMAL_TIMELOCK)).to.be.true; + }); + }); +}); diff --git a/simulations/vip-371/sepolia-addendum.ts b/simulations/vip-371/sepolia-addendum.ts new file mode 100644 index 000000000..39c742c50 --- /dev/null +++ b/simulations/vip-371/sepolia-addendum.ts @@ -0,0 +1,47 @@ +import { expect } from "chai"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; +import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip371, { DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet-addendum"; +import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; + +const { sepolia } = NETWORK_ADDRESSES; +const ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; +const FAST_TRACK_TIMELOCK = "0x7F043F43Adb392072a3Ba0cC9c96e894C6f7e182"; + +forking(6968680, async () => { + testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [6]); + await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); + }, + }); + + describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(ACM, ACCESS_CONTROL_MANAGER_ABI, ethers.provider); + it("check if DEFAULT_ROLE has been revoked for ACMAggregator", async () => { + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR)).to.be.false; + }); + + it("check few permissions", async () => { + const role1 = ethers.utils.solidityPack( + ["address", "string"], + [sepolia.CHAINLINK_ORACLE, "setDirectPrice(address,uint256)"], + ); + + const roleHash = ethers.utils.keccak256(role1); + expect(await acm.hasRole(roleHash, sepolia.NORMAL_TIMELOCK)).to.be.true; + + const role2 = ethers.utils.solidityPack( + ["address", "string"], + [sepolia.CHAINLINK_ORACLE, "setTokenConfig(TokenConfig)"], + ); + + const roleHash2 = ethers.utils.keccak256(role2); + expect(await acm.hasRole(roleHash2, FAST_TRACK_TIMELOCK)).to.be.true; + }); + }); +}); diff --git a/vips/vip-371/bsctestnet-addendum.ts b/vips/vip-371/bsctestnet-addendum.ts new file mode 100644 index 000000000..a4ddd2d26 --- /dev/null +++ b/vips/vip-371/bsctestnet-addendum.ts @@ -0,0 +1,65 @@ +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const SEPOLIA_ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; +export const OPBNBTESTNET_ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; + +export const OPBNBTESTNET_ACM_AGGREGATOR = "0xbDd501dB1B0D6aab299CE69ef5B86C8578947AD0"; +export const SEPOLIA_ACM_AGGREGATOR = "0x0653830c55035d678e1287b2d4550519fd263d0e"; + +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + +const vip371 = () => { + const meta = { + version: "v2", + title: "VIP-371: Fix Sepolia and OPBNBTestnet permissions", + description: `### Fix chainlink permissions for sepolia and bound validator permissions for opbnbtestnet`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: OPBNBTESTNET_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: OPBNBTESTNET_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [3], + dstChainId: LzChainId.opbnbtestnet, + }, + { + target: OPBNBTESTNET_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR], + dstChainId: LzChainId.opbnbtestnet, + }, + + { + target: SEPOLIA_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.sepolia, + }, + { + target: SEPOLIA_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [4], + dstChainId: LzChainId.sepolia, + }, + { + target: SEPOLIA_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR], + dstChainId: LzChainId.sepolia, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip371; From 49d9f1d1b2970cbbe861dd445d5d14799948ecf7 Mon Sep 17 00:00:00 2001 From: web3rover Date: Tue, 29 Oct 2024 16:46:28 +0400 Subject: [PATCH 075/178] fix: fixed vip and simulations --- simulations/vip-389/sepolia.ts | 82 ++++++++++++++++++++++++---------- vips/vip-389/bsctestnet.ts | 8 +++- 2 files changed, 65 insertions(+), 25 deletions(-) diff --git a/simulations/vip-389/sepolia.ts b/simulations/vip-389/sepolia.ts index 3a7840fb1..35429f6ca 100644 --- a/simulations/vip-389/sepolia.ts +++ b/simulations/vip-389/sepolia.ts @@ -1,45 +1,59 @@ +import { impersonateAccount, setBalance } from "@nomicfoundation/hardhat-network-helpers"; import { expect } from "chai"; +import { BigNumber, Contract } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { expectEvents } from "src/utils"; import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; +import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIsolatedPoolsComptrollers"; +import { checkVToken } from "src/vip-framework/checks/checkVToken"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; -import vip389, { BORROW_CAP, +import vip389, { + BORROW_CAP, + BaseAssets, CORE_COMPTROLLER, + EIGEN, + PRICE, SUPPLY_CAP, + USDT_PRIME_CONVERTER, vEIGEN, - EIGEN, - PRICE } from "../../vips/vip-389/bsctestnet"; +} from "../../vips/vip-389/bsctestnet"; import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; +import PRIME_CONVERTER_ABI from "./abi/PrimeConverter.json"; import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; import COMPTROLLER_ABI from "./abi/comptroller.json"; import ERC20_ABI from "./abi/erc20.json"; import VTOKEN_ABI from "./abi/vToken.json"; -import { BigNumber, Contract } from "ethers"; -import { impersonateAccount, setBalance } from "@nomicfoundation/hardhat-network-helpers"; -import { parseUnits } from "ethers/lib/utils"; -import { checkVToken } from "src/vip-framework/checks/checkVToken"; -import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; const { sepolia } = NETWORK_ADDRESSES; const PROTOCOL_SHARE_RESERVE = "0xbea70755cc3555708ca11219adB0db4C80F6721B"; +const USDT_USER = "0x02EB950C215D12d723b44a18CfF098C6E166C531"; -forking(6964722, async () => { +forking(6969766, async () => { let resilientOracle: Contract; let poolRegistry: Contract; let vEIGENContract: Contract; let comptroller: Contract; let eigenContract: Contract; + let usdtPrimeConverter: Contract; + let usdt: Contract; before(async () => { - // await impersonateAccount(sepolia.NORMAL_TIMELOCK); - // await setBalance(sepolia.NORMAL_TIMELOCK, parseUnits("1000", 18)); + await impersonateAccount(sepolia.NORMAL_TIMELOCK); + await setBalance(sepolia.NORMAL_TIMELOCK, parseUnits("1000", 18)); + await impersonateAccount(USDT_USER); + await setBalance(USDT_USER, parseUnits("1000", 18)); + await impersonateAccount(USDT_PRIME_CONVERTER); + await setBalance(USDT_PRIME_CONVERTER, parseUnits("1000", 18)); resilientOracle = await ethers.getContractAt(RESILIENT_ORACLE_ABI, sepolia.RESILIENT_ORACLE); poolRegistry = await ethers.getContractAt(POOL_REGISTRY_ABI, sepolia.POOL_REGISTRY); vEIGENContract = await ethers.getContractAt(VTOKEN_ABI, vEIGEN); comptroller = await ethers.getContractAt(COMPTROLLER_ABI, CORE_COMPTROLLER); eigenContract = await ethers.getContractAt(ERC20_ABI, EIGEN, await ethers.getSigner(sepolia.NORMAL_TIMELOCK)); + usdtPrimeConverter = await ethers.getContractAt(PRIME_CONVERTER_ABI, USDT_PRIME_CONVERTER); + usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); }); testForkedNetworkVipCommands("vip389", await vip389()); @@ -47,9 +61,7 @@ forking(6964722, async () => { describe("Post-VIP behavior", async () => { it("check price", async () => { expect(await resilientOracle.getPrice(EIGEN)).to.be.equal(PRICE); - expect(await resilientOracle.getUnderlyingPrice(vEIGEN)).to.be.equal( - PRICE - ); + expect(await resilientOracle.getUnderlyingPrice(vEIGEN)).to.be.equal(PRICE); }); it("should have 12 markets in core pool", async () => { @@ -111,15 +123,39 @@ forking(6964722, async () => { IR, "vEIGENContract_Core", { base: "0.02", multiplier: "0.15", jump: "3", kink: "0.45" }, - BigNumber.from(2628000), + BigNumber.from(2252571), ); }); - // it("check Pool", async () => { - // await eigenContract.faucet(parseUnits("100", 18)); - // await checkIsolatedPoolsComptrollers({ - // [CORE_COMPTROLLER]: sepolia.NORMAL_TIMELOCK, - // }); - // }); + it("check Pool", async () => { + await eigenContract.faucet(parseUnits("100", 18)); + await checkIsolatedPoolsComptrollers({ + [CORE_COMPTROLLER]: sepolia.NORMAL_TIMELOCK, + }); + }); + + it("EIGEN conversion", async () => { + const usdtAmount = parseUnits("10", 6); + await usdt.connect(await ethers.getSigner(sepolia.NORMAL_TIMELOCK)).faucet(usdtAmount); + await usdt + .connect(await ethers.getSigner(sepolia.NORMAL_TIMELOCK)) + .approve(usdtPrimeConverter.address, usdtAmount); + + const eigenAmount = parseUnits("2", 18); + await eigenContract.connect(await ethers.getSigner(usdtPrimeConverter.address)).faucet(eigenAmount); + + const usdtBalanceBefore = await usdt.balanceOf(sepolia.NORMAL_TIMELOCK); + const eigenBalanceBefore = await eigenContract.balanceOf(sepolia.NORMAL_TIMELOCK); + + await usdtPrimeConverter + .connect(await ethers.getSigner(sepolia.NORMAL_TIMELOCK)) + .convertForExactTokens(usdtAmount, eigenAmount, usdt.address, eigenContract.address, sepolia.NORMAL_TIMELOCK); + + const usdtBalanceAfter = await usdt.balanceOf(sepolia.NORMAL_TIMELOCK); + const eigenBalanceAfter = await eigenContract.balanceOf(sepolia.NORMAL_TIMELOCK); + + expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("7", 6)); + expect(eigenBalanceAfter.sub(eigenBalanceBefore)).to.be.equal(eigenAmount); + }); }); -}); \ No newline at end of file +}); diff --git a/vips/vip-389/bsctestnet.ts b/vips/vip-389/bsctestnet.ts index fa79465f6..1b9d9b9e3 100644 --- a/vips/vip-389/bsctestnet.ts +++ b/vips/vip-389/bsctestnet.ts @@ -50,7 +50,11 @@ const vip389 = () => { target: sepolia.RESILIENT_ORACLE, signature: "setTokenConfig((address,address[3],bool[3]))", params: [ - [EIGEN, [sepolia.CHAINLINK_ORACLE, ethers.constants.AddressZero, ethers.constants.AddressZero], [true, false, false]], + [ + EIGEN, + [sepolia.CHAINLINK_ORACLE, ethers.constants.AddressZero, ethers.constants.AddressZero], + [true, false, false], + ], ], dstChainId: LzChainId.sepolia, }, @@ -129,4 +133,4 @@ const vip389 = () => { ProposalType.REGULAR, ); }; -export default vip389; \ No newline at end of file +export default vip389; From 95051612320a00ab1baf7f8398a2ebbf3aa95c90 Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 30 Oct 2024 15:07:33 +0400 Subject: [PATCH 076/178] fix: added bsctestnet simulation --- .../vip-389/abi/OmnichainProposalSender.json | 314 ++++++++++++++++++ simulations/vip-389/bsctestnet.ts | 17 + 2 files changed, 331 insertions(+) create mode 100644 simulations/vip-389/abi/OmnichainProposalSender.json create mode 100644 simulations/vip-389/bsctestnet.ts diff --git a/simulations/vip-389/abi/OmnichainProposalSender.json b/simulations/vip-389/abi/OmnichainProposalSender.json new file mode 100644 index 000000000..66fd4df02 --- /dev/null +++ b/simulations/vip-389/abi/OmnichainProposalSender.json @@ -0,0 +1,314 @@ +[ + { + "inputs": [ + { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } + ], + "name": "ClearPayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } + ], + "name": "ExecuteRemoteProposal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "FallbackWithdraw", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } + ], + "name": "StorePayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], + "name": "TrustedRemoteRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "LZ_ENDPOINT", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourCommandsSent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLastProposalSentTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bool", "name": "useZro_", "type": "bool" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } + ], + "name": "estimateFees", + "outputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } + ], + "name": "execute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "fallbackWithdraw", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "proposalCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], + "name": "removeTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "retryExecute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" }, + { "internalType": "bytes", "name": "config_", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "storedExecutionHashes", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } +] diff --git a/simulations/vip-389/bsctestnet.ts b/simulations/vip-389/bsctestnet.ts new file mode 100644 index 000000000..eb67a2f70 --- /dev/null +++ b/simulations/vip-389/bsctestnet.ts @@ -0,0 +1,17 @@ +import { expectEvents } from "../../src/utils"; +import { forking, testVip } from "../../src/vip-framework"; +import vip389 from "../../vips/vip-389/bsctestnet"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +forking(45188496, async () => { + testVip("vip389", await vip389(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [1, 0], + ); + }, + }); +}); From dc1b82ebae04cc43dc2d2c3120a8dd3f04c6c727 Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 30 Oct 2024 15:14:06 +0400 Subject: [PATCH 077/178] fix: added incentive --- simulations/vip-389/sepolia.ts | 2 +- vips/vip-389/bsctestnet.ts | 11 ++++++----- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/simulations/vip-389/sepolia.ts b/simulations/vip-389/sepolia.ts index 35429f6ca..cb1cd52ea 100644 --- a/simulations/vip-389/sepolia.ts +++ b/simulations/vip-389/sepolia.ts @@ -154,7 +154,7 @@ forking(6969766, async () => { const usdtBalanceAfter = await usdt.balanceOf(sepolia.NORMAL_TIMELOCK); const eigenBalanceAfter = await eigenContract.balanceOf(sepolia.NORMAL_TIMELOCK); - expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("7", 6)); + expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("6.999301", 6)); expect(eigenBalanceAfter.sub(eigenBalanceBefore)).to.be.equal(eigenAmount); }); }); diff --git a/vips/vip-389/bsctestnet.ts b/vips/vip-389/bsctestnet.ts index 1b9d9b9e3..939501f98 100644 --- a/vips/vip-389/bsctestnet.ts +++ b/vips/vip-389/bsctestnet.ts @@ -28,6 +28,7 @@ export const BaseAssets = [ "0x7b79995e5f793A07Bc00c21412e50Ecae098E7f9", // WETH WETHPrimeConverter BaseAsset "0x66ebd019E86e0af5f228a0439EBB33f045CBe63E", // XVS XVSPrimeConverter BaseAsset ]; +const CONVERSION_INCENTIVE = parseUnits("0.0001", 18); const vip389 = () => { const meta = { @@ -101,31 +102,31 @@ const vip389 = () => { { target: USDT_PRIME_CONVERTER, signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[0], [EIGEN], [[0, 1]]], + params: [BaseAssets[0], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], dstChainId: LzChainId.sepolia, }, { target: USDC_PRIME_CONVERTER, signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[1], [EIGEN], [[0, 1]]], + params: [BaseAssets[1], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], dstChainId: LzChainId.sepolia, }, { target: WBTC_PRIME_CONVERTER, signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[2], [EIGEN], [[0, 1]]], + params: [BaseAssets[2], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], dstChainId: LzChainId.sepolia, }, { target: WETH_PRIME_CONVERTER, signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[3], [EIGEN], [[0, 1]]], + params: [BaseAssets[3], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], dstChainId: LzChainId.sepolia, }, { target: XVS_VAULT_CONVERTER, signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[4], [EIGEN], [[0, 1]]], + params: [BaseAssets[4], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], dstChainId: LzChainId.sepolia, }, ], From dcda279bd016236b5554ac527ef076d6d7e47fe3 Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 30 Oct 2024 16:57:28 +0400 Subject: [PATCH 078/178] fix: wip - add sepolia vip --- simulations/vip-391/sepolia.ts | 160 +++++++++++++++++++++++++++++++++ vips/vip-391/bsctestnet.ts | 134 +++++++++++++++++++++++++++ 2 files changed, 294 insertions(+) create mode 100644 simulations/vip-391/sepolia.ts create mode 100644 vips/vip-391/bsctestnet.ts diff --git a/simulations/vip-391/sepolia.ts b/simulations/vip-391/sepolia.ts new file mode 100644 index 000000000..956a3368c --- /dev/null +++ b/simulations/vip-391/sepolia.ts @@ -0,0 +1,160 @@ +import { impersonateAccount, setBalance } from "@nomicfoundation/hardhat-network-helpers"; +import { expect } from "chai"; +import { BigNumber, Contract } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; +import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIsolatedPoolsComptrollers"; +import { checkVToken } from "src/vip-framework/checks/checkVToken"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; + +import vip391, { + BORROW_CAP, + BaseAssets, + CORE_COMPTROLLER, + eBTC, + SUPPLY_CAP, + USDT_PRIME_CONVERTER, + veBTC, +} from "../../vips/vip-391/bsctestnet"; +import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; +import PRIME_CONVERTER_ABI from "./abi/PrimeConverter.json"; +import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; +import COMPTROLLER_ABI from "./abi/comptroller.json"; +import ERC20_ABI from "./abi/erc20.json"; +import VTOKEN_ABI from "./abi/vToken.json"; + +const { sepolia } = NETWORK_ADDRESSES; +const PROTOCOL_SHARE_RESERVE = "0xbea70755cc3555708ca11219adB0db4C80F6721B"; +const USDT_USER = "0x02EB950C215D12d723b44a18CfF098C6E166C531"; + +forking(6969766, async () => { + let resilientOracle: Contract; + let poolRegistry: Contract; + let veBTCContract: Contract; + let comptroller: Contract; + let eBTCContract: Contract; + let usdtPrimeConverter: Contract; + let usdt: Contract; + + before(async () => { + await impersonateAccount(sepolia.NORMAL_TIMELOCK); + await setBalance(sepolia.NORMAL_TIMELOCK, parseUnits("1000", 18)); + await impersonateAccount(USDT_USER); + await setBalance(USDT_USER, parseUnits("1000", 18)); + await impersonateAccount(USDT_PRIME_CONVERTER); + await setBalance(USDT_PRIME_CONVERTER, parseUnits("1000", 18)); + + resilientOracle = await ethers.getContractAt(RESILIENT_ORACLE_ABI, sepolia.RESILIENT_ORACLE); + poolRegistry = await ethers.getContractAt(POOL_REGISTRY_ABI, sepolia.POOL_REGISTRY); + veBTCContract = await ethers.getContractAt(VTOKEN_ABI, veBTC); + comptroller = await ethers.getContractAt(COMPTROLLER_ABI, CORE_COMPTROLLER); + eBTCContract = await ethers.getContractAt(ERC20_ABI, eBTC, await ethers.getSigner(sepolia.NORMAL_TIMELOCK)); + usdtPrimeConverter = await ethers.getContractAt(PRIME_CONVERTER_ABI, USDT_PRIME_CONVERTER); + usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); + }); + + testForkedNetworkVipCommands("vip391", await vip391()); + + describe("Post-VIP behavior", async () => { + it("check price", async () => { + expect(await resilientOracle.getPrice(eBTC)).to.be.equal("0"); + expect(await resilientOracle.getUnderlyingPrice(veBTC)).to.be.equal("0"); + }); + + it("should have 12 markets in core pool", async () => { + const poolVTokens = await comptroller.getAllMarkets(); + expect(poolVTokens).to.have.lengthOf(12); + }); + + it("should add veBTC to the pool", async () => { + const registeredVToken = await poolRegistry.getVTokenForAsset(comptroller.address, eBTC); + expect(registeredVToken).to.equal(veBTC); + }); + + it("check ownership", async () => { + expect(await veBTCContract.owner()).to.equal(sepolia.GUARDIAN); + }); + + it("check supply", async () => { + const expectedSupply = parseUnits("0.00000005", 18); + expect(await veBTCContract.balanceOf(sepolia.VTREASURY)).to.equal(expectedSupply); + }); + + it("check borrow and supply caps", async () => { + expect(await comptroller.borrowCaps(veBTC)).equals(BORROW_CAP); + expect(await comptroller.supplyCaps(veBTC)).equals(SUPPLY_CAP); + }); + + it("should set veBTC collateral factor to 50% and Liquidation threshold to 60%", async () => { + const market = await comptroller.markets(veBTC); + expect(market.collateralFactorMantissa).to.equal(parseUnits("0.5", 18)); + expect(market.liquidationThresholdMantissa).to.equal(parseUnits("0.6", 18)); + }); + + it("check protocol share reserve", async () => { + expect(await veBTCContract.protocolShareReserve()).equals(PROTOCOL_SHARE_RESERVE); + }); + + it("check reserve factor", async () => { + expect(await veBTCContract.reserveFactorMantissa()).equals(parseUnits("0.25", 18)); + }); + + it("check protocol seize share", async () => { + expect(await veBTCContract.protocolSeizeShareMantissa()).equals(parseUnits("0.01", 18)); + }); + + it("check vToken", async () => { + checkVToken(veBTC, { + name: "Venus eBTC", + symbol: "veBTC", + decimals: 8, + underlying: eBTC, + exchangeRate: parseUnits("10000000000", 18), + comptroller: CORE_COMPTROLLER, + }); + }); + + it("check IR", async () => { + const IR = await veBTCContract.interestRateModel(); + checkInterestRate( + IR, + "veBTCContract_Core", + { base: "0.02", multiplier: "0.15", jump: "3", kink: "0.45" }, + BigNumber.from(2252571), + ); + }); + + it("check Pool", async () => { + await eBTCContract.faucet(parseUnits("100", 18)); + await checkIsolatedPoolsComptrollers({ + [CORE_COMPTROLLER]: sepolia.NORMAL_TIMELOCK, + }); + }); + + it("eBTC conversion", async () => { + const usdtAmount = parseUnits("10", 6); + await usdt.connect(await ethers.getSigner(sepolia.NORMAL_TIMELOCK)).faucet(usdtAmount); + await usdt + .connect(await ethers.getSigner(sepolia.NORMAL_TIMELOCK)) + .approve(usdtPrimeConverter.address, usdtAmount); + + const eBTCAmount = parseUnits("2", 18); + await eBTCContract.connect(await ethers.getSigner(usdtPrimeConverter.address)).faucet(eBTCAmount); + + const usdtBalanceBefore = await usdt.balanceOf(sepolia.NORMAL_TIMELOCK); + const eBTCBalanceBefore = await eBTCContract.balanceOf(sepolia.NORMAL_TIMELOCK); + + await usdtPrimeConverter + .connect(await ethers.getSigner(sepolia.NORMAL_TIMELOCK)) + .convertForExactTokens(usdtAmount, eBTCAmount, usdt.address, eBTCContract.address, sepolia.NORMAL_TIMELOCK); + + const usdtBalanceAfter = await usdt.balanceOf(sepolia.NORMAL_TIMELOCK); + const eBTCBalanceAfter = await eBTCContract.balanceOf(sepolia.NORMAL_TIMELOCK); + + expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("6.999301", 6)); + expect(eBTCBalanceAfter.sub(eBTCBalanceBefore)).to.be.equal(eBTCAmount); + }); + }); +}); \ No newline at end of file diff --git a/vips/vip-391/bsctestnet.ts b/vips/vip-391/bsctestnet.ts new file mode 100644 index 000000000..1d6860b15 --- /dev/null +++ b/vips/vip-391/bsctestnet.ts @@ -0,0 +1,134 @@ +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +const { sepolia } = NETWORK_ADDRESSES; + +export const MOCK_ACCOUNTANT = "0xb4a5E8d4ba737fb27D6C5c43521fF1Da391c6CAE"; +export const ACCOUNTANT_ORACLE = "0xE621e50f74CfAdeeb059eEe1AdCd6e20cEe9E1a6"; +export const eBTC = "0xd48392CCf3fe028023D0783E570DFc71996859d7"; +const RATE = parseUnits("1", 8); +const INITIAL_SUPPLY = parseUnits("0.14471345", 8); +export const SUPPLY_CAP = parseUnits("25", 8); +export const BORROW_CAP = parseUnits("12.5", 8); +const CF = parseUnits("0.68", 18); +const LT = parseUnits("0.72", 18); +export const veBTC = "0x8E6241389e823111259413810b81a050bd45e5cE"; +export const CORE_COMPTROLLER = "0x7Aa39ab4BcA897F403425C9C6FDbd0f882Be0D70"; + +export const USDT_PRIME_CONVERTER = "0x3716C24EA86A67cAf890d7C9e4C4505cDDC2F8A2"; +export const USDC_PRIME_CONVERTER = "0x511a559a699cBd665546a1F75908f7E9454Bfc67"; +export const WBTC_PRIME_CONVERTER = "0x8a3937F27921e859db3FDA05729CbCea8cfd82AE"; +export const WETH_PRIME_CONVERTER = "0x274a834eFFA8D5479502dD6e78925Bc04ae82B46"; +export const XVS_VAULT_CONVERTER = "0xc203bfA9dCB0B5fEC510Db644A494Ff7f4968ed2"; +export const BaseAssets = [ + "0x8d412FD0bc5d826615065B931171Eed10F5AF266", // USDT USDTPrimeConverter BaseAsset + "0x772d68929655ce7234C8C94256526ddA66Ef641E", // USDC USDCPrimeConverter BaseAsset + "0x92A2928f5634BEa89A195e7BeCF0f0FEEDAB885b", // WBTC WBTCPrimeConverter BaseAsset + "0x7b79995e5f793A07Bc00c21412e50Ecae098E7f9", // WETH WETHPrimeConverter BaseAsset + "0x66ebd019E86e0af5f228a0439EBB33f045CBe63E", // XVS XVSPrimeConverter BaseAsset +]; +const CONVERSION_INCENTIVE = parseUnits("0.0001", 18); + +const vip391 = () => { + const meta = { + version: "v2", + title: "VIP-391", + description: `### Description`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + // Configure Oracle + { + target: MOCK_ACCOUNTANT, + signature: "setRate(uint256)", + params: [RATE], + }, + { + target: sepolia.RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [eBTC, [ACCOUNTANT_ORACLE, ethers.constants.AddressZero, ethers.constants.AddressZero], [true, false, false]], + ], + }, + + // Add Market + { + target: eBTC, + signature: "faucet(uint256)", + params: [INITIAL_SUPPLY], + dstChainId: LzChainId.sepolia, + }, + { + target: eBTC, + signature: "approve(address,uint256)", + params: [sepolia.POOL_REGISTRY, 0], + dstChainId: LzChainId.sepolia, + }, + { + target: eBTC, + signature: "approve(address,uint256)", + params: [sepolia.POOL_REGISTRY, INITIAL_SUPPLY], + dstChainId: LzChainId.sepolia, + }, + { + target: veBTC, + signature: "setReduceReservesBlockDelta(uint256)", + params: ["7200"], + dstChainId: LzChainId.sepolia, + }, + { + target: sepolia.POOL_REGISTRY, + signature: "addMarket((address,uint256,uint256,uint256,address,uint256,uint256))", + params: [[veBTC, CF, LT, INITIAL_SUPPLY, sepolia.VTREASURY, SUPPLY_CAP, BORROW_CAP]], + dstChainId: LzChainId.sepolia, + }, + { + target: veBTC, + signature: "setProtocolSeizeShare(uint256)", + params: [parseUnits("0.01", 18)], + dstChainId: LzChainId.sepolia, + }, + + // Conversion config + { + target: USDT_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[0], [eBTC], [[CONVERSION_INCENTIVE, 1]]], + dstChainId: LzChainId.sepolia, + }, + { + target: USDC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[1], [eBTC], [[CONVERSION_INCENTIVE, 1]]], + dstChainId: LzChainId.sepolia, + }, + { + target: WBTC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[2], [eBTC], [[CONVERSION_INCENTIVE, 1]]], + dstChainId: LzChainId.sepolia, + }, + { + target: WETH_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[3], [eBTC], [[CONVERSION_INCENTIVE, 1]]], + dstChainId: LzChainId.sepolia, + }, + { + target: XVS_VAULT_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[4], [eBTC], [[CONVERSION_INCENTIVE, 1]]], + dstChainId: LzChainId.sepolia, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip391; \ No newline at end of file From de8fe78673b21218c3e93380cd0eba6fe0ea83d8 Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 30 Oct 2024 17:35:17 +0400 Subject: [PATCH 079/178] fix: added vip for sepolia --- .../vip-391/abi/OmnichainProposalSender.json | 314 ++++ simulations/vip-391/abi/PoolRegistry.json | 310 ++++ simulations/vip-391/abi/PrimeConverter.json | 587 +++++++ simulations/vip-391/abi/ResilientOracle.json | 301 ++++ simulations/vip-391/abi/comptroller.json | 1496 +++++++++++++++++ simulations/vip-391/abi/erc20.json | 134 ++ simulations/vip-391/abi/vToken.json | 861 ++++++++++ simulations/vip-391/sepolia.ts | 32 +- vips/vip-391/bsctestnet.ts | 8 +- 9 files changed, 4024 insertions(+), 19 deletions(-) create mode 100644 simulations/vip-391/abi/OmnichainProposalSender.json create mode 100644 simulations/vip-391/abi/PoolRegistry.json create mode 100644 simulations/vip-391/abi/PrimeConverter.json create mode 100644 simulations/vip-391/abi/ResilientOracle.json create mode 100644 simulations/vip-391/abi/comptroller.json create mode 100644 simulations/vip-391/abi/erc20.json create mode 100644 simulations/vip-391/abi/vToken.json diff --git a/simulations/vip-391/abi/OmnichainProposalSender.json b/simulations/vip-391/abi/OmnichainProposalSender.json new file mode 100644 index 000000000..66fd4df02 --- /dev/null +++ b/simulations/vip-391/abi/OmnichainProposalSender.json @@ -0,0 +1,314 @@ +[ + { + "inputs": [ + { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } + ], + "name": "ClearPayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } + ], + "name": "ExecuteRemoteProposal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "FallbackWithdraw", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } + ], + "name": "StorePayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], + "name": "TrustedRemoteRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "LZ_ENDPOINT", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourCommandsSent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLastProposalSentTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bool", "name": "useZro_", "type": "bool" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } + ], + "name": "estimateFees", + "outputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } + ], + "name": "execute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "fallbackWithdraw", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "proposalCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], + "name": "removeTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "retryExecute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" }, + { "internalType": "bytes", "name": "config_", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "storedExecutionHashes", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } +] diff --git a/simulations/vip-391/abi/PoolRegistry.json b/simulations/vip-391/abi/PoolRegistry.json new file mode 100644 index 000000000..8f15277d2 --- /dev/null +++ b/simulations/vip-391/abi/PoolRegistry.json @@ -0,0 +1,310 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "vTokenAddress", "type": "address" } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "oldMetadata", + "type": "tuple" + }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "newMetadata", + "type": "tuple" + } + ], + "name": "PoolMetadataUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "oldName", "type": "string" }, + { "indexed": false, "internalType": "string", "name": "newName", "type": "string" } + ], + "name": "PoolNameSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPool", + "name": "pool", + "type": "tuple" + } + ], + "name": "PoolRegistered", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "collateralFactor", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThreshold", "type": "uint256" }, + { "internalType": "uint256", "name": "initialSupply", "type": "uint256" }, + { "internalType": "address", "name": "vTokenReceiver", "type": "address" }, + { "internalType": "uint256", "name": "supplyCap", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCap", "type": "uint256" } + ], + "internalType": "struct PoolRegistry.AddMarketInput", + "name": "input", + "type": "tuple" + } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "contract Comptroller", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "closeFactor", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationIncentive", "type": "uint256" }, + { "internalType": "uint256", "name": "minLiquidatableCollateral", "type": "uint256" } + ], + "name": "addPool", + "outputs": [{ "internalType": "uint256", "name": "index", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getAllPools", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool[]", + "name": "", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "comptroller", "type": "address" }], + "name": "getPoolByComptroller", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPoolsSupportedByAsset", + "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "getVTokenForAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "comptroller", "type": "address" }], + "name": "getVenusPoolMetadata", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "metadata", + "outputs": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "string", "name": "name", "type": "string" } + ], + "name": "setPoolName", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "metadata_", + "type": "tuple" + } + ], + "name": "updatePoolMetadata", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-391/abi/PrimeConverter.json b/simulations/vip-391/abi/PrimeConverter.json new file mode 100644 index 000000000..8ea10cc8d --- /dev/null +++ b/simulations/vip-391/abi/PrimeConverter.json @@ -0,0 +1,587 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { "inputs": [], "name": "AmountInMismatched", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, + { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, + { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, + { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, + { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, + { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, + { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, + { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, + { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, + { "inputs": [], "name": "InvalidToAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, + { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetTransferredToDestination", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } + ], + "name": "BaseAssetUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, + { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "baseAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "conversionConfigurations", + "outputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, + { "internalType": "address", "name": "destinationAddress_", "type": "address" }, + { "internalType": "address", "name": "baseAsset_", "type": "address" }, + { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], + "name": "setBaseAsset", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-391/abi/ResilientOracle.json b/simulations/vip-391/abi/ResilientOracle.json new file mode 100644 index 000000000..e2f944a9d --- /dev/null +++ b/simulations/vip-391/abi/ResilientOracle.json @@ -0,0 +1,301 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "nativeMarketAddress", "type": "address" }, + { "internalType": "address", "name": "vaiAddress", "type": "address" }, + { "internalType": "contract BoundValidatorInterface", "name": "_boundValidator", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "role", "type": "uint256" }, + { "indexed": true, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "oracle", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "role", "type": "uint256" } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "mainOracle", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "pivotOracle", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "fallbackOracle", "type": "address" } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [{ "internalType": "contract BoundValidatorInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" } + ], + "name": "getOracle", + "outputs": [ + { "internalType": "address", "name": "oracle", "type": "address" }, + { "internalType": "bool", "name": "enabled", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getUnderlyingPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address", "name": "oracle", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-391/abi/comptroller.json b/simulations/vip-391/abi/comptroller.json new file mode 100644 index 000000000..fafe7b35e --- /dev/null +++ b/simulations/vip-391/abi/comptroller.json @@ -0,0 +1,1496 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "poolRegistry_", + "type": "address" + }, + { + "internalType": "address", + "name": "accessControl_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedLessThanOrEqualTo", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { + "inputs": [], + "name": "ComptrollerMismatch", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "collateralToSeize", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "availableCollateral", + "type": "uint256" + } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientLiquidity", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientShortfall", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidCollateralFactor", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidLiquidationThreshold", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedGreaterThan", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { + "inputs": [], + "name": "NonzeroBorrowBalance", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { + "inputs": [], + "name": "TooMuchRepay", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "expectedSender", + "type": "address" + }, + { + "internalType": "address", + "name": "actualSender", + "type": "address" + } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "bool", + "name": "pauseState", + "type": "bool" + } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newBorrowCap", + "type": "uint256" + } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldCloseFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldCollateralFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationIncentiveMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationThresholdMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMinLiquidatableCollateral", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "rewardsDistributor", + "type": "address" + } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSupplyCap", + "type": "uint256" + } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControl", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "accountAssets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "actionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract RewardsDistributor", + "name": "_rewardsDistributor", + "type": "address" + } + ], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "allMarkets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "borrowCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "checkMembership", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "vTokens", + "type": "address[]" + } + ], + "name": "enterMarkets", + "outputs": [ + { + "internalType": "uint256[]", + "name": "", + "type": "uint256[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenAddress", + "type": "address" + } + ], + "name": "exitMarket", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAssetsIn", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenModify", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [ + { + "internalType": "contract RewardsDistributor[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "rewardToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "supplySpeed", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowSpeed", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isDeprecated", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isMarketListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "components": [ + { + "internalType": "contract VToken", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokensToSeize", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "markets", + "outputs": [ + { + "internalType": "bool", + "name": "isListed", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "collateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidationThresholdMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [ + { + "internalType": "contract PriceOracle", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "skipLiquidityCheck", + "type": "bool" + } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "seizerContract", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "transferTokens", + "type": "uint256" + } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "marketsList", + "type": "address[]" + }, + { + "internalType": "enum ComptrollerStorage.Action[]", + "name": "actionsList", + "type": "uint8[]" + }, + { + "internalType": "bool", + "name": "paused", + "type": "bool" + } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newBorrowCaps", + "type": "uint256[]" + } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newSupplyCaps", + "type": "uint256[]" + } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract PriceOracle", + "name": "newOracle", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "supplyCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-391/abi/erc20.json b/simulations/vip-391/abi/erc20.json new file mode 100644 index 000000000..3a509c9c4 --- /dev/null +++ b/simulations/vip-391/abi/erc20.json @@ -0,0 +1,134 @@ +[ + { + "inputs": [ + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "name": "faucet", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "from", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-391/abi/vToken.json b/simulations/vip-391/abi/vToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/simulations/vip-391/abi/vToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-391/sepolia.ts b/simulations/vip-391/sepolia.ts index 956a3368c..1b26315df 100644 --- a/simulations/vip-391/sepolia.ts +++ b/simulations/vip-391/sepolia.ts @@ -13,9 +13,9 @@ import vip391, { BORROW_CAP, BaseAssets, CORE_COMPTROLLER, - eBTC, SUPPLY_CAP, USDT_PRIME_CONVERTER, + eBTC, veBTC, } from "../../vips/vip-391/bsctestnet"; import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; @@ -29,7 +29,7 @@ const { sepolia } = NETWORK_ADDRESSES; const PROTOCOL_SHARE_RESERVE = "0xbea70755cc3555708ca11219adB0db4C80F6721B"; const USDT_USER = "0x02EB950C215D12d723b44a18CfF098C6E166C531"; -forking(6969766, async () => { +forking(6976822, async () => { let resilientOracle: Contract; let poolRegistry: Contract; let veBTCContract: Contract; @@ -59,8 +59,8 @@ forking(6969766, async () => { describe("Post-VIP behavior", async () => { it("check price", async () => { - expect(await resilientOracle.getPrice(eBTC)).to.be.equal("0"); - expect(await resilientOracle.getUnderlyingPrice(veBTC)).to.be.equal("0"); + expect(await resilientOracle.getPrice(eBTC)).to.be.equal(parseUnits("720189057123700", 18)); + expect(await resilientOracle.getUnderlyingPrice(veBTC)).to.be.equal(parseUnits("720189057123700", 18)); }); it("should have 12 markets in core pool", async () => { @@ -78,7 +78,7 @@ forking(6969766, async () => { }); it("check supply", async () => { - const expectedSupply = parseUnits("0.00000005", 18); + const expectedSupply = parseUnits("0.14471345", 8); expect(await veBTCContract.balanceOf(sepolia.VTREASURY)).to.equal(expectedSupply); }); @@ -87,10 +87,10 @@ forking(6969766, async () => { expect(await comptroller.supplyCaps(veBTC)).equals(SUPPLY_CAP); }); - it("should set veBTC collateral factor to 50% and Liquidation threshold to 60%", async () => { + it("should set veBTC collateral factor to 68% and Liquidation threshold to 72%", async () => { const market = await comptroller.markets(veBTC); - expect(market.collateralFactorMantissa).to.equal(parseUnits("0.5", 18)); - expect(market.liquidationThresholdMantissa).to.equal(parseUnits("0.6", 18)); + expect(market.collateralFactorMantissa).to.equal(parseUnits("0.68", 18)); + expect(market.liquidationThresholdMantissa).to.equal(parseUnits("0.72", 18)); }); it("check protocol share reserve", async () => { @@ -98,7 +98,7 @@ forking(6969766, async () => { }); it("check reserve factor", async () => { - expect(await veBTCContract.reserveFactorMantissa()).equals(parseUnits("0.25", 18)); + expect(await veBTCContract.reserveFactorMantissa()).equals(parseUnits("0.2", 18)); }); it("check protocol seize share", async () => { @@ -111,7 +111,7 @@ forking(6969766, async () => { symbol: "veBTC", decimals: 8, underlying: eBTC, - exchangeRate: parseUnits("10000000000", 18), + exchangeRate: parseUnits("10000000000", 8), comptroller: CORE_COMPTROLLER, }); }); @@ -121,8 +121,8 @@ forking(6969766, async () => { checkInterestRate( IR, "veBTCContract_Core", - { base: "0.02", multiplier: "0.15", jump: "3", kink: "0.45" }, - BigNumber.from(2252571), + { base: "0", multiplier: "0.09", jump: "2", kink: "0.45" }, + BigNumber.from(2628000), ); }); @@ -134,13 +134,13 @@ forking(6969766, async () => { }); it("eBTC conversion", async () => { - const usdtAmount = parseUnits("10", 6); + const usdtAmount = parseUnits("50000", 6); await usdt.connect(await ethers.getSigner(sepolia.NORMAL_TIMELOCK)).faucet(usdtAmount); await usdt .connect(await ethers.getSigner(sepolia.NORMAL_TIMELOCK)) .approve(usdtPrimeConverter.address, usdtAmount); - const eBTCAmount = parseUnits("2", 18); + const eBTCAmount = parseUnits("0.5", 8); await eBTCContract.connect(await ethers.getSigner(usdtPrimeConverter.address)).faucet(eBTCAmount); const usdtBalanceBefore = await usdt.balanceOf(sepolia.NORMAL_TIMELOCK); @@ -153,8 +153,8 @@ forking(6969766, async () => { const usdtBalanceAfter = await usdt.balanceOf(sepolia.NORMAL_TIMELOCK); const eBTCBalanceAfter = await eBTCContract.balanceOf(sepolia.NORMAL_TIMELOCK); - expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("6.999301", 6)); + expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("36005.852271", 6)); expect(eBTCBalanceAfter.sub(eBTCBalanceBefore)).to.be.equal(eBTCAmount); }); }); -}); \ No newline at end of file +}); diff --git a/vips/vip-391/bsctestnet.ts b/vips/vip-391/bsctestnet.ts index 1d6860b15..3349ff02a 100644 --- a/vips/vip-391/bsctestnet.ts +++ b/vips/vip-391/bsctestnet.ts @@ -6,8 +6,8 @@ import { makeProposal } from "src/utils"; const { sepolia } = NETWORK_ADDRESSES; -export const MOCK_ACCOUNTANT = "0xb4a5E8d4ba737fb27D6C5c43521fF1Da391c6CAE"; -export const ACCOUNTANT_ORACLE = "0xE621e50f74CfAdeeb059eEe1AdCd6e20cEe9E1a6"; +export const MOCK_ACCOUNTANT = "0x01466F572A9F1A0353A491187D32DfB28F2BF94c"; +export const ACCOUNTANT_ORACLE = "0xD819F6fC189691A78Ff226Da51F63597e679b601"; export const eBTC = "0xd48392CCf3fe028023D0783E570DFc71996859d7"; const RATE = parseUnits("1", 8); const INITIAL_SUPPLY = parseUnits("0.14471345", 8); @@ -48,6 +48,7 @@ const vip391 = () => { target: MOCK_ACCOUNTANT, signature: "setRate(uint256)", params: [RATE], + dstChainId: LzChainId.sepolia, }, { target: sepolia.RESILIENT_ORACLE, @@ -55,6 +56,7 @@ const vip391 = () => { params: [ [eBTC, [ACCOUNTANT_ORACLE, ethers.constants.AddressZero, ethers.constants.AddressZero], [true, false, false]], ], + dstChainId: LzChainId.sepolia, }, // Add Market @@ -131,4 +133,4 @@ const vip391 = () => { ProposalType.REGULAR, ); }; -export default vip391; \ No newline at end of file +export default vip391; From 351647727e6cb9f1532d71f9c54fa9d0a630411b Mon Sep 17 00:00:00 2001 From: Narayan <7037606+web3rover@users.noreply.github.com> Date: Wed, 30 Oct 2024 20:22:02 +0400 Subject: [PATCH 080/178] fix: remove setProtocolSeizeShare Co-authored-by: Jesus Lanchas --- vips/vip-391/bsctestnet.ts | 6 ------ 1 file changed, 6 deletions(-) diff --git a/vips/vip-391/bsctestnet.ts b/vips/vip-391/bsctestnet.ts index 3349ff02a..0512b5262 100644 --- a/vips/vip-391/bsctestnet.ts +++ b/vips/vip-391/bsctestnet.ts @@ -90,12 +90,6 @@ const vip391 = () => { params: [[veBTC, CF, LT, INITIAL_SUPPLY, sepolia.VTREASURY, SUPPLY_CAP, BORROW_CAP]], dstChainId: LzChainId.sepolia, }, - { - target: veBTC, - signature: "setProtocolSeizeShare(uint256)", - params: [parseUnits("0.01", 18)], - dstChainId: LzChainId.sepolia, - }, // Conversion config { From edc3a40eb069ce07b2643bff72db821827e51a3e Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 30 Oct 2024 20:29:00 +0400 Subject: [PATCH 081/178] fix: added bsctestnet vip --- simulations/vip-391/bsctestnet.ts | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 simulations/vip-391/bsctestnet.ts diff --git a/simulations/vip-391/bsctestnet.ts b/simulations/vip-391/bsctestnet.ts new file mode 100644 index 000000000..69d103678 --- /dev/null +++ b/simulations/vip-391/bsctestnet.ts @@ -0,0 +1,17 @@ +import { expectEvents } from "../../src/utils"; +import { forking, testVip } from "../../src/vip-framework"; +import vip391 from "../../vips/vip-391/bsctestnet"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +forking(45194889, async () => { + testVip("vip391", await vip391(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [1, 0], + ); + }, + }); +}); \ No newline at end of file From f8f67d8c4397fbd515c15a95ac47c906fae584af Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 30 Oct 2024 21:44:57 +0400 Subject: [PATCH 082/178] fix: wip - mainnet vip --- multisig/proposals/ethereum/vip-067/index.ts | 118 ++ .../ethereum/vip-067/abi/PoolRegistry.json | 310 ++++ .../ethereum/vip-067/abi/PrimeConverter.json | 587 +++++++ .../ethereum/vip-067/abi/ResilientOracle.json | 301 ++++ .../ethereum/vip-067/abi/comptroller.json | 1496 +++++++++++++++++ .../ethereum/vip-067/abi/erc20.json | 134 ++ .../ethereum/vip-067/abi/vToken.json | 861 ++++++++++ .../simulations/ethereum/vip-067/index.ts | 158 ++ 8 files changed, 3965 insertions(+) create mode 100644 multisig/proposals/ethereum/vip-067/index.ts create mode 100644 multisig/simulations/ethereum/vip-067/abi/PoolRegistry.json create mode 100644 multisig/simulations/ethereum/vip-067/abi/PrimeConverter.json create mode 100644 multisig/simulations/ethereum/vip-067/abi/ResilientOracle.json create mode 100644 multisig/simulations/ethereum/vip-067/abi/comptroller.json create mode 100644 multisig/simulations/ethereum/vip-067/abi/erc20.json create mode 100644 multisig/simulations/ethereum/vip-067/abi/vToken.json create mode 100644 multisig/simulations/ethereum/vip-067/index.ts diff --git a/multisig/proposals/ethereum/vip-067/index.ts b/multisig/proposals/ethereum/vip-067/index.ts new file mode 100644 index 000000000..94e49e023 --- /dev/null +++ b/multisig/proposals/ethereum/vip-067/index.ts @@ -0,0 +1,118 @@ +import { parseUnits } from "ethers/lib/utils"; + +import { makeProposal } from "../../../../src/utils"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { ethers } from "hardhat"; + +const { ethereum } = NETWORK_ADDRESSES; + +export const EIGEN = "0xec53bf9167f50cdeb3ae105f56099aaab9061f83"; +const INITIAL_SUPPLY = parseUnits("0", 18); +export const SUPPLY_CAP = parseUnits("3000000", 18); +export const BORROW_CAP = parseUnits("1500000", 18); +const CF = parseUnits("0.5", 18); +const LT = parseUnits("0.6", 18); +export const vEIGEN = "0x256AdDBe0a387c98f487e44b85c29eb983413c5e"; +export const CORE_COMPTROLLER = "0x687a01ecF6d3907658f7A7c714749fAC32336D1B"; + +export const USDT_PRIME_CONVERTER = "0x4f55cb0a24D5542a3478B0E284259A6B850B06BD"; +export const USDC_PRIME_CONVERTER = "0xcEB9503f10B781E30213c0b320bCf3b3cE54216E"; +export const WBTC_PRIME_CONVERTER = "0xDcCDE673Cd8988745dA384A7083B0bd22085dEA0"; +export const WETH_PRIME_CONVERTER = "0xb8fD67f215117FADeF06447Af31590309750529D"; +export const XVS_VAULT_CONVERTER = "0x1FD30e761C3296fE36D9067b1e398FD97B4C0407"; +export const BaseAssets = [ + "0xdAC17F958D2ee523a2206206994597C13D831ec7", // USDT USDTTokenConverter BaseAsset + "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48", // USDC USDCTokenConverter BaseAsset + "0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599", // WBTC WBTCTokenConverter BaseAsset + "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2", // WETH WETHTokenConverter BaseAsset + "0xd3CC9d8f3689B83c91b7B59cAB4946B063EB894A", // XVS XVSTokenConverter BaseAsset +]; +const CONVERSION_INCENTIVE = parseUnits("0.0001", 18); +const CHAINLINK_FEED = "0xf2917e602C2dCa458937fad715bb1E465305A4A1"; +const MAX_STALE_PERIOD = 30 * 3600; + +export const vip067 = () => { + return makeProposal([ + { + target: ethereum.CHAINLINK_ORACLE, + signature: "setTokenConfig((address,address,uint256))", + params: [[EIGEN, CHAINLINK_FEED, MAX_STALE_PERIOD]], + }, + { + target: ethereum.RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [ + EIGEN, + [ethereum.CHAINLINK_ORACLE, ethers.constants.AddressZero, ethers.constants.AddressZero], + [true, false, false], + ], + ], + }, + + // Add Market + { + target: EIGEN, + signature: "approve(address,uint256)", + params: [ethereum.POOL_REGISTRY, 0], + }, + { + target: EIGEN, + signature: "approve(address,uint256)", + params: [ethereum.POOL_REGISTRY, INITIAL_SUPPLY], + + }, + { + target: vEIGEN, + signature: "setReduceReservesBlockDelta(uint256)", + params: ["7200"], + + }, + { + target: ethereum.POOL_REGISTRY, + signature: "addMarket((address,uint256,uint256,uint256,address,uint256,uint256))", + params: [[vEIGEN, CF, LT, INITIAL_SUPPLY, ethereum.VTREASURY, SUPPLY_CAP, BORROW_CAP]], + + }, + { + target: vEIGEN, + signature: "setProtocolSeizeShare(uint256)", + params: [parseUnits("0.01", 18)], + + }, + + // Conversion config + { + target: USDT_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[0], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], + + }, + { + target: USDC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[1], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], + + }, + { + target: WBTC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[2], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], + + }, + { + target: WETH_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[3], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], + + }, + { + target: XVS_VAULT_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[4], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], + + }, + ]); +}; + +export default vip067; diff --git a/multisig/simulations/ethereum/vip-067/abi/PoolRegistry.json b/multisig/simulations/ethereum/vip-067/abi/PoolRegistry.json new file mode 100644 index 000000000..8f15277d2 --- /dev/null +++ b/multisig/simulations/ethereum/vip-067/abi/PoolRegistry.json @@ -0,0 +1,310 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "vTokenAddress", "type": "address" } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "oldMetadata", + "type": "tuple" + }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "newMetadata", + "type": "tuple" + } + ], + "name": "PoolMetadataUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "oldName", "type": "string" }, + { "indexed": false, "internalType": "string", "name": "newName", "type": "string" } + ], + "name": "PoolNameSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPool", + "name": "pool", + "type": "tuple" + } + ], + "name": "PoolRegistered", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "collateralFactor", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThreshold", "type": "uint256" }, + { "internalType": "uint256", "name": "initialSupply", "type": "uint256" }, + { "internalType": "address", "name": "vTokenReceiver", "type": "address" }, + { "internalType": "uint256", "name": "supplyCap", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCap", "type": "uint256" } + ], + "internalType": "struct PoolRegistry.AddMarketInput", + "name": "input", + "type": "tuple" + } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "contract Comptroller", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "closeFactor", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationIncentive", "type": "uint256" }, + { "internalType": "uint256", "name": "minLiquidatableCollateral", "type": "uint256" } + ], + "name": "addPool", + "outputs": [{ "internalType": "uint256", "name": "index", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getAllPools", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool[]", + "name": "", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "comptroller", "type": "address" }], + "name": "getPoolByComptroller", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPoolsSupportedByAsset", + "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "getVTokenForAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "comptroller", "type": "address" }], + "name": "getVenusPoolMetadata", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "metadata", + "outputs": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "string", "name": "name", "type": "string" } + ], + "name": "setPoolName", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "metadata_", + "type": "tuple" + } + ], + "name": "updatePoolMetadata", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-067/abi/PrimeConverter.json b/multisig/simulations/ethereum/vip-067/abi/PrimeConverter.json new file mode 100644 index 000000000..8ea10cc8d --- /dev/null +++ b/multisig/simulations/ethereum/vip-067/abi/PrimeConverter.json @@ -0,0 +1,587 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { "inputs": [], "name": "AmountInMismatched", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, + { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, + { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, + { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, + { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, + { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, + { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, + { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, + { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, + { "inputs": [], "name": "InvalidToAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, + { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetTransferredToDestination", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } + ], + "name": "BaseAssetUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, + { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "baseAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "conversionConfigurations", + "outputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, + { "internalType": "address", "name": "destinationAddress_", "type": "address" }, + { "internalType": "address", "name": "baseAsset_", "type": "address" }, + { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], + "name": "setBaseAsset", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-067/abi/ResilientOracle.json b/multisig/simulations/ethereum/vip-067/abi/ResilientOracle.json new file mode 100644 index 000000000..e2f944a9d --- /dev/null +++ b/multisig/simulations/ethereum/vip-067/abi/ResilientOracle.json @@ -0,0 +1,301 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "nativeMarketAddress", "type": "address" }, + { "internalType": "address", "name": "vaiAddress", "type": "address" }, + { "internalType": "contract BoundValidatorInterface", "name": "_boundValidator", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "role", "type": "uint256" }, + { "indexed": true, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "oracle", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "role", "type": "uint256" } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "mainOracle", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "pivotOracle", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "fallbackOracle", "type": "address" } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [{ "internalType": "contract BoundValidatorInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" } + ], + "name": "getOracle", + "outputs": [ + { "internalType": "address", "name": "oracle", "type": "address" }, + { "internalType": "bool", "name": "enabled", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getUnderlyingPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address", "name": "oracle", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-067/abi/comptroller.json b/multisig/simulations/ethereum/vip-067/abi/comptroller.json new file mode 100644 index 000000000..fafe7b35e --- /dev/null +++ b/multisig/simulations/ethereum/vip-067/abi/comptroller.json @@ -0,0 +1,1496 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "poolRegistry_", + "type": "address" + }, + { + "internalType": "address", + "name": "accessControl_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedLessThanOrEqualTo", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { + "inputs": [], + "name": "ComptrollerMismatch", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "collateralToSeize", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "availableCollateral", + "type": "uint256" + } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientLiquidity", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientShortfall", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidCollateralFactor", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidLiquidationThreshold", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedGreaterThan", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { + "inputs": [], + "name": "NonzeroBorrowBalance", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { + "inputs": [], + "name": "TooMuchRepay", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "expectedSender", + "type": "address" + }, + { + "internalType": "address", + "name": "actualSender", + "type": "address" + } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "bool", + "name": "pauseState", + "type": "bool" + } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newBorrowCap", + "type": "uint256" + } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldCloseFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldCollateralFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationIncentiveMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationThresholdMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMinLiquidatableCollateral", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "rewardsDistributor", + "type": "address" + } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSupplyCap", + "type": "uint256" + } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControl", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "accountAssets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "actionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract RewardsDistributor", + "name": "_rewardsDistributor", + "type": "address" + } + ], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "allMarkets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "borrowCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "checkMembership", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "vTokens", + "type": "address[]" + } + ], + "name": "enterMarkets", + "outputs": [ + { + "internalType": "uint256[]", + "name": "", + "type": "uint256[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenAddress", + "type": "address" + } + ], + "name": "exitMarket", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAssetsIn", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenModify", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [ + { + "internalType": "contract RewardsDistributor[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "rewardToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "supplySpeed", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowSpeed", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isDeprecated", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isMarketListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "components": [ + { + "internalType": "contract VToken", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokensToSeize", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "markets", + "outputs": [ + { + "internalType": "bool", + "name": "isListed", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "collateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidationThresholdMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [ + { + "internalType": "contract PriceOracle", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "skipLiquidityCheck", + "type": "bool" + } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "seizerContract", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "transferTokens", + "type": "uint256" + } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "marketsList", + "type": "address[]" + }, + { + "internalType": "enum ComptrollerStorage.Action[]", + "name": "actionsList", + "type": "uint8[]" + }, + { + "internalType": "bool", + "name": "paused", + "type": "bool" + } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newBorrowCaps", + "type": "uint256[]" + } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newSupplyCaps", + "type": "uint256[]" + } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract PriceOracle", + "name": "newOracle", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "supplyCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-067/abi/erc20.json b/multisig/simulations/ethereum/vip-067/abi/erc20.json new file mode 100644 index 000000000..3a509c9c4 --- /dev/null +++ b/multisig/simulations/ethereum/vip-067/abi/erc20.json @@ -0,0 +1,134 @@ +[ + { + "inputs": [ + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "name": "faucet", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "from", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-067/abi/vToken.json b/multisig/simulations/ethereum/vip-067/abi/vToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/multisig/simulations/ethereum/vip-067/abi/vToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-067/index.ts b/multisig/simulations/ethereum/vip-067/index.ts new file mode 100644 index 000000000..c684af2a5 --- /dev/null +++ b/multisig/simulations/ethereum/vip-067/index.ts @@ -0,0 +1,158 @@ +import { expect } from "chai"; +import { BigNumber, Contract } from "ethers"; +import { ethers } from "hardhat"; + +import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; +import vip067, { + EIGEN, + vEIGEN, + CORE_COMPTROLLER, + USDT_PRIME_CONVERTER, + BaseAssets, + BORROW_CAP, SUPPLY_CAP +} from "../../../proposals/ethereum/vip-067"; +import { impersonateAccount, setBalance } from "@nomicfoundation/hardhat-network-helpers"; +import { parseUnits } from "ethers/lib/utils"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; +import PRIME_CONVERTER_ABI from "./abi/PrimeConverter.json"; +import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; +import COMPTROLLER_ABI from "./abi/comptroller.json"; +import ERC20_ABI from "./abi/erc20.json"; +import VTOKEN_ABI from "./abi/vToken.json"; +import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIsolatedPoolsComptrollers"; +import { checkVToken } from "src/vip-framework/checks/checkVToken"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; +const { ethereum } = NETWORK_ADDRESSES; +const PROTOCOL_SHARE_RESERVE = "0x8c8c8530464f7D95552A11eC31Adbd4dC4AC4d3E"; +const USDT_USER = "0x02EB950C215D12d723b44a18CfF098C6E166C531"; + +forking(21079955, async () => { + let resilientOracle: Contract; + let poolRegistry: Contract; + let vEIGENContract: Contract; + let comptroller: Contract; + let eigenContract: Contract; + let usdtPrimeConverter: Contract; + let usdt: Contract; + + describe("Post-VIP behavior", async () => { + before(async () => { + await impersonateAccount(ethereum.NORMAL_TIMELOCK); + await setBalance(ethereum.NORMAL_TIMELOCK, parseUnits("1000", 18)); + await impersonateAccount(USDT_USER); + await setBalance(USDT_USER, parseUnits("1000", 18)); + await impersonateAccount(USDT_PRIME_CONVERTER); + await setBalance(USDT_PRIME_CONVERTER, parseUnits("1000", 18)); + + resilientOracle = await ethers.getContractAt(RESILIENT_ORACLE_ABI, ethereum.RESILIENT_ORACLE); + poolRegistry = await ethers.getContractAt(POOL_REGISTRY_ABI, ethereum.POOL_REGISTRY); + vEIGENContract = await ethers.getContractAt(VTOKEN_ABI, vEIGEN); + comptroller = await ethers.getContractAt(COMPTROLLER_ABI, CORE_COMPTROLLER); + eigenContract = await ethers.getContractAt(ERC20_ABI, EIGEN, await ethers.getSigner(ethereum.NORMAL_TIMELOCK)); + usdtPrimeConverter = await ethers.getContractAt(PRIME_CONVERTER_ABI, USDT_PRIME_CONVERTER); + usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); + + await pretendExecutingVip(await vip067()); + }); + + it("check price", async () => { + expect(await resilientOracle.getPrice(EIGEN)).to.be.equal(parseUnits("3.0196419", 18)); + expect(await resilientOracle.getUnderlyingPrice(vEIGEN)).to.be.equal(parseUnits("3.0196419", 18)); + }); + + it("should have 12 markets in core pool", async () => { + const poolVTokens = await comptroller.getAllMarkets(); + expect(poolVTokens).to.have.lengthOf(12); + }); + + it("should add vEIGEN to the pool", async () => { + const registeredVToken = await poolRegistry.getVTokenForAsset(comptroller.address, EIGEN); + expect(registeredVToken).to.equal(vEIGEN); + }); + + it("check ownership", async () => { + expect(await vEIGENContract.owner()).to.equal(ethereum.GUARDIAN); + }); + + it("check supply", async () => { + const expectedSupply = parseUnits("0", 18); + expect(await vEIGENContract.balanceOf(ethereum.VTREASURY)).to.equal(expectedSupply); + }); + + it("check borrow and supply caps", async () => { + expect(await comptroller.borrowCaps(vEIGEN)).equals(BORROW_CAP); + expect(await comptroller.supplyCaps(vEIGEN)).equals(SUPPLY_CAP); + }); + + it("should set vEIGEN collateral factor to 50% and Liquidation threshold to 60%", async () => { + const market = await comptroller.markets(vEIGEN); + expect(market.collateralFactorMantissa).to.equal(parseUnits("0.5", 18)); + expect(market.liquidationThresholdMantissa).to.equal(parseUnits("0.6", 18)); + }); + + it("check protocol share reserve", async () => { + expect(await vEIGENContract.protocolShareReserve()).equals(PROTOCOL_SHARE_RESERVE); + }); + + it("check reserve factor", async () => { + expect(await vEIGENContract.reserveFactorMantissa()).equals(parseUnits("0.25", 18)); + }); + + it("check protocol seize share", async () => { + expect(await vEIGENContract.protocolSeizeShareMantissa()).equals(parseUnits("0.01", 18)); + }); + + it("check vToken", async () => { + checkVToken(vEIGEN, { + name: "Venus EIGEN", + symbol: "vEIGEN", + decimals: 8, + underlying: EIGEN, + exchangeRate: parseUnits("10000000000", 18), + comptroller: CORE_COMPTROLLER, + }); + }); + + it("check IR", async () => { + const IR = await vEIGENContract.interestRateModel(); + checkInterestRate( + IR, + "vEIGENContract_Core", + { base: "0.02", multiplier: "0.15", jump: "3", kink: "0.45" }, + BigNumber.from(2252571), + ); + }); + + it("check Pool", async () => { + await eigenContract.faucet(parseUnits("100", 18)); + await checkIsolatedPoolsComptrollers({ + [CORE_COMPTROLLER]: ethereum.NORMAL_TIMELOCK, + }); + }); + + it("EIGEN conversion", async () => { + const usdtAmount = parseUnits("10", 6); + await usdt.connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)).faucet(usdtAmount); + await usdt + .connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)) + .approve(usdtPrimeConverter.address, usdtAmount); + + const eigenAmount = parseUnits("2", 18); + await eigenContract.connect(await ethers.getSigner(usdtPrimeConverter.address)).faucet(eigenAmount); + + const usdtBalanceBefore = await usdt.balanceOf(ethereum.NORMAL_TIMELOCK); + const eigenBalanceBefore = await eigenContract.balanceOf(ethereum.NORMAL_TIMELOCK); + + await usdtPrimeConverter + .connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)) + .convertForExactTokens(usdtAmount, eigenAmount, usdt.address, eigenContract.address, ethereum.NORMAL_TIMELOCK); + + const usdtBalanceAfter = await usdt.balanceOf(ethereum.NORMAL_TIMELOCK); + const eigenBalanceAfter = await eigenContract.balanceOf(ethereum.NORMAL_TIMELOCK); + + expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("6.999301", 6)); + expect(eigenBalanceAfter.sub(eigenBalanceBefore)).to.be.equal(eigenAmount); + }); + }); +}); From 1fd5229c852c2e1e00ea178165edc49540424991 Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 30 Oct 2024 21:52:45 +0400 Subject: [PATCH 083/178] fix: wip - mainnet vip --- multisig/proposals/ethereum/vip-068/index.ts | 112 ++ .../ethereum/vip-068/abi/PoolRegistry.json | 310 ++++ .../ethereum/vip-068/abi/PrimeConverter.json | 587 +++++++ .../ethereum/vip-068/abi/ResilientOracle.json | 301 ++++ .../ethereum/vip-068/abi/comptroller.json | 1496 +++++++++++++++++ .../ethereum/vip-068/abi/erc20.json | 134 ++ .../ethereum/vip-068/abi/vToken.json | 861 ++++++++++ .../simulations/ethereum/vip-068/index.ts | 158 ++ 8 files changed, 3959 insertions(+) create mode 100644 multisig/proposals/ethereum/vip-068/index.ts create mode 100644 multisig/simulations/ethereum/vip-068/abi/PoolRegistry.json create mode 100644 multisig/simulations/ethereum/vip-068/abi/PrimeConverter.json create mode 100644 multisig/simulations/ethereum/vip-068/abi/ResilientOracle.json create mode 100644 multisig/simulations/ethereum/vip-068/abi/comptroller.json create mode 100644 multisig/simulations/ethereum/vip-068/abi/erc20.json create mode 100644 multisig/simulations/ethereum/vip-068/abi/vToken.json create mode 100644 multisig/simulations/ethereum/vip-068/index.ts diff --git a/multisig/proposals/ethereum/vip-068/index.ts b/multisig/proposals/ethereum/vip-068/index.ts new file mode 100644 index 000000000..c5a3b7d10 --- /dev/null +++ b/multisig/proposals/ethereum/vip-068/index.ts @@ -0,0 +1,112 @@ +import { parseUnits } from "ethers/lib/utils"; + +import { makeProposal } from "../../../../src/utils"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { ethers } from "hardhat"; + +const { ethereum } = NETWORK_ADDRESSES; + +export const eBTC = "0x657e8c867d8b37dcc18fa4caead9c45eb088c642"; +const INITIAL_SUPPLY = parseUnits("0.14471345", 8); +export const SUPPLY_CAP = parseUnits("25", 8); +export const BORROW_CAP = parseUnits("12.6", 8); +const CF = parseUnits("0.68", 18); +const LT = parseUnits("0.72", 18); +export const veBTC = "0x325cEB02fe1C2fF816A83a5770eA0E88e2faEcF2"; +export const CORE_COMPTROLLER = "0x687a01ecF6d3907658f7A7c714749fAC32336D1B"; + +export const USDT_PRIME_CONVERTER = "0x4f55cb0a24D5542a3478B0E284259A6B850B06BD"; +export const USDC_PRIME_CONVERTER = "0xcEB9503f10B781E30213c0b320bCf3b3cE54216E"; +export const WBTC_PRIME_CONVERTER = "0xDcCDE673Cd8988745dA384A7083B0bd22085dEA0"; +export const WETH_PRIME_CONVERTER = "0xb8fD67f215117FADeF06447Af31590309750529D"; +export const XVS_VAULT_CONVERTER = "0x1FD30e761C3296fE36D9068b1e398FD97B4C0407"; +export const BaseAssets = [ + "0xdAC17F958D2ee523a2206206994597C13D831ec7", // USDT USDTTokenConverter BaseAsset + "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48", // USDC USDCTokenConverter BaseAsset + "0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599", // WBTC WBTCTokenConverter BaseAsset + "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2", // WETH WETHTokenConverter BaseAsset + "0xd3CC9d8f3689B83c91b7B59cAB4946B063EB894A", // XVS XVSTokenConverter BaseAsset +]; +const CONVERSION_INCENTIVE = parseUnits("0.0001", 18); +const eBTCAccountantOracle = "0x077A11d634be3498b9af3EbD3d5D35A0fC3569d8"; + +export const vip068 = () => { + return makeProposal([ + { + target: ethereum.RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [ + eBTC, + [eBTCAccountantOracle, ethers.constants.AddressZero, ethers.constants.AddressZero], + [true, false, false], + ], + ], + }, + + // Add Market + { + target: eBTC, + signature: "approve(address,uint256)", + params: [ethereum.POOL_REGISTRY, 0], + }, + { + target: eBTC, + signature: "approve(address,uint256)", + params: [ethereum.POOL_REGISTRY, INITIAL_SUPPLY], + + }, + { + target: veBTC, + signature: "setReduceReservesBlockDelta(uint256)", + params: ["7200"], + + }, + { + target: ethereum.POOL_REGISTRY, + signature: "addMarket((address,uint256,uint256,uint256,address,uint256,uint256))", + params: [[veBTC, CF, LT, INITIAL_SUPPLY, ethereum.VTREASURY, SUPPLY_CAP, BORROW_CAP]], + + }, + { + target: veBTC, + signature: "setProtocolSeizeShare(uint256)", + params: [parseUnits("0.01", 18)], + + }, + + // Conversion config + { + target: USDT_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[0], [eBTC], [[CONVERSION_INCENTIVE, 1]]], + + }, + { + target: USDC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[1], [eBTC], [[CONVERSION_INCENTIVE, 1]]], + + }, + { + target: WBTC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[2], [eBTC], [[CONVERSION_INCENTIVE, 1]]], + + }, + { + target: WETH_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[3], [eBTC], [[CONVERSION_INCENTIVE, 1]]], + + }, + { + target: XVS_VAULT_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[4], [eBTC], [[CONVERSION_INCENTIVE, 1]]], + + }, + ]); +}; + +export default vip068; \ No newline at end of file diff --git a/multisig/simulations/ethereum/vip-068/abi/PoolRegistry.json b/multisig/simulations/ethereum/vip-068/abi/PoolRegistry.json new file mode 100644 index 000000000..8f15277d2 --- /dev/null +++ b/multisig/simulations/ethereum/vip-068/abi/PoolRegistry.json @@ -0,0 +1,310 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "vTokenAddress", "type": "address" } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "oldMetadata", + "type": "tuple" + }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "newMetadata", + "type": "tuple" + } + ], + "name": "PoolMetadataUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "oldName", "type": "string" }, + { "indexed": false, "internalType": "string", "name": "newName", "type": "string" } + ], + "name": "PoolNameSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPool", + "name": "pool", + "type": "tuple" + } + ], + "name": "PoolRegistered", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "collateralFactor", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThreshold", "type": "uint256" }, + { "internalType": "uint256", "name": "initialSupply", "type": "uint256" }, + { "internalType": "address", "name": "vTokenReceiver", "type": "address" }, + { "internalType": "uint256", "name": "supplyCap", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCap", "type": "uint256" } + ], + "internalType": "struct PoolRegistry.AddMarketInput", + "name": "input", + "type": "tuple" + } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "contract Comptroller", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "closeFactor", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationIncentive", "type": "uint256" }, + { "internalType": "uint256", "name": "minLiquidatableCollateral", "type": "uint256" } + ], + "name": "addPool", + "outputs": [{ "internalType": "uint256", "name": "index", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getAllPools", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool[]", + "name": "", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "comptroller", "type": "address" }], + "name": "getPoolByComptroller", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPoolsSupportedByAsset", + "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "getVTokenForAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "comptroller", "type": "address" }], + "name": "getVenusPoolMetadata", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "metadata", + "outputs": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "string", "name": "name", "type": "string" } + ], + "name": "setPoolName", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "metadata_", + "type": "tuple" + } + ], + "name": "updatePoolMetadata", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-068/abi/PrimeConverter.json b/multisig/simulations/ethereum/vip-068/abi/PrimeConverter.json new file mode 100644 index 000000000..8ea10cc8d --- /dev/null +++ b/multisig/simulations/ethereum/vip-068/abi/PrimeConverter.json @@ -0,0 +1,587 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { "inputs": [], "name": "AmountInMismatched", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, + { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, + { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, + { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, + { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, + { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, + { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, + { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, + { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, + { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, + { "inputs": [], "name": "InvalidToAddress", "type": "error" }, + { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, + { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "AssetTransferredToDestination", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } + ], + "name": "BaseAssetUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, + { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "baseAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "conversionConfigurations", + "outputs": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, + { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, + { "internalType": "address", "name": "destinationAddress_", "type": "address" }, + { "internalType": "address", "name": "baseAsset_", "type": "address" }, + { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], + "name": "setBaseAsset", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, + { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, + { + "components": [ + { "internalType": "uint256", "name": "incentive", "type": "uint256" }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-068/abi/ResilientOracle.json b/multisig/simulations/ethereum/vip-068/abi/ResilientOracle.json new file mode 100644 index 000000000..e2f944a9d --- /dev/null +++ b/multisig/simulations/ethereum/vip-068/abi/ResilientOracle.json @@ -0,0 +1,301 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "nativeMarketAddress", "type": "address" }, + { "internalType": "address", "name": "vaiAddress", "type": "address" }, + { "internalType": "contract BoundValidatorInterface", "name": "_boundValidator", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "role", "type": "uint256" }, + { "indexed": true, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "oracle", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "role", "type": "uint256" } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "mainOracle", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "pivotOracle", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "fallbackOracle", "type": "address" } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [{ "internalType": "contract BoundValidatorInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" } + ], + "name": "getOracle", + "outputs": [ + { "internalType": "address", "name": "oracle", "type": "address" }, + { "internalType": "bool", "name": "enabled", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getUnderlyingPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address", "name": "oracle", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-068/abi/comptroller.json b/multisig/simulations/ethereum/vip-068/abi/comptroller.json new file mode 100644 index 000000000..fafe7b35e --- /dev/null +++ b/multisig/simulations/ethereum/vip-068/abi/comptroller.json @@ -0,0 +1,1496 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "poolRegistry_", + "type": "address" + }, + { + "internalType": "address", + "name": "accessControl_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedLessThanOrEqualTo", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { + "inputs": [], + "name": "ComptrollerMismatch", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "collateralToSeize", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "availableCollateral", + "type": "uint256" + } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientLiquidity", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientShortfall", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidCollateralFactor", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidLiquidationThreshold", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedGreaterThan", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { + "inputs": [], + "name": "NonzeroBorrowBalance", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { + "inputs": [], + "name": "TooMuchRepay", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "expectedSender", + "type": "address" + }, + { + "internalType": "address", + "name": "actualSender", + "type": "address" + } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "bool", + "name": "pauseState", + "type": "bool" + } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newBorrowCap", + "type": "uint256" + } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldCloseFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldCollateralFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationIncentiveMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationThresholdMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMinLiquidatableCollateral", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "rewardsDistributor", + "type": "address" + } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSupplyCap", + "type": "uint256" + } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControl", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "accountAssets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "actionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract RewardsDistributor", + "name": "_rewardsDistributor", + "type": "address" + } + ], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "allMarkets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "borrowCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "checkMembership", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "vTokens", + "type": "address[]" + } + ], + "name": "enterMarkets", + "outputs": [ + { + "internalType": "uint256[]", + "name": "", + "type": "uint256[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenAddress", + "type": "address" + } + ], + "name": "exitMarket", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAssetsIn", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenModify", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [ + { + "internalType": "contract RewardsDistributor[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "rewardToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "supplySpeed", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowSpeed", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isDeprecated", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isMarketListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "components": [ + { + "internalType": "contract VToken", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokensToSeize", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "markets", + "outputs": [ + { + "internalType": "bool", + "name": "isListed", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "collateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidationThresholdMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [ + { + "internalType": "contract PriceOracle", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "skipLiquidityCheck", + "type": "bool" + } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "seizerContract", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "transferTokens", + "type": "uint256" + } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "marketsList", + "type": "address[]" + }, + { + "internalType": "enum ComptrollerStorage.Action[]", + "name": "actionsList", + "type": "uint8[]" + }, + { + "internalType": "bool", + "name": "paused", + "type": "bool" + } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newBorrowCaps", + "type": "uint256[]" + } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newSupplyCaps", + "type": "uint256[]" + } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract PriceOracle", + "name": "newOracle", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "supplyCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-068/abi/erc20.json b/multisig/simulations/ethereum/vip-068/abi/erc20.json new file mode 100644 index 000000000..3a509c9c4 --- /dev/null +++ b/multisig/simulations/ethereum/vip-068/abi/erc20.json @@ -0,0 +1,134 @@ +[ + { + "inputs": [ + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "name": "faucet", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "from", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-068/abi/vToken.json b/multisig/simulations/ethereum/vip-068/abi/vToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/multisig/simulations/ethereum/vip-068/abi/vToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-068/index.ts b/multisig/simulations/ethereum/vip-068/index.ts new file mode 100644 index 000000000..a5fea8dad --- /dev/null +++ b/multisig/simulations/ethereum/vip-068/index.ts @@ -0,0 +1,158 @@ +import { expect } from "chai"; +import { BigNumber, Contract } from "ethers"; +import { ethers } from "hardhat"; + +import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; +import vip068, { + eBTC, + veBTC, + CORE_COMPTROLLER, + USDT_PRIME_CONVERTER, + BaseAssets, + BORROW_CAP, SUPPLY_CAP +} from "../../../proposals/ethereum/vip-068"; +import { impersonateAccount, setBalance } from "@nomicfoundation/hardhat-network-helpers"; +import { parseUnits } from "ethers/lib/utils"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; +import PRIME_CONVERTER_ABI from "./abi/PrimeConverter.json"; +import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; +import COMPTROLLER_ABI from "./abi/comptroller.json"; +import ERC20_ABI from "./abi/erc20.json"; +import VTOKEN_ABI from "./abi/vToken.json"; +import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIsolatedPoolsComptrollers"; +import { checkVToken } from "src/vip-framework/checks/checkVToken"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; +const { ethereum } = NETWORK_ADDRESSES; +const PROTOCOL_SHARE_RESERVE = "0x8c8c8530464f7D95552A11eC31Adbd4dC4AC4d3E"; +const USDT_USER = "0x02EB950C215D12d723b44a18CfF098C6E166C531"; + +forking(21079955, async () => { + let resilientOracle: Contract; + let poolRegistry: Contract; + let veBTCContract: Contract; + let comptroller: Contract; + let eBTCContract: Contract; + let usdtPrimeConverter: Contract; + let usdt: Contract; + + describe("Post-VIP behavior", async () => { + before(async () => { + await impersonateAccount(ethereum.NORMAL_TIMELOCK); + await setBalance(ethereum.NORMAL_TIMELOCK, parseUnits("1000", 18)); + await impersonateAccount(USDT_USER); + await setBalance(USDT_USER, parseUnits("1000", 18)); + await impersonateAccount(USDT_PRIME_CONVERTER); + await setBalance(USDT_PRIME_CONVERTER, parseUnits("1000", 18)); + + resilientOracle = await ethers.getContractAt(RESILIENT_ORACLE_ABI, ethereum.RESILIENT_ORACLE); + poolRegistry = await ethers.getContractAt(POOL_REGISTRY_ABI, ethereum.POOL_REGISTRY); + veBTCContract = await ethers.getContractAt(VTOKEN_ABI, veBTC); + comptroller = await ethers.getContractAt(COMPTROLLER_ABI, CORE_COMPTROLLER); + eBTCContract = await ethers.getContractAt(ERC20_ABI, eBTC, await ethers.getSigner(ethereum.NORMAL_TIMELOCK)); + usdtPrimeConverter = await ethers.getContractAt(PRIME_CONVERTER_ABI, USDT_PRIME_CONVERTER); + usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); + + await pretendExecutingVip(await vip068()); + }); + + it("check price", async () => { + expect(await resilientOracle.getPrice(eBTC)).to.be.equal(parseUnits("3.0196419", 18)); + expect(await resilientOracle.getUnderlyingPrice(veBTC)).to.be.equal(parseUnits("3.0196419", 18)); + }); + + // it("should have 12 markets in core pool", async () => { + // const poolVTokens = await comptroller.getAllMarkets(); + // expect(poolVTokens).to.have.lengthOf(12); + // }); + + // it("should add veBTC to the pool", async () => { + // const registeredVToken = await poolRegistry.getVTokenForAsset(comptroller.address, eBTC); + // expect(registeredVToken).to.equal(veBTC); + // }); + + // it("check ownership", async () => { + // expect(await veBTCContract.owner()).to.equal(ethereum.GUARDIAN); + // }); + + // it("check supply", async () => { + // const expectedSupply = parseUnits("0.14471345", 8); + // expect(await veBTCContract.balanceOf(ethereum.VTREASURY)).to.equal(expectedSupply); + // }); + + // it("check borrow and supply caps", async () => { + // expect(await comptroller.borrowCaps(veBTC)).equals(BORROW_CAP); + // expect(await comptroller.supplyCaps(veBTC)).equals(SUPPLY_CAP); + // }); + + // it("should set veBTC collateral factor to 68% and Liquidation threshold to 72%", async () => { + // const market = await comptroller.markets(veBTC); + // expect(market.collateralFactorMantissa).to.equal(parseUnits("0.68", 18)); + // expect(market.liquidationThresholdMantissa).to.equal(parseUnits("0.72", 18)); + // }); + + // it("check protocol share reserve", async () => { + // expect(await veBTCContract.protocolShareReserve()).equals(PROTOCOL_SHARE_RESERVE); + // }); + + // it("check reserve factor", async () => { + // expect(await veBTCContract.reserveFactorMantissa()).equals(parseUnits("0.25", 18)); + // }); + + // it("check protocol seize share", async () => { + // expect(await veBTCContract.protocolSeizeShareMantissa()).equals(parseUnits("0.01", 18)); + // }); + + // it("check vToken", async () => { + // checkVToken(veBTC, { + // name: "Venus eBTC", + // symbol: "veBTC", + // decimals: 8, + // underlying: eBTC, + // exchangeRate: parseUnits("10000000000", 18), + // comptroller: CORE_COMPTROLLER, + // }); + // }); + + // it("check IR", async () => { + // const IR = await veBTCContract.interestRateModel(); + // checkInterestRate( + // IR, + // "veBTCContract_Core", + // { base: "0.02", multiplier: "0.15", jump: "3", kink: "0.45" }, + // BigNumber.from(2252571), + // ); + // }); + + // it("check Pool", async () => { + // await eBTCContract.faucet(parseUnits("100", 18)); + // await checkIsolatedPoolsComptrollers({ + // [CORE_COMPTROLLER]: ethereum.NORMAL_TIMELOCK, + // }); + // }); + + // it("eBTC conversion", async () => { + // const usdtAmount = parseUnits("10", 6); + // await usdt.connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)).faucet(usdtAmount); + // await usdt + // .connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)) + // .approve(usdtPrimeConverter.address, usdtAmount); + + // const eBTCAmount = parseUnits("2", 18); + // await eBTCContract.connect(await ethers.getSigner(usdtPrimeConverter.address)).faucet(eBTCAmount); + + // const usdtBalanceBefore = await usdt.balanceOf(ethereum.NORMAL_TIMELOCK); + // const eBTCBalanceBefore = await eBTCContract.balanceOf(ethereum.NORMAL_TIMELOCK); + + // await usdtPrimeConverter + // .connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)) + // .convertForExactTokens(usdtAmount, eBTCAmount, usdt.address, eBTCContract.address, ethereum.NORMAL_TIMELOCK); + + // const usdtBalanceAfter = await usdt.balanceOf(ethereum.NORMAL_TIMELOCK); + // const eBTCBalanceAfter = await eBTCContract.balanceOf(ethereum.NORMAL_TIMELOCK); + + // expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("6.999301", 6)); + // expect(eBTCBalanceAfter.sub(eBTCBalanceBefore)).to.be.equal(eBTCAmount); + // }); + }); +}); \ No newline at end of file From 5bfec2ea2fbfcd33570fe81cd987c1031d367581 Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 30 Oct 2024 22:11:04 +0400 Subject: [PATCH 084/178] fix: added vip for ethereum --- multisig/proposals/ethereum/vip-068/index.ts | 18 ++- .../simulations/ethereum/vip-068/index.ts | 108 +++++++++--------- 2 files changed, 61 insertions(+), 65 deletions(-) diff --git a/multisig/proposals/ethereum/vip-068/index.ts b/multisig/proposals/ethereum/vip-068/index.ts index c5a3b7d10..fe800981d 100644 --- a/multisig/proposals/ethereum/vip-068/index.ts +++ b/multisig/proposals/ethereum/vip-068/index.ts @@ -6,7 +6,7 @@ import { ethers } from "hardhat"; const { ethereum } = NETWORK_ADDRESSES; -export const eBTC = "0x657e8c867d8b37dcc18fa4caead9c45eb088c642"; +export const eBTC = "0x657e8C867D8B37dCC18fA4Caead9C45EB088C642"; const INITIAL_SUPPLY = parseUnits("0.14471345", 8); export const SUPPLY_CAP = parseUnits("25", 8); export const BORROW_CAP = parseUnits("12.6", 8); @@ -19,7 +19,7 @@ export const USDT_PRIME_CONVERTER = "0x4f55cb0a24D5542a3478B0E284259A6B850B06BD" export const USDC_PRIME_CONVERTER = "0xcEB9503f10B781E30213c0b320bCf3b3cE54216E"; export const WBTC_PRIME_CONVERTER = "0xDcCDE673Cd8988745dA384A7083B0bd22085dEA0"; export const WETH_PRIME_CONVERTER = "0xb8fD67f215117FADeF06447Af31590309750529D"; -export const XVS_VAULT_CONVERTER = "0x1FD30e761C3296fE36D9068b1e398FD97B4C0407"; +export const XVS_VAULT_CONVERTER = "0x1Fd30E761C3296fe36d9068b1e398Fd97b4C0407"; export const BaseAssets = [ "0xdAC17F958D2ee523a2206206994597C13D831ec7", // USDT USDTTokenConverter BaseAsset "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48", // USDC USDCTokenConverter BaseAsset @@ -45,6 +45,11 @@ export const vip068 = () => { }, // Add Market + { + target: ethereum.VTREASURY, + signature: "withdrawTreasuryToken(address,uint256,address)", + params: [eBTC, INITIAL_SUPPLY, ethereum.GUARDIAN], + }, { target: eBTC, signature: "approve(address,uint256)", @@ -54,25 +59,21 @@ export const vip068 = () => { target: eBTC, signature: "approve(address,uint256)", params: [ethereum.POOL_REGISTRY, INITIAL_SUPPLY], - }, { target: veBTC, signature: "setReduceReservesBlockDelta(uint256)", params: ["7200"], - }, { target: ethereum.POOL_REGISTRY, signature: "addMarket((address,uint256,uint256,uint256,address,uint256,uint256))", params: [[veBTC, CF, LT, INITIAL_SUPPLY, ethereum.VTREASURY, SUPPLY_CAP, BORROW_CAP]], - }, { target: veBTC, signature: "setProtocolSeizeShare(uint256)", params: [parseUnits("0.01", 18)], - }, // Conversion config @@ -80,31 +81,26 @@ export const vip068 = () => { target: USDT_PRIME_CONVERTER, signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", params: [BaseAssets[0], [eBTC], [[CONVERSION_INCENTIVE, 1]]], - }, { target: USDC_PRIME_CONVERTER, signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", params: [BaseAssets[1], [eBTC], [[CONVERSION_INCENTIVE, 1]]], - }, { target: WBTC_PRIME_CONVERTER, signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", params: [BaseAssets[2], [eBTC], [[CONVERSION_INCENTIVE, 1]]], - }, { target: WETH_PRIME_CONVERTER, signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", params: [BaseAssets[3], [eBTC], [[CONVERSION_INCENTIVE, 1]]], - }, { target: XVS_VAULT_CONVERTER, signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", params: [BaseAssets[4], [eBTC], [[CONVERSION_INCENTIVE, 1]]], - }, ]); }; diff --git a/multisig/simulations/ethereum/vip-068/index.ts b/multisig/simulations/ethereum/vip-068/index.ts index a5fea8dad..92787902f 100644 --- a/multisig/simulations/ethereum/vip-068/index.ts +++ b/multisig/simulations/ethereum/vip-068/index.ts @@ -57,72 +57,72 @@ forking(21079955, async () => { }); it("check price", async () => { - expect(await resilientOracle.getPrice(eBTC)).to.be.equal(parseUnits("3.0196419", 18)); - expect(await resilientOracle.getUnderlyingPrice(veBTC)).to.be.equal(parseUnits("3.0196419", 18)); + expect(await resilientOracle.getPrice(eBTC)).to.be.equal(parseUnits("71835.7052865100", 28)); + expect(await resilientOracle.getUnderlyingPrice(veBTC)).to.be.equal(parseUnits("71835.7052865100", 28)); }); - // it("should have 12 markets in core pool", async () => { - // const poolVTokens = await comptroller.getAllMarkets(); - // expect(poolVTokens).to.have.lengthOf(12); - // }); + it("should have 10 markets in core pool", async () => { + const poolVTokens = await comptroller.getAllMarkets(); + expect(poolVTokens).to.have.lengthOf(10); + }); - // it("should add veBTC to the pool", async () => { - // const registeredVToken = await poolRegistry.getVTokenForAsset(comptroller.address, eBTC); - // expect(registeredVToken).to.equal(veBTC); - // }); + it("should add veBTC to the pool", async () => { + const registeredVToken = await poolRegistry.getVTokenForAsset(comptroller.address, eBTC); + expect(registeredVToken).to.equal(veBTC); + }); - // it("check ownership", async () => { - // expect(await veBTCContract.owner()).to.equal(ethereum.GUARDIAN); - // }); + it("check ownership", async () => { + expect(await veBTCContract.owner()).to.equal(ethereum.GUARDIAN); + }); - // it("check supply", async () => { - // const expectedSupply = parseUnits("0.14471345", 8); - // expect(await veBTCContract.balanceOf(ethereum.VTREASURY)).to.equal(expectedSupply); - // }); + it("check supply", async () => { + const expectedSupply = parseUnits("0.14471345", 8); + expect(await veBTCContract.balanceOf(ethereum.VTREASURY)).to.equal(expectedSupply); + }); - // it("check borrow and supply caps", async () => { - // expect(await comptroller.borrowCaps(veBTC)).equals(BORROW_CAP); - // expect(await comptroller.supplyCaps(veBTC)).equals(SUPPLY_CAP); - // }); + it("check borrow and supply caps", async () => { + expect(await comptroller.borrowCaps(veBTC)).equals(BORROW_CAP); + expect(await comptroller.supplyCaps(veBTC)).equals(SUPPLY_CAP); + }); - // it("should set veBTC collateral factor to 68% and Liquidation threshold to 72%", async () => { - // const market = await comptroller.markets(veBTC); - // expect(market.collateralFactorMantissa).to.equal(parseUnits("0.68", 18)); - // expect(market.liquidationThresholdMantissa).to.equal(parseUnits("0.72", 18)); - // }); + it("should set veBTC collateral factor to 68% and Liquidation threshold to 72%", async () => { + const market = await comptroller.markets(veBTC); + expect(market.collateralFactorMantissa).to.equal(parseUnits("0.68", 18)); + expect(market.liquidationThresholdMantissa).to.equal(parseUnits("0.72", 18)); + }); - // it("check protocol share reserve", async () => { - // expect(await veBTCContract.protocolShareReserve()).equals(PROTOCOL_SHARE_RESERVE); - // }); + it("check protocol share reserve", async () => { + expect(await veBTCContract.protocolShareReserve()).equals(PROTOCOL_SHARE_RESERVE); + }); - // it("check reserve factor", async () => { - // expect(await veBTCContract.reserveFactorMantissa()).equals(parseUnits("0.25", 18)); - // }); + it("check reserve factor", async () => { + expect(await veBTCContract.reserveFactorMantissa()).equals(parseUnits("0.2", 18)); + }); - // it("check protocol seize share", async () => { - // expect(await veBTCContract.protocolSeizeShareMantissa()).equals(parseUnits("0.01", 18)); - // }); + it("check protocol seize share", async () => { + expect(await veBTCContract.protocolSeizeShareMantissa()).equals(parseUnits("0.01", 18)); + }); - // it("check vToken", async () => { - // checkVToken(veBTC, { - // name: "Venus eBTC", - // symbol: "veBTC", - // decimals: 8, - // underlying: eBTC, - // exchangeRate: parseUnits("10000000000", 18), - // comptroller: CORE_COMPTROLLER, - // }); - // }); + it("check vToken", async () => { + checkVToken(veBTC, { + name: "Venus eBTC", + symbol: "veBTC", + decimals: 8, + underlying: eBTC, + exchangeRate: parseUnits("10000000000", 8), + comptroller: CORE_COMPTROLLER, + }); + }); - // it("check IR", async () => { - // const IR = await veBTCContract.interestRateModel(); - // checkInterestRate( - // IR, - // "veBTCContract_Core", - // { base: "0.02", multiplier: "0.15", jump: "3", kink: "0.45" }, - // BigNumber.from(2252571), - // ); - // }); + it("check IR", async () => { + const IR = await veBTCContract.interestRateModel(); + checkInterestRate( + IR, + "veBTCContract_Core", + { base: "0", multiplier: "0.09", jump: "2", kink: "0.45" }, + BigNumber.from(2628000), + ); + }); // it("check Pool", async () => { // await eBTCContract.faucet(parseUnits("100", 18)); From 868df913a1e6da66a4b301977de950878c1f6c46 Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 30 Oct 2024 22:26:24 +0400 Subject: [PATCH 085/178] fix: fixed mainnet vip --- multisig/proposals/ethereum/vip-067/index.ts | 10 ++- .../simulations/ethereum/vip-067/index.ts | 64 ++++++++++--------- 2 files changed, 42 insertions(+), 32 deletions(-) diff --git a/multisig/proposals/ethereum/vip-067/index.ts b/multisig/proposals/ethereum/vip-067/index.ts index 94e49e023..fc84a1540 100644 --- a/multisig/proposals/ethereum/vip-067/index.ts +++ b/multisig/proposals/ethereum/vip-067/index.ts @@ -6,8 +6,8 @@ import { ethers } from "hardhat"; const { ethereum } = NETWORK_ADDRESSES; -export const EIGEN = "0xec53bf9167f50cdeb3ae105f56099aaab9061f83"; -const INITIAL_SUPPLY = parseUnits("0", 18); +export const EIGEN = "0xec53bF9167f50cDEB3Ae105f56099aaaB9061F83"; +const INITIAL_SUPPLY = parseUnits("500", 18); export const SUPPLY_CAP = parseUnits("3000000", 18); export const BORROW_CAP = parseUnits("1500000", 18); const CF = parseUnits("0.5", 18); @@ -51,6 +51,11 @@ export const vip067 = () => { }, // Add Market + { + target: ethereum.VTREASURY, + signature: "withdrawTreasuryToken(address,uint256,address)", + params: [EIGEN, INITIAL_SUPPLY, ethereum.GUARDIAN], + }, { target: EIGEN, signature: "approve(address,uint256)", @@ -72,7 +77,6 @@ export const vip067 = () => { target: ethereum.POOL_REGISTRY, signature: "addMarket((address,uint256,uint256,uint256,address,uint256,uint256))", params: [[vEIGEN, CF, LT, INITIAL_SUPPLY, ethereum.VTREASURY, SUPPLY_CAP, BORROW_CAP]], - }, { target: vEIGEN, diff --git a/multisig/simulations/ethereum/vip-067/index.ts b/multisig/simulations/ethereum/vip-067/index.ts index c684af2a5..3eb53a7c8 100644 --- a/multisig/simulations/ethereum/vip-067/index.ts +++ b/multisig/simulations/ethereum/vip-067/index.ts @@ -26,6 +26,7 @@ import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; const { ethereum } = NETWORK_ADDRESSES; const PROTOCOL_SHARE_RESERVE = "0x8c8c8530464f7D95552A11eC31Adbd4dC4AC4d3E"; const USDT_USER = "0x02EB950C215D12d723b44a18CfF098C6E166C531"; +const EIGEN_USER = "0x56A59D9cF7bc539ADc29537280023543C5c38A00"; forking(21079955, async () => { let resilientOracle: Contract; @@ -44,6 +45,8 @@ forking(21079955, async () => { await setBalance(USDT_USER, parseUnits("1000", 18)); await impersonateAccount(USDT_PRIME_CONVERTER); await setBalance(USDT_PRIME_CONVERTER, parseUnits("1000", 18)); + await impersonateAccount(EIGEN_USER); + await setBalance(EIGEN_USER, parseUnits("1000", 18)); resilientOracle = await ethers.getContractAt(RESILIENT_ORACLE_ABI, ethereum.RESILIENT_ORACLE); poolRegistry = await ethers.getContractAt(POOL_REGISTRY_ABI, ethereum.POOL_REGISTRY); @@ -52,7 +55,10 @@ forking(21079955, async () => { eigenContract = await ethers.getContractAt(ERC20_ABI, EIGEN, await ethers.getSigner(ethereum.NORMAL_TIMELOCK)); usdtPrimeConverter = await ethers.getContractAt(PRIME_CONVERTER_ABI, USDT_PRIME_CONVERTER); usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); - + + const eigen = await ethers.getContractAt(ERC20_ABI, EIGEN, await ethers.getSigner(EIGEN_USER)); + await eigen.transfer(ethereum.VTREASURY, parseUnits("500", 18)); + await pretendExecutingVip(await vip067()); }); @@ -61,9 +67,9 @@ forking(21079955, async () => { expect(await resilientOracle.getUnderlyingPrice(vEIGEN)).to.be.equal(parseUnits("3.0196419", 18)); }); - it("should have 12 markets in core pool", async () => { + it("should have 10 markets in core pool", async () => { const poolVTokens = await comptroller.getAllMarkets(); - expect(poolVTokens).to.have.lengthOf(12); + expect(poolVTokens).to.have.lengthOf(10); }); it("should add vEIGEN to the pool", async () => { @@ -76,7 +82,7 @@ forking(21079955, async () => { }); it("check supply", async () => { - const expectedSupply = parseUnits("0", 18); + const expectedSupply = parseUnits("500", 8); expect(await vEIGENContract.balanceOf(ethereum.VTREASURY)).to.equal(expectedSupply); }); @@ -120,39 +126,39 @@ forking(21079955, async () => { IR, "vEIGENContract_Core", { base: "0.02", multiplier: "0.15", jump: "3", kink: "0.45" }, - BigNumber.from(2252571), + BigNumber.from(2628000), ); }); - it("check Pool", async () => { - await eigenContract.faucet(parseUnits("100", 18)); - await checkIsolatedPoolsComptrollers({ - [CORE_COMPTROLLER]: ethereum.NORMAL_TIMELOCK, - }); - }); + // it("check Pool", async () => { + // await eigenContract.faucet(parseUnits("100", 18)); + // await checkIsolatedPoolsComptrollers({ + // [CORE_COMPTROLLER]: ethereum.NORMAL_TIMELOCK, + // }); + // }); - it("EIGEN conversion", async () => { - const usdtAmount = parseUnits("10", 6); - await usdt.connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)).faucet(usdtAmount); - await usdt - .connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)) - .approve(usdtPrimeConverter.address, usdtAmount); + // it("EIGEN conversion", async () => { + // const usdtAmount = parseUnits("10", 6); + // await usdt.connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)).faucet(usdtAmount); + // await usdt + // .connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)) + // .approve(usdtPrimeConverter.address, usdtAmount); - const eigenAmount = parseUnits("2", 18); - await eigenContract.connect(await ethers.getSigner(usdtPrimeConverter.address)).faucet(eigenAmount); + // const eigenAmount = parseUnits("2", 18); + // await eigenContract.connect(await ethers.getSigner(usdtPrimeConverter.address)).faucet(eigenAmount); - const usdtBalanceBefore = await usdt.balanceOf(ethereum.NORMAL_TIMELOCK); - const eigenBalanceBefore = await eigenContract.balanceOf(ethereum.NORMAL_TIMELOCK); + // const usdtBalanceBefore = await usdt.balanceOf(ethereum.NORMAL_TIMELOCK); + // const eigenBalanceBefore = await eigenContract.balanceOf(ethereum.NORMAL_TIMELOCK); - await usdtPrimeConverter - .connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)) - .convertForExactTokens(usdtAmount, eigenAmount, usdt.address, eigenContract.address, ethereum.NORMAL_TIMELOCK); + // await usdtPrimeConverter + // .connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)) + // .convertForExactTokens(usdtAmount, eigenAmount, usdt.address, eigenContract.address, ethereum.NORMAL_TIMELOCK); - const usdtBalanceAfter = await usdt.balanceOf(ethereum.NORMAL_TIMELOCK); - const eigenBalanceAfter = await eigenContract.balanceOf(ethereum.NORMAL_TIMELOCK); + // const usdtBalanceAfter = await usdt.balanceOf(ethereum.NORMAL_TIMELOCK); + // const eigenBalanceAfter = await eigenContract.balanceOf(ethereum.NORMAL_TIMELOCK); - expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("6.999301", 6)); - expect(eigenBalanceAfter.sub(eigenBalanceBefore)).to.be.equal(eigenAmount); - }); + // expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("6.999301", 6)); + // expect(eigenBalanceAfter.sub(eigenBalanceBefore)).to.be.equal(eigenAmount); + // }); }); }); From 203cad96059df7fe3dee5e44972e96af4eca9e80 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Thu, 31 Oct 2024 10:39:30 +0100 Subject: [PATCH 086/178] feat: fund the normal timelock contract with BNB to send cross-chain messages --- simulations/vip-371/abi/VtreasuryAbi.json | 83 +++++++++++++++++++++++ simulations/vip-371/bscmainnet.ts | 2 + vips/vip-371/bscmainnet.ts | 11 +++ 3 files changed, 96 insertions(+) create mode 100644 simulations/vip-371/abi/VtreasuryAbi.json diff --git a/simulations/vip-371/abi/VtreasuryAbi.json b/simulations/vip-371/abi/VtreasuryAbi.json new file mode 100644 index 000000000..df5a655ee --- /dev/null +++ b/simulations/vip-371/abi/VtreasuryAbi.json @@ -0,0 +1,83 @@ +[ + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": false, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryBEP20", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": false, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryBNB", + "type": "event" + }, + { "payable": true, "stateMutability": "payable", "type": "fallback" }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryBEP20", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryBNB", + "outputs": [], + "payable": true, + "stateMutability": "payable", + "type": "function" + } +] diff --git a/simulations/vip-371/bscmainnet.ts b/simulations/vip-371/bscmainnet.ts index 89e8b7c94..d9e7c45f3 100644 --- a/simulations/vip-371/bscmainnet.ts +++ b/simulations/vip-371/bscmainnet.ts @@ -2,6 +2,7 @@ import { expectEvents } from "../../src/utils"; import { forking, testVip } from "../../src/vip-framework"; import vip371 from "../../vips/vip-371/bscmainnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; +import TREASURY_ABI from "./abi/VTreasuryAbi.json"; forking(43428406, async () => { testVip("vip371 XVS vault permission proposal", await vip371(), { @@ -12,6 +13,7 @@ forking(43428406, async () => { ["ExecuteRemoteProposal", "StorePayload"], [3, 0], ); + await expectEvents(txResponse, [TREASURY_ABI], ["WithdrawTreasuryBNB"], [1]); }, }); }); diff --git a/vips/vip-371/bscmainnet.ts b/vips/vip-371/bscmainnet.ts index 8f9184b6f..4a9d1cf62 100644 --- a/vips/vip-371/bscmainnet.ts +++ b/vips/vip-371/bscmainnet.ts @@ -1,5 +1,10 @@ +import { parseUnits } from "ethers/lib/utils"; import { LzChainId, ProposalType } from "src/types"; import { makeProposal } from "src/utils"; +import { NORMAL_TIMELOCK } from "src/vip-framework"; + +const TREASURY = "0xF322942f644A996A617BD29c16bd7d231d9F35E9"; +export const BNB_AMOUNT = parseUnits("5", 18); export const ARBITRUM_ACM = "0xD9dD18EB0cf10CbA837677f28A8F9Bda4bc2b157"; export const OPBNBMAINNET_ACM = "0xA60Deae5344F1152426cA440fb6552eA0e3005D6"; @@ -22,6 +27,12 @@ const vip371 = () => { }; return makeProposal( [ + { + target: TREASURY, + signature: "withdrawTreasuryBNB(uint256,address)", + params: [BNB_AMOUNT, NORMAL_TIMELOCK], + value: "0", + }, { target: ARBITRUM_ACM, signature: "grantRole(bytes32,address)", From cf6895cb05fc8a03db6736868e6b71ba5020739d Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Thu, 31 Oct 2024 10:39:56 +0100 Subject: [PATCH 087/178] chore: remove unneeded ABI files --- simulations/vip-371/abi/Comptroller.json | 929 ------------------ .../vip-371/abi/ComptrollerBeacon.json | 51 - simulations/vip-371/abi/ConverterNetwork.json | 205 ---- .../vip-371/abi/DefaultProxyAdmin.json | 76 -- simulations/vip-371/abi/PoolRegistry.json | 379 ------- simulations/vip-371/abi/Prime.json | 763 -------------- .../vip-371/abi/PrimeLiquidityProvider.json | 385 -------- .../vip-371/abi/ProtocolShareReserve.json | 356 ------- .../vip-371/abi/RewardDistributor.json | 532 ---------- .../vip-371/abi/SingleTokenConverter.json | 587 ----------- .../abi/SingleTokenConverterBeacon.json | 51 - simulations/vip-371/abi/VToken.json | 861 ---------------- simulations/vip-371/abi/VTokenBeacon.json | 51 - simulations/vip-371/abi/XVSStore.json | 130 --- simulations/vip-371/abi/XVSVault.json | 787 --------------- simulations/vip-371/abi/XVSVaultProxy.json | 122 --- simulations/vip-371/abi/binanceOracle.json | 284 ------ simulations/vip-371/abi/boundValidator.json | 498 ---------- simulations/vip-371/abi/chainlinkOracle.json | 459 --------- simulations/vip-371/abi/resilientOracle.json | 640 ------------ simulations/vip-371/abi/sFrxETHOracle.json | 148 --- simulations/vip-371/abi/treasury.json | 86 -- simulations/vip-371/abi/xvs.json | 716 -------------- simulations/vip-371/abi/xvsBridge.json | 807 --------------- simulations/vip-371/abi/xvsBridgeAdmin.json | 329 ------- 25 files changed, 10232 deletions(-) delete mode 100644 simulations/vip-371/abi/Comptroller.json delete mode 100644 simulations/vip-371/abi/ComptrollerBeacon.json delete mode 100644 simulations/vip-371/abi/ConverterNetwork.json delete mode 100644 simulations/vip-371/abi/DefaultProxyAdmin.json delete mode 100644 simulations/vip-371/abi/PoolRegistry.json delete mode 100644 simulations/vip-371/abi/Prime.json delete mode 100644 simulations/vip-371/abi/PrimeLiquidityProvider.json delete mode 100644 simulations/vip-371/abi/ProtocolShareReserve.json delete mode 100644 simulations/vip-371/abi/RewardDistributor.json delete mode 100644 simulations/vip-371/abi/SingleTokenConverter.json delete mode 100644 simulations/vip-371/abi/SingleTokenConverterBeacon.json delete mode 100644 simulations/vip-371/abi/VToken.json delete mode 100644 simulations/vip-371/abi/VTokenBeacon.json delete mode 100644 simulations/vip-371/abi/XVSStore.json delete mode 100644 simulations/vip-371/abi/XVSVault.json delete mode 100644 simulations/vip-371/abi/XVSVaultProxy.json delete mode 100644 simulations/vip-371/abi/binanceOracle.json delete mode 100644 simulations/vip-371/abi/boundValidator.json delete mode 100644 simulations/vip-371/abi/chainlinkOracle.json delete mode 100644 simulations/vip-371/abi/resilientOracle.json delete mode 100644 simulations/vip-371/abi/sFrxETHOracle.json delete mode 100644 simulations/vip-371/abi/treasury.json delete mode 100644 simulations/vip-371/abi/xvs.json delete mode 100644 simulations/vip-371/abi/xvsBridge.json delete mode 100644 simulations/vip-371/abi/xvsBridgeAdmin.json diff --git a/simulations/vip-371/abi/Comptroller.json b/simulations/vip-371/abi/Comptroller.json deleted file mode 100644 index f3b2445ac..000000000 --- a/simulations/vip-371/abi/Comptroller.json +++ /dev/null @@ -1,929 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "ActionPaused", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "BorrowCapExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "CollateralExceedsThreshold", - "type": "error" - }, - { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, - { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, - { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } - ], - "name": "InsufficientCollateral", - "type": "error" - }, - { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, - { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, - { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, - { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketAlreadyListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "MarketNotCollateral", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], - "name": "MarketNotListed", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, - { "internalType": "uint256", "name": "actual", "type": "uint256" } - ], - "name": "MinimalCollateralViolated", - "type": "error" - }, - { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "PriceError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "SnapshotError", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "cap", "type": "uint256" } - ], - "name": "SupplyCapExceeded", - "type": "error" - }, - { "inputs": [], "name": "TooMuchRepay", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "expectedSender", "type": "address" }, - { "internalType": "address", "name": "actualSender", "type": "address" } - ], - "name": "UnexpectedSender", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, - { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } - ], - "name": "ActionPausedMarket", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "DelegateUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "IsForcedLiquidationEnabledUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketEntered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" } - ], - "name": "MarketExited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "MarketSupported", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } - ], - "name": "NewBorrowCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } - ], - "name": "NewCloseFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } - ], - "name": "NewCollateralFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } - ], - "name": "NewLiquidationIncentive", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "NewLiquidationThreshold", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } - ], - "name": "NewMinLiquidatableCollateral", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "oldPriceOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "contract ResilientOracleInterface", - "name": "newPriceOracle", - "type": "address" - } - ], - "name": "NewPriceOracle", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } - ], - "name": "NewRewardsDistributor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } - ], - "name": "NewSupplyCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "accountAssets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "enum Action", "name": "action", "type": "uint8" } - ], - "name": "actionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], - "name": "addRewardsDistributor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "allMarkets", - "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "approvedDelegates", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "borrowCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "contract VToken", "name": "vToken", "type": "address" } - ], - "name": "checkMembership", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "closeFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], - "name": "enterMarkets", - "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], - "name": "exitMarket", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAssetsIn", - "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getBorrowingPower", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "address", "name": "vTokenModify", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "getHypotheticalAccountLiquidity", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, - { "internalType": "uint256", "name": "shortfall", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getRewardDistributors", - "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "getRewardsByMarket", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.RewardSpeeds[]", - "name": "rewardSpeeds", - "type": "tuple[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "healAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isComptroller", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isForcedLiquidationEnabled", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "isMarketListed", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [ - { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "internalType": "struct ComptrollerStorage.LiquidationOrder[]", - "name": "orders", - "type": "tuple[]" - } - ], - "name": "liquidateAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "liquidateBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } - ], - "name": "liquidateCalculateSeizeTokens", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "liquidationIncentiveMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "bool", "name": "isListed", "type": "bool" }, - { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "minLiquidatableCollateral", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } - ], - "name": "mintVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "preBorrowHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "preLiquidateHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "preMintHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "preRedeemHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preRepayHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "seizerContract", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" } - ], - "name": "preSeizeHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "preTransferHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } - ], - "name": "repayBorrowVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seizeVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, - { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, - { "internalType": "bool", "name": "paused", "type": "bool" } - ], - "name": "setActionsPaused", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], - "name": "setCloseFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } - ], - "name": "setCollateralFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, - { "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "setForcedLiquidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], - "name": "setLiquidationIncentive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } - ], - "name": "setMarketBorrowCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } - ], - "name": "setMarketSupplyCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], - "name": "setMinLiquidatableCollateral", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "supplyCaps", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], - "name": "supportMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } - ], - "name": "transferVerify", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "delegate", "type": "address" }, - { "internalType": "bool", "name": "approved", "type": "bool" } - ], - "name": "updateDelegate", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "updatePrices", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/ComptrollerBeacon.json b/simulations/vip-371/abi/ComptrollerBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/simulations/vip-371/abi/ComptrollerBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/ConverterNetwork.json b/simulations/vip-371/abi/ConverterNetwork.json deleted file mode 100644 index 396f12a91..000000000 --- a/simulations/vip-371/abi/ConverterNetwork.json +++ /dev/null @@ -1,205 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { "inputs": [], "name": "ConverterAlreadyExists", "type": "error" }, - { "inputs": [], "name": "ConverterDoesNotExist", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "InvalidMaxLoopsLimit", - "type": "error" - }, - { "inputs": [], "name": "InvalidTokenConverterAddress", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], - "name": "ConverterAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "converter", "type": "address" }], - "name": "ConverterRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], - "name": "addTokenConverter", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "allConverters", - "outputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } - ], - "name": "findTokenConverters", - "outputs": [ - { "internalType": "address[]", "name": "converters", "type": "address[]" }, - { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "_tokenAddressOut", "type": "address" } - ], - "name": "findTokenConvertersForConverters", - "outputs": [ - { "internalType": "address[]", "name": "converters", "type": "address[]" }, - { "internalType": "uint256[]", "name": "convertersBalance", "type": "uint256[]" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getAllConverters", - "outputs": [{ "internalType": "contract IAbstractTokenConverter[]", "name": "converters", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_tokenConverter", "type": "address" }], - "name": "isTokenConverter", - "outputs": [{ "internalType": "bool", "name": "isConverter", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IAbstractTokenConverter", "name": "_tokenConverter", "type": "address" }], - "name": "removeTokenConverter", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/DefaultProxyAdmin.json b/simulations/vip-371/abi/DefaultProxyAdmin.json deleted file mode 100644 index 9801cfcc7..000000000 --- a/simulations/vip-371/abi/DefaultProxyAdmin.json +++ /dev/null @@ -1,76 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "changeProxyAdmin", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }], - "name": "getProxyImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" } - ], - "name": "upgrade", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract TransparentUpgradeableProxy", "name": "proxy", "type": "address" }, - { "internalType": "address", "name": "implementation", "type": "address" }, - { "internalType": "bytes", "name": "data", "type": "bytes" } - ], - "name": "upgradeAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/PoolRegistry.json b/simulations/vip-371/abi/PoolRegistry.json deleted file mode 100644 index 31b1e2a17..000000000 --- a/simulations/vip-371/abi/PoolRegistry.json +++ /dev/null @@ -1,379 +0,0 @@ -[ - { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, - { - "name": "Unauthorized", - "type": "error", - "inputs": [ - { "name": "sender", "type": "address", "internalType": "address" }, - { "name": "calledContract", "type": "address", "internalType": "address" }, - { "name": "methodSignature", "type": "string", "internalType": "string" } - ] - }, - { "name": "ZeroAddressNotAllowed", "type": "error", "inputs": [] }, - { - "name": "Initialized", - "type": "event", - "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], - "anonymous": false, - "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" - }, - { - "name": "MarketAdded", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "vTokenAddress", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x7772c85e68debdf74fad87834e2cc05fa763e74faf14de7096da305290651142" - }, - { - "name": "NewAccessControlManager", - "type": "event", - "inputs": [ - { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, - { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" - }, - { - "name": "OwnershipTransferStarted", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" - }, - { - "name": "OwnershipTransferred", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" - }, - { - "name": "PoolMetadataUpdated", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "oldMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - }, - { - "name": "newMetadata", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "anonymous": false, - "signature": "0x8f91f3b5d20b61744ed591c43346d4514ee5c2ffced5fc3795bb13c6f9518147" - }, - { - "name": "PoolNameSet", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "oldName", "type": "string", "indexed": false, "internalType": "string" }, - { "name": "newName", "type": "string", "indexed": false, "internalType": "string" } - ], - "anonymous": false, - "signature": "0xa01f2b0df2b143bfb23d4b696c103547a6bec8ca1f56e8e8a483611cb4e23a7e" - }, - { - "name": "PoolRegistered", - "type": "event", - "inputs": [ - { "name": "comptroller", "type": "address", "indexed": true, "internalType": "address" }, - { - "name": "pool", - "type": "tuple", - "indexed": false, - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "anonymous": false, - "signature": "0x53ec2a1d9645c4631472dabcf6d255f5f2971baa64321235b1610d91c692928e" - }, - { - "name": "acceptOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x79ba5097", - "stateMutability": "nonpayable" - }, - { - "name": "accessControlManager", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "contract IAccessControlManagerV8" - } - ], - "constant": true, - "signature": "0xb4a0bdf3", - "stateMutability": "view" - }, - { - "name": "addMarket", - "type": "function", - "inputs": [ - { - "name": "input", - "type": "tuple", - "components": [ - { "name": "vToken", "type": "address", "internalType": "contract VToken" }, - { "name": "collateralFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationThreshold", "type": "uint256", "internalType": "uint256" }, - { "name": "initialSupply", "type": "uint256", "internalType": "uint256" }, - { "name": "vTokenReceiver", "type": "address", "internalType": "address" }, - { "name": "supplyCap", "type": "uint256", "internalType": "uint256" }, - { "name": "borrowCap", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistry.AddMarketInput" - } - ], - "outputs": [], - "signature": "0x23dc8d64", - "stateMutability": "nonpayable" - }, - { - "name": "addPool", - "type": "function", - "inputs": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "comptroller", "type": "address", "internalType": "contract Comptroller" }, - { "name": "closeFactor", "type": "uint256", "internalType": "uint256" }, - { "name": "liquidationIncentive", "type": "uint256", "internalType": "uint256" }, - { "name": "minLiquidatableCollateral", "type": "uint256", "internalType": "uint256" } - ], - "outputs": [{ "name": "index", "type": "uint256", "internalType": "uint256" }], - "signature": "0xeed873c2", - "stateMutability": "nonpayable" - }, - { - "name": "getAllPools", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "tuple[]", - "value": [], - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool[]" - } - ], - "constant": true, - "signature": "0xd88ff1f4", - "stateMutability": "view" - }, - { - "name": "getPoolByComptroller", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "name", "type": "string", "internalType": "string" }, - { "name": "creator", "type": "address", "internalType": "address" }, - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "blockPosted", "type": "uint256", "internalType": "uint256" }, - { "name": "timestampPosted", "type": "uint256", "internalType": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool" - } - ], - "constant": true, - "signature": "0x7aee632d", - "stateMutability": "view" - }, - { - "name": "getPoolsSupportedByAsset", - "type": "function", - "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], - "outputs": [{ "name": "", "type": "address[]", "internalType": "address[]" }], - "constant": true, - "signature": "0xf36dba38", - "stateMutability": "view" - }, - { - "name": "getVTokenForAsset", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "asset", "type": "address", "internalType": "address" } - ], - "outputs": [{ "name": "", "type": "address", "internalType": "address" }], - "constant": true, - "signature": "0x266e0a7f", - "stateMutability": "view" - }, - { - "name": "getVenusPoolMetadata", - "type": "function", - "inputs": [{ "name": "comptroller", "type": "address", "internalType": "address" }], - "outputs": [ - { - "name": "", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "constant": true, - "signature": "0xa3aefa2c", - "stateMutability": "view" - }, - { - "name": "initialize", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xc4d66de8", - "stateMutability": "nonpayable" - }, - { - "name": "metadata", - "type": "function", - "inputs": [{ "name": "", "type": "address", "internalType": "address" }], - "outputs": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "constant": true, - "signature": "0x2ba21572", - "stateMutability": "view" - }, - { - "name": "owner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x8da5cb5b", - "stateMutability": "view" - }, - { - "name": "pendingOwner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0xe30c3978", - "stateMutability": "view" - }, - { - "name": "renounceOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x715018a6", - "stateMutability": "nonpayable" - }, - { - "name": "setAccessControlManager", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0x0e32cb86", - "stateMutability": "nonpayable" - }, - { - "name": "setPoolName", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { "name": "name", "type": "string", "internalType": "string" } - ], - "outputs": [], - "signature": "0x1cb6bb7e", - "stateMutability": "nonpayable" - }, - { - "name": "transferOwnership", - "type": "function", - "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xf2fde38b", - "stateMutability": "nonpayable" - }, - { - "name": "updatePoolMetadata", - "type": "function", - "inputs": [ - { "name": "comptroller", "type": "address", "internalType": "address" }, - { - "name": "metadata_", - "type": "tuple", - "components": [ - { "name": "category", "type": "string", "internalType": "string" }, - { "name": "logoURL", "type": "string", "internalType": "string" }, - { "name": "description", "type": "string", "internalType": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData" - } - ], - "outputs": [], - "signature": "0xff94d958", - "stateMutability": "nonpayable" - } -] diff --git a/simulations/vip-371/abi/Prime.json b/simulations/vip-371/abi/Prime.json deleted file mode 100644 index e8bfa99ff..000000000 --- a/simulations/vip-371/abi/Prime.json +++ /dev/null @@ -1,763 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_wrappedNativeToken", "type": "address" }, - { "internalType": "address", "name": "_nativeMarket", "type": "address" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" }, - { "internalType": "uint256", "name": "_stakingPeriod", "type": "uint256" }, - { "internalType": "uint256", "name": "_minimumStakedXVS", "type": "uint256" }, - { "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" }, - { "internalType": "bool", "name": "_timeBased", "type": "bool" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AssetAlreadyExists", "type": "error" }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "ExpTooLarge", "type": "error" }, - { "inputs": [], "name": "IneligibleToClaim", "type": "error" }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidAlphaArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidComptroller", "type": "error" }, - { "inputs": [], "name": "InvalidFixedPoint", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "n", "type": "uint256" }, - { "internalType": "uint256", "name": "d", "type": "uint256" } - ], - "name": "InvalidFraction", - "type": "error" - }, - { "inputs": [], "name": "InvalidLength", "type": "error" }, - { "inputs": [], "name": "InvalidLimit", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { "inputs": [], "name": "InvalidTimestamp", "type": "error" }, - { "inputs": [], "name": "InvalidVToken", "type": "error" }, - { - "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], - "name": "LnNonRealResult", - "type": "error" - }, - { "inputs": [{ "internalType": "int256", "name": "x", "type": "int256" }], "name": "LnTooLarge", "type": "error" }, - { "inputs": [], "name": "MarketAlreadyExists", "type": "error" }, - { "inputs": [], "name": "MarketNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { "inputs": [], "name": "NoScoreUpdatesRequired", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "UserHasNoPrimeToken", "type": "error" }, - { "inputs": [], "name": "WaitMoreTime", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint128", "name": "oldNumerator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "oldDenominator", "type": "uint128" }, - { "indexed": true, "internalType": "uint128", "name": "newNumerator", "type": "uint128" }, - { "indexed": false, "internalType": "uint128", "name": "newDenominator", "type": "uint128" } - ], - "name": "AlphaUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "Burn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "InterestClaimed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "MarketAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "oldIrrevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldRevocableLimit", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "newIrrevocableLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newRevocableLimit", "type": "uint256" } - ], - "name": "MintLimitsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "market", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "oldSupplyMultiplier", "type": "uint256" }, - { "indexed": true, "internalType": "uint256", "name": "oldBorrowMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSupplyMultiplier", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBorrowMultiplier", "type": "uint256" } - ], - "name": "MultiplierUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" } - ], - "name": "StakedAtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "TokenUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }], - "name": "UserScoreUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "MAXIMUM_XVS_CAP", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MINIMUM_STAKED_XVS", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_MARKET", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "STAKING_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WRAPPED_NATIVE_TOKEN", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "accrueInterest", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" } - ], - "name": "accrueInterestAndUpdateScore", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "addMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "alphaDenominator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "alphaNumerator", - "outputs": [{ "internalType": "uint128", "name": "", "type": "uint128" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "calculateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "claimInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "claimTimeRemaining", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" }, - { "internalType": "uint256", "name": "borrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supply", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsStaked", "type": "uint256" } - ], - "name": "estimateAPR", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "supplyAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowAPR", "type": "uint256" }, - { "internalType": "uint256", "name": "totalScore", "type": "uint256" }, - { "internalType": "uint256", "name": "userScore", "type": "uint256" }, - { "internalType": "uint256", "name": "xvsBalanceForScore", "type": "uint256" }, - { "internalType": "uint256", "name": "capital", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedSupply", "type": "uint256" }, - { "internalType": "uint256", "name": "cappedBorrow", "type": "uint256" }, - { "internalType": "uint256", "name": "supplyCapUSD", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCapUSD", "type": "uint256" } - ], - "internalType": "struct IPrime.APRInfo", - "name": "aprInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "user", "type": "address" } - ], - "name": "getInterestAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "getPendingRewards", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "internalType": "struct PrimeStorageV1.PendingReward[]", - "name": "pendingRewards", - "type": "tuple[]" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "incomeDistributionYearly", - "outputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "xvsVault_", "type": "address" }, - { "internalType": "address", "name": "xvsVaultRewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "xvsVaultPoolId_", "type": "uint256" }, - { "internalType": "uint128", "name": "alphaNumerator_", "type": "uint128" }, - { "internalType": "uint128", "name": "alphaDenominator_", "type": "uint128" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address", "name": "primeLiquidityProvider_", "type": "address" }, - { "internalType": "address", "name": "comptroller_", "type": "address" }, - { "internalType": "address", "name": "oracle_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], - "name": "initializeV2", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "interests", - "outputs": [ - { "internalType": "uint256", "name": "accrued", "type": "uint256" }, - { "internalType": "uint256", "name": "score", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "irrevocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "", "type": "uint256" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "isScoreUpdated", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "isUserPrimeHolder", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" }, - { "internalType": "address[]", "name": "users", "type": "address[]" } - ], - "name": "issue", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "markets", - "outputs": [ - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardIndex", "type": "uint256" }, - { "internalType": "uint256", "name": "sumOfMembersScore", "type": "uint256" }, - { "internalType": "bool", "name": "exists", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "nextScoreUpdateRoundId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingScoreUpdates", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "primeLiquidityProvider", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "revocableLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "_irrevocableLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "_revocableLimit", "type": "uint256" } - ], - "name": "setLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "users", "type": "address[]" }, - { "internalType": "uint256[]", "name": "timestamps", "type": "uint256[]" } - ], - "name": "setStakedAt", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "stakedAt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "togglePause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokens", - "outputs": [ - { "internalType": "bool", "name": "exists", "type": "bool" }, - { "internalType": "bool", "name": "isIrrevocable", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalIrrevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalRevocable", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalScoreUpdatesRequired", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "unreleasedPLPIncome", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint128", "name": "_alphaNumerator", "type": "uint128" }, - { "internalType": "uint128", "name": "_alphaDenominator", "type": "uint128" } - ], - "name": "updateAlpha", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "market", "type": "address" }, - { "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" } - ], - "name": "updateMultipliers", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "users", "type": "address[]" }], - "name": "updateScores", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "vTokenForAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], - "name": "xvsUpdated", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVault", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultPoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "xvsVaultRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/PrimeLiquidityProvider.json b/simulations/vip-371/abi/PrimeLiquidityProvider.json deleted file mode 100644 index 02ca8e0bf..000000000 --- a/simulations/vip-371/abi/PrimeLiquidityProvider.json +++ /dev/null @@ -1,385 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "_timeBased", "type": "bool" }, - { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, - { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "balance", "type": "uint256" } - ], - "name": "InsufficientBalance", - "type": "error" - }, - { "inputs": [], "name": "InvalidArguments", "type": "error" }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidCaller", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "speed", "type": "uint256" }, - { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } - ], - "name": "InvalidDistributionSpeed", - "type": "error" - }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenAlreadyInitialized", - "type": "error" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "TokenNotInitialized", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "MaxTokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } - ], - "name": "PrimeTokenUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "TokenDistributionInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "TokenDistributionSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokenTransferredToPrime", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "TokensAccrued", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "accrueTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "getEffectiveDistributionSpeed", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], - "name": "initializeTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "lastAccruedBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastAccruedBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "maxTokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "prime", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } - ], - "name": "setMaxTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], - "name": "setPrimeToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, - { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } - ], - "name": "setTokensDistributionSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, - { "internalType": "address", "name": "to_", "type": "address" }, - { "internalType": "uint256", "name": "amount_", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], - "name": "tokenAmountAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "tokenDistributionSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/ProtocolShareReserve.json b/simulations/vip-371/abi/ProtocolShareReserve.json deleted file mode 100644 index b33d7c495..000000000 --- a/simulations/vip-371/abi/ProtocolShareReserve.json +++ /dev/null @@ -1,356 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_corePoolComptroller", "type": "address" }, - { "internalType": "address", "name": "_wbnb", "type": "address" }, - { "internalType": "address", "name": "_vbnb", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTotalPercentage", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "percent", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetReleased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IProtocolShareReserve.IncomeType", - "name": "incomeType", - "type": "uint8" - }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "AssetsReservesUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "destination", "type": "address" }, - { "indexed": false, "internalType": "uint16", "name": "oldPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "uint16", "name": "newPercentage", "type": "uint16" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "DistributionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldPoolRegistry", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newPoolRegistry", "type": "address" } - ], - "name": "PoolRegistryUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "indexed": false, "internalType": "uint256", "name": "oldBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "ReservesUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "CORE_POOL_COMPTROLLER", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "MAX_PERCENT", - "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "internalType": "struct ProtocolShareReserve.DistributionConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "addOrUpdateDistributionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "", "type": "uint8" } - ], - "name": "assetsReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "distributionTargets", - "outputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "uint16", "name": "percentage", "type": "uint16" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" } - ], - "name": "getPercentageDistribution", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "getUnreleasedFunds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_loopsLimit", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address[]", "name": "assets", "type": "address[]" } - ], - "name": "releaseFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "enum ProtocolShareReserve.Schema", "name": "schema", "type": "uint8" }, - { "internalType": "address", "name": "destination", "type": "address" } - ], - "name": "removeDistributionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_poolRegistry", "type": "address" }], - "name": "setPoolRegistry", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAssetReserve", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalDistributions", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "enum IProtocolShareReserve.IncomeType", "name": "incomeType", "type": "uint8" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBNB", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/RewardDistributor.json b/simulations/vip-371/abi/RewardDistributor.json deleted file mode 100644 index 249fdd111..000000000 --- a/simulations/vip-371/abi/RewardDistributor.json +++ /dev/null @@ -1,532 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, - { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } - ], - "name": "MaxLoopsLimitExceeded", - "type": "error" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "BorrowLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "BorrowLastRewardingBlockUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "ContributorRewardTokenSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "contributor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardAccrued", "type": "uint256" } - ], - "name": "ContributorRewardsUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenBorrowIndex", "type": "uint256" } - ], - "name": "DistributedBorrowerRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "supplier", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenTotal", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardTokenSupplyIndex", "type": "uint256" } - ], - "name": "DistributedSupplierRewardToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "MarketInitialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } - ], - "name": "MaxLoopsLimitUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "indexed": false, - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "RewardTokenBorrowIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenBorrowSpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "recipient", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RewardTokenGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], - "name": "RewardTokenSupplyIndexUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } - ], - "name": "RewardTokenSupplySpeedUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "newTimestamp", "type": "uint256" } - ], - "name": "SupplyLastRewardingBlockTimestampUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, - { "indexed": false, "internalType": "uint32", "name": "newBlock", "type": "uint32" } - ], - "name": "SupplyLastRewardingBlockUpdated", - "type": "event" - }, - { - "inputs": [], - "name": "INITIAL_INDEX", - "outputs": [{ "internalType": "uint224", "name": "", "type": "uint224" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "holder", "type": "address" }, - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" } - ], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "holder", "type": "address" }], - "name": "claimRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "distributeBorrowerRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { "internalType": "address", "name": "supplier", "type": "address" } - ], - "name": "distributeSupplierRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "recipient", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "grantRewardToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract Comptroller", "name": "comptroller_", "type": "address" }, - { "internalType": "contract IERC20Upgradeable", "name": "rewardToken_", "type": "address" }, - { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "initializeMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "lastContributorBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "maxLoopsLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "rewardToken", - "outputs": [{ "internalType": "contract IERC20Upgradeable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAccrued", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenBorrowStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenBorrowerIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenContributorSpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "rewardTokenSupplierIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplySpeeds", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyState", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint32", "name": "block", "type": "uint32" }, - { "internalType": "uint32", "name": "lastRewardingBlock", "type": "uint32" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenSupplyStateTimeBased", - "outputs": [ - { "internalType": "uint224", "name": "index", "type": "uint224" }, - { "internalType": "uint256", "name": "timestamp", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardingTimestamp", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contributor", "type": "address" }, - { "internalType": "uint256", "name": "rewardTokenSpeed", "type": "uint256" } - ], - "name": "setContributorRewardTokenSpeed", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplyLastRewardingBlockTimestamps", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowLastRewardingBlockTimestamps", "type": "uint256[]" } - ], - "name": "setLastRewardingBlockTimestamps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint32[]", "name": "supplyLastRewardingBlocks", "type": "uint32[]" }, - { "internalType": "uint32[]", "name": "borrowLastRewardingBlocks", "type": "uint32[]" } - ], - "name": "setLastRewardingBlocks", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], - "name": "setMaxLoopsLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, - { "internalType": "uint256[]", "name": "supplySpeeds", "type": "uint256[]" }, - { "internalType": "uint256[]", "name": "borrowSpeeds", "type": "uint256[]" } - ], - "name": "setRewardTokenSpeeds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "contributor", "type": "address" }], - "name": "updateContributorRewards", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "vToken", "type": "address" }, - { - "components": [{ "internalType": "uint256", "name": "mantissa", "type": "uint256" }], - "internalType": "struct ExponentialNoError.Exp", - "name": "marketBorrowIndex", - "type": "tuple" - } - ], - "name": "updateRewardTokenBorrowIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "updateRewardTokenSupplyIndex", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/SingleTokenConverter.json b/simulations/vip-371/abi/SingleTokenConverter.json deleted file mode 100644 index 8ea10cc8d..000000000 --- a/simulations/vip-371/abi/SingleTokenConverter.json +++ /dev/null @@ -1,587 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } - ], - "name": "AmountInHigherThanMax", - "type": "error" - }, - { "inputs": [], "name": "AmountInMismatched", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } - ], - "name": "AmountOutLowerThanMinRequired", - "type": "error" - }, - { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, - { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, - { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, - { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, - { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, - { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } - ], - "name": "IncentiveTooHigh", - "type": "error" - }, - { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, - { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, - { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, - { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, - { "inputs": [], "name": "InvalidToAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, - { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetTransferredToDestination", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } - ], - "name": "BaseAssetUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "oldAccess", - "type": "uint8" - }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "newAccess", - "type": "uint8" - } - ], - "name": "ConversionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } - ], - "name": "ConverterNetworkAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } - ], - "name": "DestinationAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } - ], - "name": "MinAmountToConvertUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, - { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } - ], - "name": "PriceOracleUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "inputs": [], - "name": "MAX_INCENTIVE", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "baseAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "conversionConfigurations", - "outputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "conversionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "converterNetwork", - "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "destinationAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, - { "internalType": "address", "name": "destinationAddress_", "type": "address" }, - { "internalType": "address", "name": "baseAsset_", "type": "address" }, - { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "minAmountToConvert", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "priceOracle", - "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], - "name": "setBaseAsset", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig", - "name": "conversionConfig", - "type": "tuple" - } - ], - "name": "setConversionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", - "name": "conversionConfigs", - "type": "tuple[]" - } - ], - "name": "setConversionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], - "name": "setConverterNetwork", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], - "name": "setDestination", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], - "name": "setMinAmountToConvert", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/SingleTokenConverterBeacon.json b/simulations/vip-371/abi/SingleTokenConverterBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/simulations/vip-371/abi/SingleTokenConverterBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/VToken.json b/simulations/vip-371/abi/VToken.json deleted file mode 100644 index d8cc1aae4..000000000 --- a/simulations/vip-371/abi/VToken.json +++ /dev/null @@ -1,861 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], - "name": "AddReservesFactorFreshCheck", - "type": "error" - }, - { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, - { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, - { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], - "name": "LiquidateAccrueCollateralInterestFailed", - "type": "error" - }, - { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, - { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, - { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, - { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, - { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, - { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, - { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "AccrueInterest", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtRecovered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "Borrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "HealBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "LiquidateBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } - ], - "name": "NewComptroller", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "oldInterestRateModel", - "type": "address" - }, - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "newInterestRateModel", - "type": "address" - } - ], - "name": "NewMarketInterestRateModel", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } - ], - "name": "NewProtocolSeizeShare", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } - ], - "name": "NewProtocolShareReserve", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } - ], - "name": "NewReduceReservesBlockDelta", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } - ], - "name": "NewReserveFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } - ], - "name": "NewShortfallContract", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ProtocolSeize", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Redeem", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "RepayBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "ReservesAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "SpreadReservesReduced", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Transfer", - "type": "event" - }, - { - "inputs": [], - "name": "NO_ERROR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrualBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrueInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], - "name": "addReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "owner", "type": "address" }, - { "internalType": "address", "name": "spender", "type": "address" } - ], - "name": "allowance", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "approve", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "badDebt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], - "name": "badDebtRecovered", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOfUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], - "name": "borrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "borrowIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "borrowRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } - ], - "name": "decreaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "forceLiquidateBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountSnapshot", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCash", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "healBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "addedValue", "type": "uint256" } - ], - "name": "increaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "underlying_", "type": "address" }, - { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, - { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, - { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, - { "internalType": "string", "name": "name_", "type": "string" }, - { "internalType": "string", "name": "symbol_", "type": "string" }, - { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, - { "internalType": "address", "name": "admin_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { - "components": [ - { "internalType": "address", "name": "shortfall", "type": "address" }, - { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } - ], - "internalType": "struct VTokenInterface.RiskManagementInit", - "name": "riskManagement", - "type": "tuple" - }, - { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "interestRateModel", - "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isVToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } - ], - "name": "liquidateBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], - "name": "mint", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "mintBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolSeizeShareMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolShareReserve", - "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], - "name": "redeem", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], - "name": "redeemUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } - ], - "name": "redeemUnderlyingBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], - "name": "reduceReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockDelta", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], - "name": "repayBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "repayBorrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reserveFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], - "name": "setInterestRateModel", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], - "name": "setProtocolSeizeShare", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], - "name": "setProtocolShareReserve", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], - "name": "setReduceReservesBlockDelta", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], - "name": "setReserveFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], - "name": "setShortfallContract", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "shortfall", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "supplyRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrows", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrowsCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "totalReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transfer", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transferFrom", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "underlying", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/VTokenBeacon.json b/simulations/vip-371/abi/VTokenBeacon.json deleted file mode 100644 index fe7f3e52f..000000000 --- a/simulations/vip-371/abi/VTokenBeacon.json +++ /dev/null @@ -1,51 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "implementation_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], - "name": "Upgraded", - "type": "event" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/XVSStore.json b/simulations/vip-371/abi/XVSStore.json deleted file mode 100644 index 2d9ea2bb2..000000000 --- a/simulations/vip-371/abi/XVSStore.json +++ /dev/null @@ -1,130 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldAdmin", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "AdminTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } - ], - "name": "NewPendingAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnerTransferred", - "type": "event" - }, - { - "constant": false, - "inputs": [], - "name": "acceptAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "emergencyRewardWithdraw", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokens", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "token", "type": "address" }, - { "internalType": "address", "name": "_to", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "safeRewardTransfer", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_owner", "type": "address" }], - "name": "setNewOwner", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "_admin", "type": "address" }], - "name": "setPendingAdmin", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_tokenAddress", "type": "address" }, - { "internalType": "bool", "name": "status", "type": "bool" } - ], - "name": "setRewardToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/XVSVault.json b/simulations/vip-371/abi/XVSVault.json deleted file mode 100644 index 51d8d540c..000000000 --- a/simulations/vip-371/abi/XVSVault.json +++ /dev/null @@ -1,787 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Claim", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" } - ], - "name": "DelegateChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "previousBalance", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newBalance", "type": "uint256" } - ], - "name": "DelegateVotesChangedV2", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Deposit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ExecutedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, - { "indexed": true, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPrimeRewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldPrimePoolId", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPrimePoolId", "type": "uint256" } - ], - "name": "NewPrimeToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "allocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "rewardPerBlockOrSecond", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "name": "PoolAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldAllocPoints", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newAllocPoints", "type": "uint256" } - ], - "name": "PoolUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "RequestedWithdrawal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldReward", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReward", "type": "uint256" } - ], - "name": "RewardAmountUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "oldStore", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newXvs", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newStore", "type": "address" } - ], - "name": "StoreUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "userAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldOwedAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newOwedAmount", "type": "uint256" } - ], - "name": "VaultDebtUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "admin", "type": "address" }], - "name": "VaultResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "pid", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "oldPeriod", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newPeriod", "type": "uint256" } - ], - "name": "WithdrawalLockingPeriodUpdated", - "type": "event" - }, - { - "constant": true, - "inputs": [], - "name": "DELEGATION_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "DOMAIN_TYPEHASH", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "MAX_LOCK_PERIOD", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "SECONDS_PER_YEAR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "contract XVSVaultProxy", "name": "xvsVaultProxy", "type": "address" }], - "name": "_become", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV5", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" }, - { "internalType": "contract IBEP20", "name": "_token", "type": "address" }, - { "internalType": "uint256", "name": "_rewardPerBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "_lockPeriod", "type": "uint256" } - ], - "name": "add", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "blocksOrSecondsPerYear", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint32", "name": "", "type": "uint32" } - ], - "name": "checkpoints", - "outputs": [ - { "internalType": "uint32", "name": "fromBlockOrSecond", "type": "uint32" }, - { "internalType": "uint96", "name": "votes", "type": "uint96" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_account", "type": "address" }, - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "claim", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], - "name": "delegate", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "delegatee", "type": "address" }, - { "internalType": "uint256", "name": "nonce", "type": "uint256" }, - { "internalType": "uint256", "name": "expiry", "type": "uint256" }, - { "internalType": "uint8", "name": "v", "type": "uint8" }, - { "internalType": "bytes32", "name": "r", "type": "bytes32" }, - { "internalType": "bytes32", "name": "s", "type": "bytes32" } - ], - "name": "delegateBySig", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "delegates", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "deposit", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "executeWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "getBlockNumberOrTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getCurrentVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getEligibleWithdrawalAmount", - "outputs": [{ "internalType": "uint256", "name": "withdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "uint256", "name": "blockNumberOrSecond", "type": "uint256" } - ], - "name": "getPriorVotes", - "outputs": [{ "internalType": "uint96", "name": "", "type": "uint96" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getRequestedAmount", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getUserInfo", - "outputs": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint256", "name": "rewardDebt", "type": "uint256" }, - { "internalType": "uint256", "name": "pendingWithdrawals", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "getWithdrawalRequests", - "outputs": [ - { - "components": [ - { "internalType": "uint256", "name": "amount", "type": "uint256" }, - { "internalType": "uint128", "name": "lockedUntil", "type": "uint128" }, - { "internalType": "uint128", "name": "afterUpgrade", "type": "uint128" } - ], - "internalType": "struct XVSVaultStorageV1.WithdrawalRequest[]", - "name": "", - "type": "tuple[]" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "bool", "name": "timeBased_", "type": "bool" }, - { "internalType": "uint256", "name": "blocksPerYear_", "type": "uint256" } - ], - "name": "initializeTimeManager", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "isStakedToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "isTimeBased", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "nonces", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "numCheckpoints", - "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "pause", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingReward", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "pendingRewardTransfers", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "address", "name": "_user", "type": "address" } - ], - "name": "pendingWithdrawalsBeforeUpgrade", - "outputs": [{ "internalType": "uint256", "name": "beforeUpgradeWithdrawalAmount", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingXVSVaultImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "poolInfos", - "outputs": [ - { "internalType": "contract IBEP20", "name": "token", "type": "address" }, - { "internalType": "uint256", "name": "allocPoint", "type": "uint256" }, - { "internalType": "uint256", "name": "lastRewardBlockOrSecond", "type": "uint256" }, - { "internalType": "uint256", "name": "accRewardPerShare", "type": "uint256" }, - { "internalType": "uint256", "name": "lockPeriod", "type": "uint256" } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "rewardToken", "type": "address" }], - "name": "poolLength", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primePoolId", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeRewardToken", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "primeToken", - "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "requestWithdrawal", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "resume", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "_rewardToken", "type": "address" }], - "name": "rewardTokenAmountsPerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "rewardTokenAmountsPerBlockOrSecond", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_allocPoint", "type": "uint256" } - ], - "name": "set", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "newAccessControlAddress", "type": "address" }], - "name": "setAccessControl", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "contract IPrime", "name": "_primeToken", "type": "address" }, - { "internalType": "address", "name": "_primeRewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_primePoolId", "type": "uint256" } - ], - "name": "setPrimeToken", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" } - ], - "name": "setRewardAmountPerBlockOrSecond", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" }, - { "internalType": "uint256", "name": "_newPeriod", "type": "uint256" } - ], - "name": "setWithdrawalLockingPeriod", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_xvs", "type": "address" }, - { "internalType": "address", "name": "_xvsStore", "type": "address" } - ], - "name": "setXvsStore", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "totalAllocPoints", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "name": "totalPendingWithdrawals", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { "internalType": "address", "name": "_rewardToken", "type": "address" }, - { "internalType": "uint256", "name": "_pid", "type": "uint256" } - ], - "name": "updatePool", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "vaultPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "xvsStore", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/XVSVaultProxy.json b/simulations/vip-371/abi/XVSVaultProxy.json deleted file mode 100644 index 070a7fa56..000000000 --- a/simulations/vip-371/abi/XVSVaultProxy.json +++ /dev/null @@ -1,122 +0,0 @@ -[ - { "inputs": [], "payable": false, "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "error", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "info", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "detail", "type": "uint256" } - ], - "name": "Failure", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAdmin", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAdmin", "type": "address" } - ], - "name": "NewAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldImplementation", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newImplementation", "type": "address" } - ], - "name": "NewImplementation", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } - ], - "name": "NewPendingAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldPendingImplementation", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newPendingImplementation", "type": "address" } - ], - "name": "NewPendingImplementation", - "type": "event" - }, - { "payable": true, "stateMutability": "payable", "type": "fallback" }, - { - "constant": false, - "inputs": [], - "name": "_acceptAdmin", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [], - "name": "_acceptImplementation", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "newPendingAdmin", "type": "address" }], - "name": "_setPendingAdmin", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": false, - "inputs": [{ "internalType": "address", "name": "newPendingImplementation", "type": "address" }], - "name": "_setPendingImplementation", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "admin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "implementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingAdmin", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "pendingXVSVaultImplementation", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "payable": false, - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/binanceOracle.json b/simulations/vip-371/abi/binanceOracle.json deleted file mode 100644 index 513793a74..000000000 --- a/simulations/vip-371/abi/binanceOracle.json +++ /dev/null @@ -1,284 +0,0 @@ -[ - { "type": "constructor", "inputs": [], "stateMutability": "nonpayable" }, - { - "name": "Unauthorized", - "type": "error", - "inputs": [ - { "name": "sender", "type": "address", "internalType": "address" }, - { "name": "calledContract", "type": "address", "internalType": "address" }, - { "name": "methodSignature", "type": "string", "internalType": "string" } - ] - }, - { - "name": "FeedRegistryUpdated", - "type": "event", - "inputs": [ - { "name": "oldFeedRegistry", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newFeedRegistry", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x6d1006252b3dd171af76c28c184327bfddc39f439a50e0ac7f418c660b8894b5" - }, - { - "name": "Initialized", - "type": "event", - "inputs": [{ "name": "version", "type": "uint8", "indexed": false, "internalType": "uint8" }], - "anonymous": false, - "signature": "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" - }, - { - "name": "MaxStalePeriodAdded", - "type": "event", - "inputs": [ - { "name": "asset", "type": "string", "indexed": true, "internalType": "string" }, - { "name": "maxStalePeriod", "type": "uint256", "indexed": false, "internalType": "uint256" } - ], - "anonymous": false, - "signature": "0x37839d4a80c5e3f2578f59515c911ee8cce42383d7ebaa1c92afcde9871c4b58" - }, - { - "name": "NewAccessControlManager", - "type": "event", - "inputs": [ - { "name": "oldAccessControlManager", "type": "address", "indexed": false, "internalType": "address" }, - { "name": "newAccessControlManager", "type": "address", "indexed": false, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x66fd58e82f7b31a2a5c30e0888f3093efe4e111b00cd2b0c31fe014601293aa0" - }, - { - "name": "OwnershipTransferStarted", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e22700" - }, - { - "name": "OwnershipTransferred", - "type": "event", - "inputs": [ - { "name": "previousOwner", "type": "address", "indexed": true, "internalType": "address" }, - { "name": "newOwner", "type": "address", "indexed": true, "internalType": "address" } - ], - "anonymous": false, - "signature": "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0" - }, - { - "name": "SymbolOverridden", - "type": "event", - "inputs": [ - { "name": "symbol", "type": "string", "indexed": true, "internalType": "string" }, - { "name": "overriddenSymbol", "type": "string", "indexed": false, "internalType": "string" } - ], - "anonymous": false, - "signature": "0xceb1f47aa91b96f02ea70e1deed25fe154ad1885aea509bd7222f9eec0a0bda5" - }, - { - "name": "BNB_ADDR", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x3e83b6b8", - "stateMutability": "view" - }, - { - "name": "acceptOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x79ba5097", - "stateMutability": "nonpayable" - }, - { - "name": "accessControlManager", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "contract IAccessControlManagerV8" - } - ], - "constant": true, - "signature": "0xb4a0bdf3", - "stateMutability": "view" - }, - { - "name": "feedRegistryAddress", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x011d3962", - "stateMutability": "view" - }, - { - "name": "getFeedRegistryAddress", - "type": "function", - "inputs": [], - "outputs": [{ "name": "", "type": "address", "internalType": "address" }], - "constant": true, - "signature": "0x99fe040e", - "stateMutability": "view" - }, - { - "name": "getPrice", - "type": "function", - "inputs": [{ "name": "asset", "type": "address", "internalType": "address" }], - "outputs": [{ "name": "", "type": "uint256", "internalType": "uint256" }], - "constant": true, - "signature": "0x41976e09", - "stateMutability": "view" - }, - { - "name": "initialize", - "type": "function", - "inputs": [ - { "name": "_sidRegistryAddress", "type": "address", "internalType": "address" }, - { "name": "_accessControlManager", "type": "address", "internalType": "address" } - ], - "outputs": [], - "signature": "0x485cc955", - "stateMutability": "nonpayable" - }, - { - "name": "maxStalePeriod", - "type": "function", - "inputs": [{ "name": "", "type": "string", "internalType": "string" }], - "outputs": [{ "name": "", "type": "uint256", "internalType": "uint256" }], - "constant": true, - "signature": "0xfdfbc277", - "stateMutability": "view" - }, - { - "name": "owner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x8da5cb5b", - "stateMutability": "view" - }, - { - "name": "pendingOwner", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0xe30c3978", - "stateMutability": "view" - }, - { - "name": "renounceOwnership", - "type": "function", - "inputs": [], - "outputs": [], - "signature": "0x715018a6", - "stateMutability": "nonpayable" - }, - { - "name": "setAccessControlManager", - "type": "function", - "inputs": [{ "name": "accessControlManager_", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0x0e32cb86", - "stateMutability": "nonpayable" - }, - { - "name": "setFeedRegistryAddress", - "type": "function", - "inputs": [{ "name": "newfeedRegistryAddress", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0x255ce37a", - "stateMutability": "nonpayable" - }, - { - "name": "setMaxStalePeriod", - "type": "function", - "inputs": [ - { "name": "symbol", "type": "string", "internalType": "string" }, - { "name": "_maxStalePeriod", "type": "uint256", "internalType": "uint256" } - ], - "outputs": [], - "signature": "0x636b999a", - "stateMutability": "nonpayable" - }, - { - "name": "setSymbolOverride", - "type": "function", - "inputs": [ - { "name": "symbol", "type": "string", "internalType": "string" }, - { "name": "overrideSymbol", "type": "string", "internalType": "string" } - ], - "outputs": [], - "signature": "0x9eab1ad6", - "stateMutability": "nonpayable" - }, - { - "name": "sidRegistryAddress", - "type": "function", - "inputs": [], - "outputs": [ - { - "name": "", - "type": "address", - "value": "0x0000000000000000000000000000000000000000", - "internalType": "address" - } - ], - "constant": true, - "signature": "0x475e7de5", - "stateMutability": "view" - }, - { - "name": "symbols", - "type": "function", - "inputs": [{ "name": "", "type": "string", "internalType": "string" }], - "outputs": [{ "name": "", "type": "string", "internalType": "string" }], - "constant": true, - "signature": "0x047a74b2", - "stateMutability": "view" - }, - { - "name": "transferOwnership", - "type": "function", - "inputs": [{ "name": "newOwner", "type": "address", "internalType": "address" }], - "outputs": [], - "signature": "0xf2fde38b", - "stateMutability": "nonpayable" - } -] diff --git a/simulations/vip-371/abi/boundValidator.json b/simulations/vip-371/abi/boundValidator.json deleted file mode 100644 index d16c8fb08..000000000 --- a/simulations/vip-371/abi/boundValidator.json +++ /dev/null @@ -1,498 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "previousAdmin", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAdmin", - "type": "address" - } - ], - "name": "AdminChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "beacon", - "type": "address" - } - ], - "name": "BeaconUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "implementation", - "type": "address" - } - ], - "name": "Upgraded", - "type": "event" - }, - { - "stateMutability": "payable", - "type": "fallback" - }, - { - "inputs": [], - "name": "admin", - "outputs": [ - { - "internalType": "address", - "name": "admin_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "implementation", - "outputs": [ - { - "internalType": "address", - "name": "implementation_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - } - ], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - }, - { - "internalType": "bytes", - "name": "data", - "type": "bytes" - } - ], - "name": "upgradeToAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "upperBound", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "lowerBound", - "type": "uint256" - } - ], - "name": "ValidateConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig", - "name": "config", - "type": "tuple" - } - ], - "name": "setValidateConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "internalType": "struct BoundValidator.ValidateConfig[]", - "name": "configs", - "type": "tuple[]" - } - ], - "name": "setValidateConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "validateConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "upperBoundRatio", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "lowerBoundRatio", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "reportedPrice", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "anchorPrice", - "type": "uint256" - } - ], - "name": "validatePriceWithAnchorPrice", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_logic", - "type": "address" - }, - { - "internalType": "address", - "name": "admin_", - "type": "address" - }, - { - "internalType": "bytes", - "name": "_data", - "type": "bytes" - } - ], - "stateMutability": "payable", - "type": "constructor" - } -] diff --git a/simulations/vip-371/abi/chainlinkOracle.json b/simulations/vip-371/abi/chainlinkOracle.json deleted file mode 100644 index cdd689acb..000000000 --- a/simulations/vip-371/abi/chainlinkOracle.json +++ /dev/null @@ -1,459 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "vBnbAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "previousPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "requestedPriceMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newPriceMantissa", - "type": "uint256" - } - ], - "name": "PricePosted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "inputs": [], - "name": "BNB_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManager", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "prices", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - } - ], - "name": "setDirectPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "internalType": "struct TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VBep20Interface", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "underlyingPriceMantissa", - "type": "uint256" - } - ], - "name": "setUnderlyingPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "tokenConfigs", - "outputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "feed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxStalePeriod", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vBnb", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/resilientOracle.json b/simulations/vip-371/abi/resilientOracle.json deleted file mode 100644 index 35f52caa0..000000000 --- a/simulations/vip-371/abi/resilientOracle.json +++ /dev/null @@ -1,640 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "nativeMarketAddress", - "type": "address" - }, - { - "internalType": "address", - "name": "vaiAddress", - "type": "address" - }, - { - "internalType": "contract BoundValidatorInterface", - "name": "_boundValidator", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "OracleEnabled", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "role", - "type": "uint256" - } - ], - "name": "OracleSet", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "mainOracle", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "pivotOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "fallbackOracle", - "type": "address" - } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "INVALID_PRICE", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_TOKEN_ADDR", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "boundValidator", - "outputs": [ - { - "internalType": "contract BoundValidatorInterface", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - }, - { - "internalType": "bool", - "name": "enable", - "type": "bool" - } - ], - "name": "enableOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "getOracle", - "outputs": [ - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "bool", - "name": "enabled", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "getTokenConfig", - "outputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getUnderlyingPrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "nativeMarket", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address", - "name": "oracle", - "type": "address" - }, - { - "internalType": "enum ResilientOracle.OracleRole", - "name": "role", - "type": "uint8" - } - ], - "name": "setOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - }, - { - "internalType": "address[3]", - "name": "oracles", - "type": "address[3]" - }, - { - "internalType": "bool[3]", - "name": "enableFlagsForOracles", - "type": "bool[3]" - } - ], - "internalType": "struct ResilientOracle.TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "asset", - "type": "address" - } - ], - "name": "updateAssetPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "updatePrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/sFrxETHOracle.json b/simulations/vip-371/abi/sFrxETHOracle.json deleted file mode 100644 index b461549ba..000000000 --- a/simulations/vip-371/abi/sFrxETHOracle.json +++ /dev/null @@ -1,148 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "_sfrxEthFraxOracle", "type": "address" }, - { "internalType": "address", "name": "_sfrxETH", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "BadPriceData", "type": "error" }, - { "inputs": [], "name": "InvalidTokenAddress", "type": "error" }, - { "inputs": [], "name": "PriceDifferenceExceeded", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxAllowedPriceDifference", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxAllowedPriceDifference", "type": "uint256" } - ], - "name": "MaxAllowedPriceDifferenceUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [], - "name": "SFRXETH", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "SFRXETH_FRAX_ORACLE", - "outputs": [{ "internalType": "contract ISfrxEthFraxOracle", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], - "name": "getPrice", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_accessControlManager", "type": "address" }, - { "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxAllowedPriceDifference", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_maxAllowedPriceDifference", "type": "uint256" }], - "name": "setMaxAllowedPriceDifference", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/treasury.json b/simulations/vip-371/abi/treasury.json deleted file mode 100644 index 18aabb61a..000000000 --- a/simulations/vip-371/abi/treasury.json +++ /dev/null @@ -1,86 +0,0 @@ -[ - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryNative", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "WithdrawTreasuryToken", - "type": "event" - }, - { "stateMutability": "payable", "type": "fallback" }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryNative", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, - { "internalType": "address", "name": "withdrawAddress", "type": "address" } - ], - "name": "withdrawTreasuryToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "stateMutability": "payable", "type": "receive" } -] diff --git a/simulations/vip-371/abi/xvs.json b/simulations/vip-371/abi/xvs.json deleted file mode 100644 index 69092bb4a..000000000 --- a/simulations/vip-371/abi/xvs.json +++ /dev/null @@ -1,716 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user", - "type": "address" - } - ], - "name": "AccountBlacklisted", - "type": "error" - }, - { - "inputs": [], - "name": "AddressesMustDiffer", - "type": "error" - }, - { - "inputs": [], - "name": "MintLimitExceed", - "type": "error" - }, - { - "inputs": [], - "name": "MintedAmountExceed", - "type": "error" - }, - { - "inputs": [], - "name": "NewCapNotGreaterThanMintedTokens", - "type": "error" - }, - { - "inputs": [], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "user", - "type": "address" - }, - { - "indexed": false, - "internalType": "bool", - "name": "value", - "type": "bool" - } - ], - "name": "BlacklistUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "MintCapChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitDecreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLimit", - "type": "uint256" - } - ], - "name": "MintLimitIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "source", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "destination", - "type": "address" - } - ], - "name": "MintedTokensMigrated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "value", - "type": "uint256" - } - ], - "name": "Transfer", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "internalType": "address", - "name": "spender", - "type": "address" - } - ], - "name": "allowance", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "approve", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "burn", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [ - { - "internalType": "uint8", - "name": "", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "subtractedValue", - "type": "uint256" - } - ], - "name": "decreaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "spender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "addedValue", - "type": "uint256" - } - ], - "name": "increaseAllowance", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - } - ], - "name": "isBlackListed", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "source_", - "type": "address" - }, - { - "internalType": "address", - "name": "destination_", - "type": "address" - } - ], - "name": "migrateMinterTokens", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "mint", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToCap", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "minterToMintedAmount", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "paused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newAccessControlAddress_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "minter_", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount_", - "type": "uint256" - } - ], - "name": "setMintCap", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transfer", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transferFrom", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unpause", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user_", - "type": "address" - }, - { - "internalType": "bool", - "name": "value_", - "type": "bool" - } - ], - "name": "updateBlacklist", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/xvsBridge.json b/simulations/vip-371/abi/xvsBridge.json deleted file mode 100644 index 4e4dc5152..000000000 --- a/simulations/vip-371/abi/xvsBridge.json +++ /dev/null @@ -1,807 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress_", "type": "address" }, - { "internalType": "uint8", "name": "sharedDecimals_", "type": "uint8" }, - { "internalType": "address", "name": "lzEndpoint_", "type": "address" }, - { "internalType": "address", "name": "oracle_", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, - { "internalType": "uint256", "name": "balance", "type": "uint256" } - ], - "name": "InsufficientBalance", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "indexed": false, "internalType": "bytes32", "name": "_hash", "type": "bytes32" } - ], - "name": "CallOFTReceivedSuccess", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "srcChainId", "type": "uint16" }, - { "indexed": true, "internalType": "bytes", "name": "srcAddress", "type": "bytes" }, - { "indexed": false, "internalType": "uint64", "name": "nonce", "type": "uint64" } - ], - "name": "DropFailedMessage", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "innerToken", "type": "address" }], - "name": "InnerTokenAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "indexed": false, "internalType": "bytes", "name": "_payload", "type": "bytes" }, - { "indexed": false, "internalType": "bytes", "name": "_reason", "type": "bytes" } - ], - "name": "MessageFailed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "_address", "type": "address" }], - "name": "NonContractAddress", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldOracle", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOracle", "type": "address" } - ], - "name": "OracleChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "indexed": true, "internalType": "address", "name": "_to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "ReceiveFromChain", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "indexed": false, "internalType": "bytes32", "name": "_payloadHash", "type": "bytes32" } - ], - "name": "RetryMessageSuccess", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "indexed": true, "internalType": "address", "name": "_from", "type": "address" }, - { "indexed": true, "internalType": "bytes32", "name": "_toAddress", "type": "bytes32" }, - { "indexed": false, "internalType": "uint256", "name": "_amount", "type": "uint256" } - ], - "name": "SendToChain", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } - ], - "name": "SetMaxDailyLimit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } - ], - "name": "SetMaxDailyReceiveLimit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } - ], - "name": "SetMaxSingleReceiveTransactionLimit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } - ], - "name": "SetMaxSingleTransactionLimit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint16", "name": "_type", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "_minDstGas", "type": "uint256" } - ], - "name": "SetMinDstGas", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "precrime", "type": "address" }], - "name": "SetPrecrime", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_path", "type": "bytes" } - ], - "name": "SetTrustedRemote", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } - ], - "name": "SetTrustedRemoteAddress", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "addr", "type": "address" }, - { "indexed": false, "internalType": "bool", "name": "isWhitelist", "type": "bool" } - ], - "name": "SetWhitelist", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint16", "name": "chainId", "type": "uint16" }], - "name": "TrustedRemoteRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "bool", "name": "enabled", "type": "bool" }], - "name": "UpdateSendAndCallEnabled", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_PAYLOAD_SIZE_LIMIT", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NO_EXTRA_GAS", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "PT_SEND", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "PT_SEND_AND_CALL", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "internalType": "bytes32", "name": "_from", "type": "bytes32" }, - { "internalType": "address", "name": "_to", "type": "address" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" }, - { "internalType": "bytes", "name": "_payload", "type": "bytes" }, - { "internalType": "uint256", "name": "_gasForCall", "type": "uint256" } - ], - "name": "callOnOFTReceived", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourReceiveWindowStart", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourReceived", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourTransferred", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourWindowStart", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToMaxDailyLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToMaxDailyReceiveLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToMaxSingleReceiveTransactionLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToMaxSingleTransactionLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "circulatingSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "", "type": "uint16" }, - { "internalType": "bytes", "name": "", "type": "bytes" }, - { "internalType": "uint64", "name": "", "type": "uint64" } - ], - "name": "creditedPackets", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "srcAddress_", "type": "bytes" }, - { "internalType": "uint64", "name": "nonce_", "type": "uint64" } - ], - "name": "dropFailedMessage", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "internalType": "bytes32", "name": "_toAddress", "type": "bytes32" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" }, - { "internalType": "bytes", "name": "_payload", "type": "bytes" }, - { "internalType": "uint64", "name": "_dstGasForCall", "type": "uint64" }, - { "internalType": "bool", "name": "_useZro", "type": "bool" }, - { "internalType": "bytes", "name": "_adapterParams", "type": "bytes" } - ], - "name": "estimateSendAndCallFee", - "outputs": [ - { "internalType": "uint256", "name": "nativeFee", "type": "uint256" }, - { "internalType": "uint256", "name": "zroFee", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "internalType": "bytes32", "name": "_toAddress", "type": "bytes32" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" }, - { "internalType": "bool", "name": "_useZro", "type": "bool" }, - { "internalType": "bytes", "name": "_adapterParams", "type": "bytes" } - ], - "name": "estimateSendFee", - "outputs": [ - { "internalType": "uint256", "name": "nativeFee", "type": "uint256" }, - { "internalType": "uint256", "name": "zroFee", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "", "type": "uint16" }, - { "internalType": "bytes", "name": "", "type": "bytes" }, - { "internalType": "uint64", "name": "", "type": "uint64" } - ], - "name": "failedMessages", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } - ], - "name": "forceResumeReceive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_version", "type": "uint16" }, - { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "_configType", "type": "uint256" } - ], - "name": "getConfig", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }], - "name": "getTrustedRemoteAddress", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "from_", "type": "address" }, - { "internalType": "uint16", "name": "dstChainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "amount_", "type": "uint256" } - ], - "name": "isEligibleToSend", - "outputs": [ - { "internalType": "bool", "name": "eligibleToSend", "type": "bool" }, - { "internalType": "uint256", "name": "maxSingleTransactionLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "maxDailyLimit", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInUsd", "type": "uint256" }, - { "internalType": "uint256", "name": "transferredInWindow", "type": "uint256" }, - { "internalType": "uint256", "name": "last24HourWindowStart", "type": "uint256" }, - { "internalType": "bool", "name": "isWhiteListedUser", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } - ], - "name": "isTrustedRemote", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "lzEndpoint", - "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "internalType": "bytes", "name": "_payload", "type": "bytes" } - ], - "name": "lzReceive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "", "type": "uint16" }, - { "internalType": "uint16", "name": "", "type": "uint16" } - ], - "name": "minDstGasLookup", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "internalType": "bytes", "name": "_payload", "type": "bytes" } - ], - "name": "nonblockingLzReceive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "payloadSizeLimitLookup", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "precrime", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], - "name": "removeTrustedRemote", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "internalType": "bytes", "name": "_payload", "type": "bytes" } - ], - "name": "retryMessage", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "from_", "type": "address" }, - { "internalType": "uint16", "name": "dstChainId_", "type": "uint16" }, - { "internalType": "bytes32", "name": "toAddress_", "type": "bytes32" }, - { "internalType": "uint256", "name": "amount_", "type": "uint256" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "uint64", "name": "dstGasForCall_", "type": "uint64" }, - { - "components": [ - { "internalType": "address payable", "name": "refundAddress", "type": "address" }, - { "internalType": "address", "name": "zroPaymentAddress", "type": "address" }, - { "internalType": "bytes", "name": "adapterParams", "type": "bytes" } - ], - "internalType": "struct ICommonOFT.LzCallParams", - "name": "callparams_", - "type": "tuple" - } - ], - "name": "sendAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [], - "name": "sendAndCallEnabled", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "_from", "type": "address" }, - { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "internalType": "bytes32", "name": "_toAddress", "type": "bytes32" }, - { "internalType": "uint256", "name": "_amount", "type": "uint256" }, - { - "components": [ - { "internalType": "address payable", "name": "refundAddress", "type": "address" }, - { "internalType": "address", "name": "zroPaymentAddress", "type": "address" }, - { "internalType": "bytes", "name": "adapterParams", "type": "bytes" } - ], - "internalType": "struct ICommonOFT.LzCallParams", - "name": "_callParams", - "type": "tuple" - } - ], - "name": "sendFrom", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_version", "type": "uint16" }, - { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, - { "internalType": "uint256", "name": "_configType", "type": "uint256" }, - { "internalType": "bytes", "name": "_config", "type": "bytes" } - ], - "name": "setConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "limit_", "type": "uint256" } - ], - "name": "setMaxDailyLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "limit_", "type": "uint256" } - ], - "name": "setMaxDailyReceiveLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "limit_", "type": "uint256" } - ], - "name": "setMaxSingleReceiveTransactionLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "limit_", "type": "uint256" } - ], - "name": "setMaxSingleTransactionLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "internalType": "uint16", "name": "_packetType", "type": "uint16" }, - { "internalType": "uint256", "name": "_minGas", "type": "uint256" } - ], - "name": "setMinDstGas", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "oracleAddress_", "type": "address" }], - "name": "setOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "internalType": "uint256", "name": "_size", "type": "uint256" } - ], - "name": "setPayloadSizeLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_precrime", "type": "address" }], - "name": "setPrecrime", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], - "name": "setReceiveVersion", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], - "name": "setSendVersion", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_path", "type": "bytes" } - ], - "name": "setTrustedRemote", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "user_", "type": "address" }, - { "internalType": "bool", "name": "val_", "type": "bool" } - ], - "name": "setWhitelist", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "sharedDecimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], - "name": "supportsInterface", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "contract IERC20", "name": "token_", "type": "address" }, - { "internalType": "address", "name": "to_", "type": "address" }, - { "internalType": "uint256", "name": "amount_", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "token", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "trustedRemoteLookup", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "bool", "name": "enabled_", "type": "bool" }], - "name": "updateSendAndCallEnabled", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "whitelist", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-371/abi/xvsBridgeAdmin.json b/simulations/vip-371/abi/xvsBridgeAdmin.json deleted file mode 100644 index 024450a40..000000000 --- a/simulations/vip-371/abi/xvsBridgeAdmin.json +++ /dev/null @@ -1,329 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "XVSBridge_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "string", - "name": "signature", - "type": "string" - }, - { - "indexed": false, - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "name": "FunctionRegistryChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "oldAccessControlManager", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAccessControlManager", - "type": "address" - } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "stateMutability": "nonpayable", - "type": "fallback" - }, - { - "inputs": [], - "name": "XVSBridge", - "outputs": [ - { - "internalType": "contract IXVSProxyOFT", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes4", - "name": "", - "type": "bytes4" - } - ], - "name": "functionRegistry", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "isTrustedRemote", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "accessControlManager_", - "type": "address" - } - ], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint16", - "name": "remoteChainId_", - "type": "uint16" - }, - { - "internalType": "bytes", - "name": "remoteAddress_", - "type": "bytes" - } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner_", - "type": "address" - } - ], - "name": "transferBridgeOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "string[]", - "name": "signatures_", - "type": "string[]" - }, - { - "internalType": "bool[]", - "name": "active_", - "type": "bool[]" - } - ], - "name": "upsertSignature", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] From b7f0d880dc27715298826dff3a553496721f9103 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Thu, 31 Oct 2024 11:26:24 +0100 Subject: [PATCH 088/178] feat: set ID and description for the VIP 391 --- .../abi/ACMCommandsAggregator.json | 0 .../abi/AccessControlManager.json | 0 .../abi/OmnichainProposalSender.json | 0 .../abi/VtreasuryAbi.json | 0 .../{vip-371 => vip-391}/arbitrumone.ts | 4 +- .../{vip-371 => vip-391}/arbitrumsepolia.ts | 4 +- .../{vip-371 => vip-391}/bscmainnet.ts | 6 +- .../{vip-371 => vip-391}/bsctestnet.ts | 4 +- simulations/{vip-371 => vip-391}/ethereum.ts | 4 +- .../{vip-371 => vip-391}/opbnbmainnet.ts | 4 +- .../opbnbtestnet-addendum.ts | 4 +- .../{vip-371 => vip-391}/opbnbtestnet.ts | 4 +- .../{vip-371 => vip-391}/sepolia-addendum.ts | 4 +- simulations/{vip-371 => vip-391}/sepolia.ts | 4 +- vips/vip-371/bscmainnet.ts | 121 ---------- vips/vip-391/bscmainnet.ts | 208 ++++++++++++++++++ .../bsctestnet-addendum.ts | 6 +- vips/{vip-371 => vip-391}/bsctestnet.ts | 6 +- 18 files changed, 235 insertions(+), 148 deletions(-) rename simulations/{vip-371 => vip-391}/abi/ACMCommandsAggregator.json (100%) rename simulations/{vip-371 => vip-391}/abi/AccessControlManager.json (100%) rename simulations/{vip-371 => vip-391}/abi/OmnichainProposalSender.json (100%) rename simulations/{vip-371 => vip-391}/abi/VtreasuryAbi.json (100%) rename simulations/{vip-371 => vip-391}/arbitrumone.ts (93%) rename simulations/{vip-371 => vip-391}/arbitrumsepolia.ts (90%) rename simulations/{vip-371 => vip-391}/bscmainnet.ts (74%) rename simulations/{vip-371 => vip-391}/bsctestnet.ts (78%) rename simulations/{vip-371 => vip-391}/ethereum.ts (92%) rename simulations/{vip-371 => vip-391}/opbnbmainnet.ts (92%) rename simulations/{vip-371 => vip-391}/opbnbtestnet-addendum.ts (87%) rename simulations/{vip-371 => vip-391}/opbnbtestnet.ts (90%) rename simulations/{vip-371 => vip-391}/sepolia-addendum.ts (89%) rename simulations/{vip-371 => vip-391}/sepolia.ts (90%) delete mode 100644 vips/vip-371/bscmainnet.ts create mode 100644 vips/vip-391/bscmainnet.ts rename vips/{vip-371 => vip-391}/bsctestnet-addendum.ts (95%) rename vips/{vip-371 => vip-391}/bsctestnet.ts (97%) diff --git a/simulations/vip-371/abi/ACMCommandsAggregator.json b/simulations/vip-391/abi/ACMCommandsAggregator.json similarity index 100% rename from simulations/vip-371/abi/ACMCommandsAggregator.json rename to simulations/vip-391/abi/ACMCommandsAggregator.json diff --git a/simulations/vip-371/abi/AccessControlManager.json b/simulations/vip-391/abi/AccessControlManager.json similarity index 100% rename from simulations/vip-371/abi/AccessControlManager.json rename to simulations/vip-391/abi/AccessControlManager.json diff --git a/simulations/vip-371/abi/OmnichainProposalSender.json b/simulations/vip-391/abi/OmnichainProposalSender.json similarity index 100% rename from simulations/vip-371/abi/OmnichainProposalSender.json rename to simulations/vip-391/abi/OmnichainProposalSender.json diff --git a/simulations/vip-371/abi/VtreasuryAbi.json b/simulations/vip-391/abi/VtreasuryAbi.json similarity index 100% rename from simulations/vip-371/abi/VtreasuryAbi.json rename to simulations/vip-391/abi/VtreasuryAbi.json diff --git a/simulations/vip-371/arbitrumone.ts b/simulations/vip-391/arbitrumone.ts similarity index 93% rename from simulations/vip-371/arbitrumone.ts rename to simulations/vip-391/arbitrumone.ts index e1491a3b4..e30eca06a 100644 --- a/simulations/vip-371/arbitrumone.ts +++ b/simulations/vip-391/arbitrumone.ts @@ -4,7 +4,7 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip371, { ARBITRUM_ACM_AGGREGATOR, DEFAULT_ADMIN_ROLE } from "../../vips/vip-371/bscmainnet"; +import vip391, { ARBITRUM_ACM_AGGREGATOR, DEFAULT_ADMIN_ROLE } from "../../vips/vip-391/bscmainnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; @@ -14,7 +14,7 @@ const FAST_TRACK_TIMELOCK = "0x2286a9B2a5246218f2fC1F380383f45BDfCE3E04"; const CRITICAL_TIMELOCK = "0x181E4f8F21D087bF02Ea2F64D5e550849FBca674"; forking(267530159, async () => { - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { + testForkedNetworkVipCommands("VIP 391 Multichain Governance - Permissions", await vip391(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [190]); await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [52]); diff --git a/simulations/vip-371/arbitrumsepolia.ts b/simulations/vip-391/arbitrumsepolia.ts similarity index 90% rename from simulations/vip-371/arbitrumsepolia.ts rename to simulations/vip-391/arbitrumsepolia.ts index 7059d7608..54de04607 100644 --- a/simulations/vip-371/arbitrumsepolia.ts +++ b/simulations/vip-391/arbitrumsepolia.ts @@ -4,7 +4,7 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip371, { ARBITRUMSEPOLIA_ACM_AGGREGATOR, DEFAULT_ADMIN_ROLE } from "../../vips/vip-371/bsctestnet"; +import vip391, { ARBITRUMSEPOLIA_ACM_AGGREGATOR, DEFAULT_ADMIN_ROLE } from "../../vips/vip-391/bsctestnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; @@ -12,7 +12,7 @@ const { arbitrumsepolia } = NETWORK_ADDRESSES; const ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; forking(91072072, async () => { - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { + testForkedNetworkVipCommands("VIP 391 Multichain Governance - Permissions", await vip391(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [194]); await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [62]); diff --git a/simulations/vip-371/bscmainnet.ts b/simulations/vip-391/bscmainnet.ts similarity index 74% rename from simulations/vip-371/bscmainnet.ts rename to simulations/vip-391/bscmainnet.ts index d9e7c45f3..ed15ef23d 100644 --- a/simulations/vip-371/bscmainnet.ts +++ b/simulations/vip-391/bscmainnet.ts @@ -1,11 +1,11 @@ import { expectEvents } from "../../src/utils"; import { forking, testVip } from "../../src/vip-framework"; -import vip371 from "../../vips/vip-371/bscmainnet"; +import vip391 from "../../vips/vip-391/bscmainnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; -import TREASURY_ABI from "./abi/VTreasuryAbi.json"; +import TREASURY_ABI from "./abi/VtreasuryAbi.json"; forking(43428406, async () => { - testVip("vip371 XVS vault permission proposal", await vip371(), { + testVip("VIP 391 Multichain Governance - Permissions", await vip391(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-371/bsctestnet.ts b/simulations/vip-391/bsctestnet.ts similarity index 78% rename from simulations/vip-371/bsctestnet.ts rename to simulations/vip-391/bsctestnet.ts index adb8b4d09..15a9bbaf5 100644 --- a/simulations/vip-371/bsctestnet.ts +++ b/simulations/vip-391/bsctestnet.ts @@ -1,10 +1,10 @@ import { expectEvents } from "../../src/utils"; import { forking, testVip } from "../../src/vip-framework"; -import vip371 from "../../vips/vip-371/bsctestnet"; +import vip391 from "../../vips/vip-391/bsctestnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; forking(44995536, async () => { - testVip("vip371 XVS vault permission proposal", await vip371(), { + testVip("VIP 391 Multichain Governance - Permissions", await vip391(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-371/ethereum.ts b/simulations/vip-391/ethereum.ts similarity index 92% rename from simulations/vip-371/ethereum.ts rename to simulations/vip-391/ethereum.ts index f19da2827..e07381b57 100644 --- a/simulations/vip-371/ethereum.ts +++ b/simulations/vip-391/ethereum.ts @@ -4,7 +4,7 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip371, { DEFAULT_ADMIN_ROLE, ETHEREUM_ACM_AGGREGATOR } from "../../vips/vip-371/bscmainnet"; +import vip391, { DEFAULT_ADMIN_ROLE, ETHEREUM_ACM_AGGREGATOR } from "../../vips/vip-391/bscmainnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; @@ -14,7 +14,7 @@ const FAST_TRACK_TIMELOCK = "0x8764F50616B62a99A997876C2DEAaa04554C5B2E"; const CRITICAL_TIMELOCK = "0xeB9b85342c34F65af734C7bd4a149c86c472bC00"; forking(21043354, async () => { - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { + testForkedNetworkVipCommands("VIP 391 Multichain Governance - Permissions", await vip391(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [214]); await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [67]); diff --git a/simulations/vip-371/opbnbmainnet.ts b/simulations/vip-391/opbnbmainnet.ts similarity index 92% rename from simulations/vip-371/opbnbmainnet.ts rename to simulations/vip-391/opbnbmainnet.ts index 21d9b96aa..0144ab053 100644 --- a/simulations/vip-371/opbnbmainnet.ts +++ b/simulations/vip-391/opbnbmainnet.ts @@ -4,7 +4,7 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip371, { DEFAULT_ADMIN_ROLE, OPBNBMAINNET_ACM_AGGREGATOR } from "../../vips/vip-371/bscmainnet"; +import vip391, { DEFAULT_ADMIN_ROLE, OPBNBMAINNET_ACM_AGGREGATOR } from "../../vips/vip-391/bscmainnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; @@ -14,7 +14,7 @@ const FAST_TRACK_TIMELOCK = "0xEdD04Ecef0850e834833789576A1d435e7207C0d"; const CRITICAL_TIMELOCK = "0xA7DD2b15B24377296F11c702e758cd9141AB34AA"; forking(38111847, async () => { - testForkedNetworkVipCommands("vip371", await vip371(), { + testForkedNetworkVipCommands("VIP 391 Multichain Governance - Permissions", await vip391(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [140]); await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [35]); diff --git a/simulations/vip-371/opbnbtestnet-addendum.ts b/simulations/vip-391/opbnbtestnet-addendum.ts similarity index 87% rename from simulations/vip-371/opbnbtestnet-addendum.ts rename to simulations/vip-391/opbnbtestnet-addendum.ts index 628355410..016296883 100644 --- a/simulations/vip-371/opbnbtestnet-addendum.ts +++ b/simulations/vip-391/opbnbtestnet-addendum.ts @@ -4,7 +4,7 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip371, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet-addendum"; +import vip391, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-391/bsctestnet-addendum"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; @@ -13,7 +13,7 @@ const ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; const BOUND_VALIDATOR = "0x049537Bb065e6253e9D8D08B45Bf6b753657A746"; forking(43312025, async () => { - testForkedNetworkVipCommands("vip371", await vip371(), { + testForkedNetworkVipCommands("VIP 391 Multichain Governance - Permissions (addendum)", await vip391(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [1]); await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); diff --git a/simulations/vip-371/opbnbtestnet.ts b/simulations/vip-391/opbnbtestnet.ts similarity index 90% rename from simulations/vip-371/opbnbtestnet.ts rename to simulations/vip-391/opbnbtestnet.ts index c9cd967e5..8248a9338 100644 --- a/simulations/vip-371/opbnbtestnet.ts +++ b/simulations/vip-391/opbnbtestnet.ts @@ -4,7 +4,7 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip371, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet"; +import vip391, { DEFAULT_ADMIN_ROLE, OPBNBTESTNET_ACM_AGGREGATOR } from "../../vips/vip-391/bsctestnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; @@ -12,7 +12,7 @@ const { opbnbtestnet } = NETWORK_ADDRESSES; const ACM = "0x049f77F7046266d27C3bC96376f53C17Ef09c986"; forking(42828856, async () => { - testForkedNetworkVipCommands("vip371", await vip371(), { + testForkedNetworkVipCommands("VIP 391 Multichain Governance - Permissions", await vip391(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [154]); await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [48]); diff --git a/simulations/vip-371/sepolia-addendum.ts b/simulations/vip-391/sepolia-addendum.ts similarity index 89% rename from simulations/vip-371/sepolia-addendum.ts rename to simulations/vip-391/sepolia-addendum.ts index 39c742c50..96a56c376 100644 --- a/simulations/vip-371/sepolia-addendum.ts +++ b/simulations/vip-391/sepolia-addendum.ts @@ -4,7 +4,7 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip371, { DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet-addendum"; +import vip391, { DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR } from "../../vips/vip-391/bsctestnet-addendum"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; @@ -13,7 +13,7 @@ const ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; const FAST_TRACK_TIMELOCK = "0x7F043F43Adb392072a3Ba0cC9c96e894C6f7e182"; forking(6968680, async () => { - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { + testForkedNetworkVipCommands("VIP 391 Multichain Governance - Permissions (addendum)", await vip391(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [6]); await expectEvents(txResponse, [ACM_COMMANDS_AGGREGATOR_ABI], ["GrantPermissionsExecuted"], [1]); diff --git a/simulations/vip-371/sepolia.ts b/simulations/vip-391/sepolia.ts similarity index 90% rename from simulations/vip-371/sepolia.ts rename to simulations/vip-391/sepolia.ts index 850f566c4..025f84c22 100644 --- a/simulations/vip-371/sepolia.ts +++ b/simulations/vip-391/sepolia.ts @@ -4,7 +4,7 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "src/utils"; import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip371, { DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR } from "../../vips/vip-371/bsctestnet"; +import vip391, { DEFAULT_ADMIN_ROLE, SEPOLIA_ACM_AGGREGATOR } from "../../vips/vip-391/bsctestnet"; import ACM_COMMANDS_AGGREGATOR_ABI from "./abi/ACMCommandsAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager.json"; @@ -12,7 +12,7 @@ const { sepolia } = NETWORK_ADDRESSES; const ACM = "0xbf705C00578d43B6147ab4eaE04DBBEd1ccCdc96"; forking(6930723, async () => { - testForkedNetworkVipCommands("vip333 XVS Bridge permissions", await vip371(), { + testForkedNetworkVipCommands("VIP 391 Multichain Governance - Permissions", await vip391(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [223]); await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionRevoked"], [77]); diff --git a/vips/vip-371/bscmainnet.ts b/vips/vip-371/bscmainnet.ts deleted file mode 100644 index 4a9d1cf62..000000000 --- a/vips/vip-371/bscmainnet.ts +++ /dev/null @@ -1,121 +0,0 @@ -import { parseUnits } from "ethers/lib/utils"; -import { LzChainId, ProposalType } from "src/types"; -import { makeProposal } from "src/utils"; -import { NORMAL_TIMELOCK } from "src/vip-framework"; - -const TREASURY = "0xF322942f644A996A617BD29c16bd7d231d9F35E9"; -export const BNB_AMOUNT = parseUnits("5", 18); - -export const ARBITRUM_ACM = "0xD9dD18EB0cf10CbA837677f28A8F9Bda4bc2b157"; -export const OPBNBMAINNET_ACM = "0xA60Deae5344F1152426cA440fb6552eA0e3005D6"; -export const ETHEREUM_ACM = "0x230058da2D23eb8836EC5DB7037ef7250c56E25E"; - -export const ARBITRUM_ACM_AGGREGATOR = "0x74AFeA28456a683b8fF907699Ff77138edef00f3"; -export const OPBNBMAINNET_ACM_AGGREGATOR = "0x6dB5e303289fea2E83F7d442470210045592AD93"; -export const ETHEREUM_ACM_AGGREGATOR = "0xb78772bed6995551b64e54Cdb8e09800d86C73ee"; - -export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; - -const vip371 = () => { - const meta = { - version: "v2", - title: "VIP-371 grant Timelocks and revoke permissions for Guardian in Arbitrum, opBNB and Ethereum", - description: `### Description`, - forDescription: "I agree that Venus Protocol should proceed with this proposal", - againstDescription: "I do not think that Venus Protocol should proceed with this proposal", - abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", - }; - return makeProposal( - [ - { - target: TREASURY, - signature: "withdrawTreasuryBNB(uint256,address)", - params: [BNB_AMOUNT, NORMAL_TIMELOCK], - value: "0", - }, - { - target: ARBITRUM_ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, ARBITRUM_ACM_AGGREGATOR], - dstChainId: LzChainId.arbitrumone, - }, - { - target: ARBITRUM_ACM_AGGREGATOR, - signature: "executeGrantPermissions(uint256)", - params: [0], - dstChainId: LzChainId.arbitrumone, - }, - { - target: ARBITRUM_ACM_AGGREGATOR, - signature: "executeRevokePermissions(uint256)", - params: [0], - dstChainId: LzChainId.arbitrumone, - }, - { - target: ARBITRUM_ACM, - signature: "revokeRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, ARBITRUM_ACM_AGGREGATOR], - dstChainId: LzChainId.arbitrumone, - }, - - { - target: OPBNBMAINNET_ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, OPBNBMAINNET_ACM_AGGREGATOR], - dstChainId: LzChainId.opbnbmainnet, - }, - { - target: OPBNBMAINNET_ACM_AGGREGATOR, - signature: "executeGrantPermissions(uint256)", - params: [0], - dstChainId: LzChainId.opbnbmainnet, - }, - { - target: OPBNBMAINNET_ACM_AGGREGATOR, - signature: "executeRevokePermissions(uint256)", - params: [0], - dstChainId: LzChainId.opbnbmainnet, - }, - { - target: OPBNBMAINNET_ACM, - signature: "revokeRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, OPBNBMAINNET_ACM_AGGREGATOR], - dstChainId: LzChainId.opbnbmainnet, - }, - - { - target: ETHEREUM_ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, ETHEREUM_ACM_AGGREGATOR], - dstChainId: LzChainId.ethereum, - }, - { - target: ETHEREUM_ACM_AGGREGATOR, - signature: "executeGrantPermissions(uint256)", - params: [0], - dstChainId: LzChainId.ethereum, - }, - { - target: ETHEREUM_ACM_AGGREGATOR, - signature: "executeGrantPermissions(uint256)", - params: [1], - dstChainId: LzChainId.ethereum, - }, - { - target: ETHEREUM_ACM_AGGREGATOR, - signature: "executeRevokePermissions(uint256)", - params: [0], - dstChainId: LzChainId.ethereum, - }, - { - target: ETHEREUM_ACM, - signature: "revokeRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, ETHEREUM_ACM_AGGREGATOR], - dstChainId: LzChainId.ethereum, - }, - ], - meta, - ProposalType.REGULAR, - ); -}; -export default vip371; diff --git a/vips/vip-391/bscmainnet.ts b/vips/vip-391/bscmainnet.ts new file mode 100644 index 000000000..b1f20fe81 --- /dev/null +++ b/vips/vip-391/bscmainnet.ts @@ -0,0 +1,208 @@ +import { parseUnits } from "ethers/lib/utils"; +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; +import { NORMAL_TIMELOCK } from "src/vip-framework"; + +const TREASURY = "0xF322942f644A996A617BD29c16bd7d231d9F35E9"; +export const BNB_AMOUNT = parseUnits("5", 18); + +export const ARBITRUM_ACM = "0xD9dD18EB0cf10CbA837677f28A8F9Bda4bc2b157"; +export const OPBNBMAINNET_ACM = "0xA60Deae5344F1152426cA440fb6552eA0e3005D6"; +export const ETHEREUM_ACM = "0x230058da2D23eb8836EC5DB7037ef7250c56E25E"; + +export const ARBITRUM_ACM_AGGREGATOR = "0x74AFeA28456a683b8fF907699Ff77138edef00f3"; +export const OPBNBMAINNET_ACM_AGGREGATOR = "0x6dB5e303289fea2E83F7d442470210045592AD93"; +export const ETHEREUM_ACM_AGGREGATOR = "0xb78772bed6995551b64e54Cdb8e09800d86C73ee"; + +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + +const vip391 = () => { + const meta = { + version: "v2", + title: "VIP-391 Multichain Governance - Permissions on Ethereum, Arbitrum one and opBNB", + description: `#### Summary + +If passed, following the Community proposal “[Venus Upgrade - Omnichain Money Markets](https://community.venus.io/t/venus-upgrade-omnichain-money-markets/3027/9)” and [the associated snapshot](https://snapshot.org/#/venus-xvs.eth/proposal/0x62440d98cb7513d4873662203b7a27f9441880afa73105c55a733005de7ac9a1), this VIP will perform the following actions: + +- Authorise timelock contracts (Governance) on Ethereum, Arbitrum one and opBNB to execute the same privilege functions they can execute on BNB Chain +- Revoke permissions for the Guardian wallets, to execute the privilege functions that will be authorised for the timelock contracts (Governance) in the previous step +- Transfer 5 BNB from the [Venus Treasury on BNB](https://bscscan.com/address/0xf322942f644a996a617bd29c16bd7d231d9f35e9) to the [Normal Timelock](https://bscscan.com/address/0x939bD8d64c0A9583A7Dcea9933f7b21697ab6396) contract, to fund the cross-chain messages + +After executing this VIP, no more Guardian transactions will be needed to execute most of the privilege commands on Ethereum, Arbitrum one and opBNB (Guardian will be only required for contract upgrades in those networks, and that will change soon too). + +#### Details + +This VIP will update the following number of permissions: + +- Ethereum: grant 214 authorizations to Governance and revoke 67 authorizations for the Guardian wallet +- Arbitrum one: grant 190 authorizations to Governance and revoke 52 authorizations for the Guardian wallet +- opBNB: grant 140 authorizations to Governance and revoke 35 authorizations for the Guardian wallet + +The numbers of permissions granted and revoked are different because there are different contracts deployed to each network (for example, on Ethereum there are more markets and therefore more contracts). + +To apply these changes cross-chain, this VIP uses a new contract (ACMCommandsAggregator). Changes (grants and revokes) are pre-loaded in the ACMCommandsAggregator contracts and the VIP on BNB Chain only sends a message cross-chain to execute specific batches of changes. This reduces the payload sent cross-chain and therefore the gas cost of the VIP execution. + +The specific pre-loaded permissions can be checked in here: + +- Ethereum: grants ([here](https://etherscan.io/tx/0xaf04d459e828794df5749c99377541ef78b95aea3dfd6101bf0b35e42b76dd88) and [here](https://etherscan.io/tx/0x232a67df66650aeee8fa68e999725fe16e1f3c50a40ee1e75ca36add29f92ddf)) and [revokes](https://etherscan.io/tx/0xbe287e6e2ec8ab40cac11ac783a3675bbadefd1f294a95325bdbddef5319adcf) +- Arbitrum one: [grants](https://arbiscan.io/tx/0x52914e30e5e533d230cbec80d1321f515037a5d30beb07b8dccc7a8912a9e5be) and [revokes](https://arbiscan.io/tx/0x33a88d1f2764a771536a95d3718538092d22324b040db37446da8a32340be5fa) +- opBNB: [grants](https://opbnbscan.com/tx/0x15eefb0c0b4112175b971a41b051ecda2752c036f776b495514bafdffe6fc065) and [revokes](https://opbnbscan.com/tx/0xa0aae2a6fc6705f9b21a7ee9658c6bf2cdffba9c651201de42efdc3500d7be4d) + +Out of scope in this VIP (to be addressed in the future with other VIP’s): + +- Configuration of permissions for zkSync Era and Optimism. A VIP will be proposed soon to enable Multichain Governance first on these new networks, similar to VIP-330 and VIP-331 +- Ownership of the contracts. The Guardian wallets will stay as the owner of the contracts on Ethereum, Arbitrum one, opBNB (and zkSync Era and Optimism). This ownership will be transferred to Governance (specifically to the Normal Timelock contract on each network) after a period confirming everything is working as expected with Multichain VIP’s + +This VIP is a follow-up of these VIP’s: + +- [VIP-330 Enable Multichain Governance (1/2)](https://app.venus.io/#/governance/proposal/330) +- [VIP-331 Enable Multichain Governance (2/2)](https://app.venus.io/#/governance/proposal/331) + +Review these VIP’s for a detailed explanation of the Multichain Governance feature. + +#### Security and additional considerations + +We applied the following security procedures for this upgrade: + +- **Audits**: [OpenZeppelin](https://www.openzeppelin.com/), [Quantstamp](https://quantstamp.com/), [Cantina](https://cantina.xyz/) and [Certik](https://www.certik.com/) have audited the Multichain Governance contracts. Certik has audited the ACMCommandsAggregator contract. +- **VIP execution simulation**: in a simulation environment, validating the expected configuration on every network +- **Deployment on testnet**: the same contracts have been deployed to the supported testnets, and used in the Venus Protocol testnet deployment + +#### Audit reports + +- [Openzepplin audit report - 2024/01/19](https://github.com/VenusProtocol/governance-contracts/blob/feat/ven-1918/audits/084_multichainGovernance_openzeppelin_20240119.pdf) +- [Quantstamp audit report - 2024/04/29](https://github.com/VenusProtocol/governance-contracts/blob/feat/ven-1918/audits/106_multichainGovernance_quantstamp_20240429.pdf) +- [Cantina audit report - 2024/04/25](https://github.com/VenusProtocol/governance-contracts/blob/feat/ven-1918/audits/105_multichainGovernance_cantina_20240425.pdf) +- [Certik audit report - 2024/02/26](https://github.com/VenusProtocol/governance-contracts/blob/feat/ven-1918/audits/085_multichainGovernance_certik_20240226.pdf) +- [Certik audit report of ACMCommandsAggregator - 2024/10/07](https://github.com/VenusProtocol/governance-contracts/blob/3a5a2740e86c9137ab17f4f3939c97b145a22803/audits/118_ACMCommandsAggregator_certik_20241007.pdf) + +#### Deployed contracts + +Ethereum: + +- Normal Timelock: [0xd969E79406c35E80750aAae061D402Aab9325714](https://etherscan.io/address/0xd969E79406c35E80750aAae061D402Aab9325714) +- FastTrack Timelock: [0x8764F50616B62a99A997876C2DEAaa04554C5B2E](https://etherscan.io/address/0x8764F50616B62a99A997876C2DEAaa04554C5B2E) +- Critical Timelock: [0xeB9b85342c34F65af734C7bd4a149c86c472bC00](https://etherscan.io/address/0xeB9b85342c34F65af734C7bd4a149c86c472bC00) +- ACMCommandsAggregator: [0xb78772bed6995551b64e54Cdb8e09800d86C73ee](https://etherscan.io/address/0xb78772bed6995551b64e54Cdb8e09800d86C73ee) +- ACM: [0x230058da2D23eb8836EC5DB7037ef7250c56E25E](https://etherscan.io/address/0x230058da2D23eb8836EC5DB7037ef7250c56E25E) + +Arbitrum one: + +- Normal Timelock: [0x4b94589Cc23F618687790036726f744D602c4017](https://arbiscan.io/address/0x4b94589Cc23F618687790036726f744D602c4017) +- Fasttrack Timelock: [0x2286a9B2a5246218f2fC1F380383f45BDfCE3E04](https://arbiscan.io/address/0x2286a9B2a5246218f2fC1F380383f45BDfCE3E04) +- Critical Timelock: [0x181E4f8F21D087bF02Ea2F64D5e550849FBca674](https://arbiscan.io/address/0x181E4f8F21D087bF02Ea2F64D5e550849FBca674) +- ACMCommandsAggregator: [0x74AFeA28456a683b8fF907699Ff77138edef00f3](https://arbiscan.io/address/0x74AFeA28456a683b8fF907699Ff77138edef00f3) +- ACM: [0xD9dD18EB0cf10CbA837677f28A8F9Bda4bc2b157](https://arbiscan.io/address/0xD9dD18EB0cf10CbA837677f28A8F9Bda4bc2b157) + +opBNB: + +- Normal Timelock: [0x10f504e939b912569Dca611851fDAC9E3Ef86819](https://opbnbscan.com/address/0x10f504e939b912569Dca611851fDAC9E3Ef86819) +- FastTrack Timelock: [0xEdD04Ecef0850e834833789576A1d435e7207C0d](https://opbnbscan.com/address/0xEdD04Ecef0850e834833789576A1d435e7207C0d) +- Critical Timelock: [0xA7DD2b15B24377296F11c702e758cd9141AB34AA](https://opbnbscan.com/address/0xA7DD2b15B24377296F11c702e758cd9141AB34AA) +- ACMCommandsAggregator: [0x6dB5e303289fea2E83F7d442470210045592AD93](https://opbnbscan.com/address/0x6dB5e303289fea2E83F7d442470210045592AD93) +- ACM: [0xA60Deae5344F1152426cA440fb6552eA0e3005D6](https://opbnbscan.com/address/0xA60Deae5344F1152426cA440fb6552eA0e3005D6) + +#### References + +- [VIP simulation](https://github.com/VenusProtocol/vips/pull/395/) +- [Set of permissions configured on each network](https://github.com/VenusProtocol/governance-contracts/pull/90) +- [Code of Multichain Governance](https://github.com/VenusProtocol/governance-contracts/pull/21) +- [Documentation - Technical article with more details of the Multichain Governance feature](https://docs-v4.venus.io/technical-reference/reference-technical-articles/multichain-governance)`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: TREASURY, + signature: "withdrawTreasuryBNB(uint256,address)", + params: [BNB_AMOUNT, NORMAL_TIMELOCK], + value: "0", + }, + { + target: ARBITRUM_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ARBITRUM_ACM_AGGREGATOR], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ARBITRUM_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ARBITRUM_ACM_AGGREGATOR, + signature: "executeRevokePermissions(uint256)", + params: [0], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ARBITRUM_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ARBITRUM_ACM_AGGREGATOR], + dstChainId: LzChainId.arbitrumone, + }, + + { + target: OPBNBMAINNET_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPBNBMAINNET_ACM_AGGREGATOR], + dstChainId: LzChainId.opbnbmainnet, + }, + { + target: OPBNBMAINNET_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.opbnbmainnet, + }, + { + target: OPBNBMAINNET_ACM_AGGREGATOR, + signature: "executeRevokePermissions(uint256)", + params: [0], + dstChainId: LzChainId.opbnbmainnet, + }, + { + target: OPBNBMAINNET_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPBNBMAINNET_ACM_AGGREGATOR], + dstChainId: LzChainId.opbnbmainnet, + }, + + { + target: ETHEREUM_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ETHEREUM_ACM_AGGREGATOR], + dstChainId: LzChainId.ethereum, + }, + { + target: ETHEREUM_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.ethereum, + }, + { + target: ETHEREUM_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [1], + dstChainId: LzChainId.ethereum, + }, + { + target: ETHEREUM_ACM_AGGREGATOR, + signature: "executeRevokePermissions(uint256)", + params: [0], + dstChainId: LzChainId.ethereum, + }, + { + target: ETHEREUM_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ETHEREUM_ACM_AGGREGATOR], + dstChainId: LzChainId.ethereum, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip391; diff --git a/vips/vip-371/bsctestnet-addendum.ts b/vips/vip-391/bsctestnet-addendum.ts similarity index 95% rename from vips/vip-371/bsctestnet-addendum.ts rename to vips/vip-391/bsctestnet-addendum.ts index a4ddd2d26..63ec1a275 100644 --- a/vips/vip-371/bsctestnet-addendum.ts +++ b/vips/vip-391/bsctestnet-addendum.ts @@ -9,10 +9,10 @@ export const SEPOLIA_ACM_AGGREGATOR = "0x0653830c55035d678e1287b2d4550519fd263d0 export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; -const vip371 = () => { +const vip391 = () => { const meta = { version: "v2", - title: "VIP-371: Fix Sepolia and OPBNBTestnet permissions", + title: "VIP-391: Fix Sepolia and OPBNBTestnet permissions", description: `### Fix chainlink permissions for sepolia and bound validator permissions for opbnbtestnet`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", @@ -62,4 +62,4 @@ const vip371 = () => { ProposalType.REGULAR, ); }; -export default vip371; +export default vip391; diff --git a/vips/vip-371/bsctestnet.ts b/vips/vip-391/bsctestnet.ts similarity index 97% rename from vips/vip-371/bsctestnet.ts rename to vips/vip-391/bsctestnet.ts index 1097c0f20..3ec4050af 100644 --- a/vips/vip-371/bsctestnet.ts +++ b/vips/vip-391/bsctestnet.ts @@ -11,10 +11,10 @@ export const SEPOLIA_ACM_AGGREGATOR = "0x0653830c55035d678e1287b2d4550519fd263d0 export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; -const vip371 = () => { +const vip391 = () => { const meta = { version: "v2", - title: "VIP-371 grant Timelocks and revoke permissions for Guardian in Arbitrum, opBNB and Ethereum", + title: "VIP-391 grant Timelocks and revoke permissions for Guardian in Arbitrum, opBNB and Ethereum", description: `### Description`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", @@ -107,4 +107,4 @@ const vip371 = () => { ProposalType.REGULAR, ); }; -export default vip371; +export default vip391; From 45fcbede9df902973f8adb5feacc9c075e3231a0 Mon Sep 17 00:00:00 2001 From: web3rover Date: Mon, 4 Nov 2024 13:20:01 +0400 Subject: [PATCH 089/178] fix: fixed ethereum simulation --- multisig/proposals/ethereum/vip-067/index.ts | 14 +--- .../simulations/ethereum/vip-067/index.ts | 71 +++++++++---------- 2 files changed, 37 insertions(+), 48 deletions(-) diff --git a/multisig/proposals/ethereum/vip-067/index.ts b/multisig/proposals/ethereum/vip-067/index.ts index fc84a1540..1e54df982 100644 --- a/multisig/proposals/ethereum/vip-067/index.ts +++ b/multisig/proposals/ethereum/vip-067/index.ts @@ -1,8 +1,8 @@ import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { makeProposal } from "../../../../src/utils"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { ethers } from "hardhat"; const { ethereum } = NETWORK_ADDRESSES; @@ -29,7 +29,7 @@ export const BaseAssets = [ ]; const CONVERSION_INCENTIVE = parseUnits("0.0001", 18); const CHAINLINK_FEED = "0xf2917e602C2dCa458937fad715bb1E465305A4A1"; -const MAX_STALE_PERIOD = 30 * 3600; +const MAX_STALE_PERIOD = 30 * 3600; export const vip067 = () => { return makeProposal([ @@ -65,13 +65,11 @@ export const vip067 = () => { target: EIGEN, signature: "approve(address,uint256)", params: [ethereum.POOL_REGISTRY, INITIAL_SUPPLY], - }, { target: vEIGEN, signature: "setReduceReservesBlockDelta(uint256)", params: ["7200"], - }, { target: ethereum.POOL_REGISTRY, @@ -82,7 +80,6 @@ export const vip067 = () => { target: vEIGEN, signature: "setProtocolSeizeShare(uint256)", params: [parseUnits("0.01", 18)], - }, // Conversion config @@ -90,31 +87,26 @@ export const vip067 = () => { target: USDT_PRIME_CONVERTER, signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", params: [BaseAssets[0], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], - }, { target: USDC_PRIME_CONVERTER, signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", params: [BaseAssets[1], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], - }, { target: WBTC_PRIME_CONVERTER, signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", params: [BaseAssets[2], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], - }, { target: WETH_PRIME_CONVERTER, signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", params: [BaseAssets[3], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], - }, { target: XVS_VAULT_CONVERTER, signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", params: [BaseAssets[4], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], - }, ]); }; diff --git a/multisig/simulations/ethereum/vip-067/index.ts b/multisig/simulations/ethereum/vip-067/index.ts index 3eb53a7c8..37ef48461 100644 --- a/multisig/simulations/ethereum/vip-067/index.ts +++ b/multisig/simulations/ethereum/vip-067/index.ts @@ -1,31 +1,33 @@ +import { impersonateAccount, setBalance } from "@nomicfoundation/hardhat-network-helpers"; import { expect } from "chai"; import { BigNumber, Contract } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIsolatedPoolsComptrollers"; +import { checkVToken } from "src/vip-framework/checks/checkVToken"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; import vip067, { - EIGEN, - vEIGEN, + BORROW_CAP, + BaseAssets, CORE_COMPTROLLER, + EIGEN, + SUPPLY_CAP, USDT_PRIME_CONVERTER, - BaseAssets, - BORROW_CAP, SUPPLY_CAP + vEIGEN, } from "../../../proposals/ethereum/vip-067"; -import { impersonateAccount, setBalance } from "@nomicfoundation/hardhat-network-helpers"; -import { parseUnits } from "ethers/lib/utils"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; import PRIME_CONVERTER_ABI from "./abi/PrimeConverter.json"; import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; import COMPTROLLER_ABI from "./abi/comptroller.json"; import ERC20_ABI from "./abi/erc20.json"; import VTOKEN_ABI from "./abi/vToken.json"; -import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIsolatedPoolsComptrollers"; -import { checkVToken } from "src/vip-framework/checks/checkVToken"; -import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; + const { ethereum } = NETWORK_ADDRESSES; const PROTOCOL_SHARE_RESERVE = "0x8c8c8530464f7D95552A11eC31Adbd4dC4AC4d3E"; -const USDT_USER = "0x02EB950C215D12d723b44a18CfF098C6E166C531"; +const USDT_USER = "0xF977814e90dA44bFA03b6295A0616a897441aceC"; const EIGEN_USER = "0x56A59D9cF7bc539ADc29537280023543C5c38A00"; forking(21079955, async () => { @@ -56,8 +58,9 @@ forking(21079955, async () => { usdtPrimeConverter = await ethers.getContractAt(PRIME_CONVERTER_ABI, USDT_PRIME_CONVERTER); usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); - const eigen = await ethers.getContractAt(ERC20_ABI, EIGEN, await ethers.getSigner(EIGEN_USER)); - await eigen.transfer(ethereum.VTREASURY, parseUnits("500", 18)); + await eigenContract + .connect(await ethers.getSigner(EIGEN_USER)) + .transfer(ethereum.VTREASURY, parseUnits("500", 18)); await pretendExecutingVip(await vip067()); }); @@ -130,35 +133,29 @@ forking(21079955, async () => { ); }); - // it("check Pool", async () => { - // await eigenContract.faucet(parseUnits("100", 18)); - // await checkIsolatedPoolsComptrollers({ - // [CORE_COMPTROLLER]: ethereum.NORMAL_TIMELOCK, - // }); - // }); + it("check Pool", async () => { + await checkIsolatedPoolsComptrollers(); + }); - // it("EIGEN conversion", async () => { - // const usdtAmount = parseUnits("10", 6); - // await usdt.connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)).faucet(usdtAmount); - // await usdt - // .connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)) - // .approve(usdtPrimeConverter.address, usdtAmount); + it("EIGEN conversion", async () => { + const usdtAmount = parseUnits("10", 6); + await usdt.connect(await ethers.getSigner(USDT_USER)).approve(usdtPrimeConverter.address, usdtAmount); - // const eigenAmount = parseUnits("2", 18); - // await eigenContract.connect(await ethers.getSigner(usdtPrimeConverter.address)).faucet(eigenAmount); + const eigenAmount = parseUnits("2", 18); + await eigenContract.connect(await ethers.getSigner(EIGEN_USER)).transfer(usdtPrimeConverter.address, eigenAmount); - // const usdtBalanceBefore = await usdt.balanceOf(ethereum.NORMAL_TIMELOCK); - // const eigenBalanceBefore = await eigenContract.balanceOf(ethereum.NORMAL_TIMELOCK); + const usdtBalanceBefore = await usdt.balanceOf(USDT_USER); + const eigenBalanceBefore = await eigenContract.balanceOf(USDT_USER); - // await usdtPrimeConverter - // .connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)) - // .convertForExactTokens(usdtAmount, eigenAmount, usdt.address, eigenContract.address, ethereum.NORMAL_TIMELOCK); + await usdtPrimeConverter + .connect(await ethers.getSigner(USDT_USER)) + .convertForExactTokens(usdtAmount, eigenAmount, usdt.address, eigenContract.address, USDT_USER); - // const usdtBalanceAfter = await usdt.balanceOf(ethereum.NORMAL_TIMELOCK); - // const eigenBalanceAfter = await eigenContract.balanceOf(ethereum.NORMAL_TIMELOCK); + const usdtBalanceAfter = await usdt.balanceOf(USDT_USER); + const eigenBalanceAfter = await eigenContract.balanceOf(USDT_USER); - // expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("6.999301", 6)); - // expect(eigenBalanceAfter.sub(eigenBalanceBefore)).to.be.equal(eigenAmount); - // }); + expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("6.999301", 6)); + expect(eigenBalanceAfter.sub(eigenBalanceBefore)).to.be.equal(eigenAmount); + }); }); }); From 7f126f6a5972c9914ae04e590cdaf5ceaf6276e8 Mon Sep 17 00:00:00 2001 From: web3rover Date: Mon, 4 Nov 2024 13:26:58 +0400 Subject: [PATCH 090/178] fix: fixed ethereym simulation --- multisig/proposals/ethereum/vip-068/index.ts | 6 +- .../simulations/ethereum/vip-068/index.ts | 71 +++++++++---------- simulations/vip-391/bsctestnet.ts | 2 +- 3 files changed, 39 insertions(+), 40 deletions(-) diff --git a/multisig/proposals/ethereum/vip-068/index.ts b/multisig/proposals/ethereum/vip-068/index.ts index fe800981d..5cbe5ed3b 100644 --- a/multisig/proposals/ethereum/vip-068/index.ts +++ b/multisig/proposals/ethereum/vip-068/index.ts @@ -1,8 +1,8 @@ import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { makeProposal } from "../../../../src/utils"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { ethers } from "hardhat"; const { ethereum } = NETWORK_ADDRESSES; @@ -105,4 +105,4 @@ export const vip068 = () => { ]); }; -export default vip068; \ No newline at end of file +export default vip068; diff --git a/multisig/simulations/ethereum/vip-068/index.ts b/multisig/simulations/ethereum/vip-068/index.ts index 92787902f..54d51244b 100644 --- a/multisig/simulations/ethereum/vip-068/index.ts +++ b/multisig/simulations/ethereum/vip-068/index.ts @@ -1,31 +1,34 @@ +import { impersonateAccount, setBalance } from "@nomicfoundation/hardhat-network-helpers"; import { expect } from "chai"; import { BigNumber, Contract } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIsolatedPoolsComptrollers"; +import { checkVToken } from "src/vip-framework/checks/checkVToken"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; import vip068, { - eBTC, - veBTC, + BORROW_CAP, + BaseAssets, CORE_COMPTROLLER, + SUPPLY_CAP, USDT_PRIME_CONVERTER, - BaseAssets, - BORROW_CAP, SUPPLY_CAP + eBTC, + veBTC, } from "../../../proposals/ethereum/vip-068"; -import { impersonateAccount, setBalance } from "@nomicfoundation/hardhat-network-helpers"; -import { parseUnits } from "ethers/lib/utils"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; import PRIME_CONVERTER_ABI from "./abi/PrimeConverter.json"; import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; import COMPTROLLER_ABI from "./abi/comptroller.json"; import ERC20_ABI from "./abi/erc20.json"; import VTOKEN_ABI from "./abi/vToken.json"; -import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIsolatedPoolsComptrollers"; -import { checkVToken } from "src/vip-framework/checks/checkVToken"; -import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; + const { ethereum } = NETWORK_ADDRESSES; const PROTOCOL_SHARE_RESERVE = "0x8c8c8530464f7D95552A11eC31Adbd4dC4AC4d3E"; -const USDT_USER = "0x02EB950C215D12d723b44a18CfF098C6E166C531"; +const USDT_USER = "0xF977814e90dA44bFA03b6295A0616a897441aceC"; +const eBTC_USER = "0x7aCDF2012aAC69D70B86677FE91eb66e08961880"; forking(21079955, async () => { let resilientOracle: Contract; @@ -42,6 +45,8 @@ forking(21079955, async () => { await setBalance(ethereum.NORMAL_TIMELOCK, parseUnits("1000", 18)); await impersonateAccount(USDT_USER); await setBalance(USDT_USER, parseUnits("1000", 18)); + await impersonateAccount(eBTC_USER); + await setBalance(eBTC_USER, parseUnits("1000", 18)); await impersonateAccount(USDT_PRIME_CONVERTER); await setBalance(USDT_PRIME_CONVERTER, parseUnits("1000", 18)); @@ -124,35 +129,29 @@ forking(21079955, async () => { ); }); - // it("check Pool", async () => { - // await eBTCContract.faucet(parseUnits("100", 18)); - // await checkIsolatedPoolsComptrollers({ - // [CORE_COMPTROLLER]: ethereum.NORMAL_TIMELOCK, - // }); - // }); + it("check Pool", async () => { + await checkIsolatedPoolsComptrollers(); + }); - // it("eBTC conversion", async () => { - // const usdtAmount = parseUnits("10", 6); - // await usdt.connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)).faucet(usdtAmount); - // await usdt - // .connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)) - // .approve(usdtPrimeConverter.address, usdtAmount); + it("eBTC conversion", async () => { + const usdtAmount = parseUnits("10000", 6); + await usdt.connect(await ethers.getSigner(USDT_USER)).approve(usdtPrimeConverter.address, usdtAmount); - // const eBTCAmount = parseUnits("2", 18); - // await eBTCContract.connect(await ethers.getSigner(usdtPrimeConverter.address)).faucet(eBTCAmount); + const eBTCAmount = parseUnits("0.1", 8); + await eBTCContract.connect(await ethers.getSigner(eBTC_USER)).transfer(usdtPrimeConverter.address, eBTCAmount); - // const usdtBalanceBefore = await usdt.balanceOf(ethereum.NORMAL_TIMELOCK); - // const eBTCBalanceBefore = await eBTCContract.balanceOf(ethereum.NORMAL_TIMELOCK); + const usdtBalanceBefore = await usdt.balanceOf(USDT_USER); + const eigenBalanceBefore = await eBTCContract.balanceOf(USDT_USER); - // await usdtPrimeConverter - // .connect(await ethers.getSigner(ethereum.NORMAL_TIMELOCK)) - // .convertForExactTokens(usdtAmount, eBTCAmount, usdt.address, eBTCContract.address, ethereum.NORMAL_TIMELOCK); + await usdtPrimeConverter + .connect(await ethers.getSigner(USDT_USER)) + .convertForExactTokens(usdtAmount, eBTCAmount, usdt.address, eBTCContract.address, USDT_USER); - // const usdtBalanceAfter = await usdt.balanceOf(ethereum.NORMAL_TIMELOCK); - // const eBTCBalanceAfter = await eBTCContract.balanceOf(ethereum.NORMAL_TIMELOCK); + const usdtBalanceAfter = await usdt.balanceOf(USDT_USER); + const eigenBalanceAfter = await eBTCContract.balanceOf(USDT_USER); - // expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("6.999301", 6)); - // expect(eBTCBalanceAfter.sub(eBTCBalanceBefore)).to.be.equal(eBTCAmount); - // }); + expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("7186.148530", 6)); + expect(eigenBalanceAfter.sub(eigenBalanceBefore)).to.be.equal(eBTCAmount); + }); }); -}); \ No newline at end of file +}); diff --git a/simulations/vip-391/bsctestnet.ts b/simulations/vip-391/bsctestnet.ts index 69d103678..b5b44e2b8 100644 --- a/simulations/vip-391/bsctestnet.ts +++ b/simulations/vip-391/bsctestnet.ts @@ -14,4 +14,4 @@ forking(45194889, async () => { ); }, }); -}); \ No newline at end of file +}); From 76eb9b44b1a2f54bb8f7c538902a74785feb996d Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Mon, 4 Nov 2024 19:11:38 +0530 Subject: [PATCH 091/178] feat: add vip to add USDC market on zksyncsepolia --- .../proposals/zksyncsepolia/vip-012/index.ts | 73 + .../vip-012/abi/comptroller.json | 1496 ++++++++++++ .../zksyncsepolia/vip-012/abi/erc20.json | 295 +++ .../zksyncsepolia/vip-012/abi/rateModel.json | 118 + .../zksyncsepolia/vip-012/abi/vToken.json | 2066 +++++++++++++++++ .../zksyncsepolia/vip-012/index.ts | 113 + 6 files changed, 4161 insertions(+) create mode 100644 multisig/proposals/zksyncsepolia/vip-012/index.ts create mode 100644 multisig/simulations/zksyncsepolia/vip-012/abi/comptroller.json create mode 100644 multisig/simulations/zksyncsepolia/vip-012/abi/erc20.json create mode 100644 multisig/simulations/zksyncsepolia/vip-012/abi/rateModel.json create mode 100644 multisig/simulations/zksyncsepolia/vip-012/abi/vToken.json create mode 100644 multisig/simulations/zksyncsepolia/vip-012/index.ts diff --git a/multisig/proposals/zksyncsepolia/vip-012/index.ts b/multisig/proposals/zksyncsepolia/vip-012/index.ts new file mode 100644 index 000000000..a577a10e2 --- /dev/null +++ b/multisig/proposals/zksyncsepolia/vip-012/index.ts @@ -0,0 +1,73 @@ +import { parseUnits } from "ethers/lib/utils"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { makeProposal } from "src/utils"; + +const { zksyncsepolia } = NETWORK_ADDRESSES; + +export const MOCK_USDC = "0x512F8b4a3c466a30e8c9BAC9c64638dd710968c2"; +export const VUSDC_CORE = "0xA266EfCC7D1a8F1AAd093446E3C0115467ea8b9C"; +export const INITIAL_SUPPLY = parseUnits("5000", 6); +const CHAINLINK_USDC_FEED = "0x1844478CA634f3a762a2E71E3386837Bd50C947F"; +const STALE_PERIOD_26H = 26 * 60 * 60; // 26 hours (pricefeeds with heartbeat of 24 hr) + +const vip012 = () => { + return makeProposal([ + { + target: zksyncsepolia.CHAINLINK_ORACLE, + signature: "setTokenConfig((address,address,uint256))", + params: [[MOCK_USDC, CHAINLINK_USDC_FEED, STALE_PERIOD_26H]], + }, + { + target: zksyncsepolia.RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [ + MOCK_USDC, + [ + zksyncsepolia.CHAINLINK_ORACLE, + "0x0000000000000000000000000000000000000000", + "0x0000000000000000000000000000000000000000", + ], + [true, false, false], + ], + ], + }, + { + target: MOCK_USDC, + signature: "faucet(uint256)", + params: [INITIAL_SUPPLY], + }, + { + target: MOCK_USDC, + signature: "approve(address,uint256)", + params: [zksyncsepolia.POOL_REGISTRY, 0], + }, + { + target: MOCK_USDC, + signature: "approve(address,uint256)", + params: [zksyncsepolia.POOL_REGISTRY, INITIAL_SUPPLY], + }, + { + target: VUSDC_CORE, + signature: "setReduceReservesBlockDelta(uint256)", + params: ["86400"], + }, + { + target: zksyncsepolia.POOL_REGISTRY, + signature: "addMarket((address,uint256,uint256,uint256,address,uint256,uint256))", + params: [ + [ + VUSDC_CORE, + parseUnits("0.72", 18), // CF + parseUnits("0.75", 18), // LT + INITIAL_SUPPLY, // initial supply + zksyncsepolia.VTREASURY, + parseUnits("1250000", 6), // supply cap + parseUnits("1000000", 6), // borrow cap + ], + ], + }, + ]); +}; + +export default vip012; diff --git a/multisig/simulations/zksyncsepolia/vip-012/abi/comptroller.json b/multisig/simulations/zksyncsepolia/vip-012/abi/comptroller.json new file mode 100644 index 000000000..fafe7b35e --- /dev/null +++ b/multisig/simulations/zksyncsepolia/vip-012/abi/comptroller.json @@ -0,0 +1,1496 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "poolRegistry_", + "type": "address" + }, + { + "internalType": "address", + "name": "accessControl_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedLessThanOrEqualTo", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { + "inputs": [], + "name": "ComptrollerMismatch", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "collateralToSeize", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "availableCollateral", + "type": "uint256" + } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientLiquidity", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientShortfall", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidCollateralFactor", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidLiquidationThreshold", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedGreaterThan", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { + "inputs": [], + "name": "NonzeroBorrowBalance", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { + "inputs": [], + "name": "TooMuchRepay", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "expectedSender", + "type": "address" + }, + { + "internalType": "address", + "name": "actualSender", + "type": "address" + } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "bool", + "name": "pauseState", + "type": "bool" + } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newBorrowCap", + "type": "uint256" + } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldCloseFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldCollateralFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationIncentiveMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationThresholdMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMinLiquidatableCollateral", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "rewardsDistributor", + "type": "address" + } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSupplyCap", + "type": "uint256" + } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControl", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "accountAssets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "actionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract RewardsDistributor", + "name": "_rewardsDistributor", + "type": "address" + } + ], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "allMarkets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "borrowCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "checkMembership", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "vTokens", + "type": "address[]" + } + ], + "name": "enterMarkets", + "outputs": [ + { + "internalType": "uint256[]", + "name": "", + "type": "uint256[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenAddress", + "type": "address" + } + ], + "name": "exitMarket", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAssetsIn", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenModify", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [ + { + "internalType": "contract RewardsDistributor[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "rewardToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "supplySpeed", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowSpeed", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isDeprecated", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isMarketListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "components": [ + { + "internalType": "contract VToken", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokensToSeize", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "markets", + "outputs": [ + { + "internalType": "bool", + "name": "isListed", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "collateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidationThresholdMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [ + { + "internalType": "contract PriceOracle", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "skipLiquidityCheck", + "type": "bool" + } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "seizerContract", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "transferTokens", + "type": "uint256" + } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "marketsList", + "type": "address[]" + }, + { + "internalType": "enum ComptrollerStorage.Action[]", + "name": "actionsList", + "type": "uint8[]" + }, + { + "internalType": "bool", + "name": "paused", + "type": "bool" + } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newBorrowCaps", + "type": "uint256[]" + } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newSupplyCaps", + "type": "uint256[]" + } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract PriceOracle", + "name": "newOracle", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "supplyCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/zksyncsepolia/vip-012/abi/erc20.json b/multisig/simulations/zksyncsepolia/vip-012/abi/erc20.json new file mode 100644 index 000000000..374b04c75 --- /dev/null +++ b/multisig/simulations/zksyncsepolia/vip-012/abi/erc20.json @@ -0,0 +1,295 @@ +[ + { + "inputs": [ + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "userAddress", "type": "address" }, + { "indexed": false, "internalType": "address payable", "name": "relayerAddress", "type": "address" }, + { "indexed": false, "internalType": "bytes", "name": "functionSignature", "type": "bytes" } + ], + "name": "MetaTransactionExecuted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } + ], + "name": "RoleAdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_ADMIN_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "ERC712_VERSION", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "PREDICATE_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "userAddress", "type": "address" }, + { "internalType": "bytes", "name": "functionSignature", "type": "bytes" }, + { "internalType": "bytes32", "name": "sigR", "type": "bytes32" }, + { "internalType": "bytes32", "name": "sigS", "type": "bytes32" }, + { "internalType": "uint8", "name": "sigV", "type": "uint8" } + ], + "name": "executeMetaTransaction", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [], + "name": "getChainId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [], + "name": "getDomainSeperator", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "getNonce", + "outputs": [{ "internalType": "uint256", "name": "nonce", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleAdmin", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "uint256", "name": "index", "type": "uint256" } + ], + "name": "getRoleMember", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleMemberCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "grantRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "hasRole", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "renounceRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "revokeRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/zksyncsepolia/vip-012/abi/rateModel.json b/multisig/simulations/zksyncsepolia/vip-012/abi/rateModel.json new file mode 100644 index 000000000..8c04a8527 --- /dev/null +++ b/multisig/simulations/zksyncsepolia/vip-012/abi/rateModel.json @@ -0,0 +1,118 @@ +[ + { + "inputs": [ + { "internalType": "uint256", "name": "baseRatePerYear", "type": "uint256" }, + { "internalType": "uint256", "name": "multiplierPerYear", "type": "uint256" }, + { "internalType": "uint256", "name": "jumpMultiplierPerYear", "type": "uint256" }, + { "internalType": "uint256", "name": "kink_", "type": "uint256" } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "baseRatePerBlock", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "multiplierPerBlock", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "jumpMultiplierPerBlock", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "kink", "type": "uint256" } + ], + "name": "NewInterestParams", + "type": "event" + }, + { + "constant": true, + "inputs": [], + "name": "baseRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "blocksPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "uint256", "name": "cash", "type": "uint256" }, + { "internalType": "uint256", "name": "borrows", "type": "uint256" }, + { "internalType": "uint256", "name": "reserves", "type": "uint256" } + ], + "name": "getBorrowRate", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "uint256", "name": "cash", "type": "uint256" }, + { "internalType": "uint256", "name": "borrows", "type": "uint256" }, + { "internalType": "uint256", "name": "reserves", "type": "uint256" }, + { "internalType": "uint256", "name": "reserveFactorMantissa", "type": "uint256" } + ], + "name": "getSupplyRate", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isInterestRateModel", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "jumpMultiplierPerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "kink", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "multiplierPerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "uint256", "name": "cash", "type": "uint256" }, + { "internalType": "uint256", "name": "borrows", "type": "uint256" }, + { "internalType": "uint256", "name": "reserves", "type": "uint256" } + ], + "name": "utilizationRate", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "pure", + "type": "function" + } +] diff --git a/multisig/simulations/zksyncsepolia/vip-012/abi/vToken.json b/multisig/simulations/zksyncsepolia/vip-012/abi/vToken.json new file mode 100644 index 000000000..1ce01e4a8 --- /dev/null +++ b/multisig/simulations/zksyncsepolia/vip-012/abi/vToken.json @@ -0,0 +1,2066 @@ +[ + { + "inputs": [ + { + "internalType": "bool", + "name": "timeBased_", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "blocksPerYear_", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxBorrowRateMantissa_", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "actualAddAmount", + "type": "uint256" + } + ], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { + "inputs": [], + "name": "BorrowCashNotAvailable", + "type": "error" + }, + { + "inputs": [], + "name": "BorrowFreshnessCheck", + "type": "error" + }, + { + "inputs": [], + "name": "DelegateNotApproved", + "type": "error" + }, + { + "inputs": [], + "name": "ForceLiquidateBorrowUnauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "HealBorrowUnauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidBlocksPerYear", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidTimeBasedConfiguration", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "errorCode", + "type": "uint256" + } + ], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { + "inputs": [], + "name": "LiquidateCloseAmountIsUintMax", + "type": "error" + }, + { + "inputs": [], + "name": "LiquidateCloseAmountIsZero", + "type": "error" + }, + { + "inputs": [], + "name": "LiquidateCollateralFreshnessCheck", + "type": "error" + }, + { + "inputs": [], + "name": "LiquidateFreshnessCheck", + "type": "error" + }, + { + "inputs": [], + "name": "LiquidateLiquidatorIsBorrower", + "type": "error" + }, + { + "inputs": [], + "name": "LiquidateSeizeLiquidatorIsBorrower", + "type": "error" + }, + { + "inputs": [], + "name": "MintFreshnessCheck", + "type": "error" + }, + { + "inputs": [], + "name": "ProtocolSeizeShareTooBig", + "type": "error" + }, + { + "inputs": [], + "name": "RedeemFreshnessCheck", + "type": "error" + }, + { + "inputs": [], + "name": "RedeemTransferOutNotPossible", + "type": "error" + }, + { + "inputs": [], + "name": "ReduceReservesCashNotAvailable", + "type": "error" + }, + { + "inputs": [], + "name": "ReduceReservesCashValidation", + "type": "error" + }, + { + "inputs": [], + "name": "ReduceReservesFreshCheck", + "type": "error" + }, + { + "inputs": [], + "name": "RepayBorrowFreshnessCheck", + "type": "error" + }, + { + "inputs": [], + "name": "SetInterestRateModelFreshCheck", + "type": "error" + }, + { + "inputs": [], + "name": "SetReserveFactorBoundsCheck", + "type": "error" + }, + { + "inputs": [], + "name": "SetReserveFactorFreshCheck", + "type": "error" + }, + { + "inputs": [], + "name": "TransferNotAllowed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "cashPrior", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "interestAccumulated", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "borrowIndex", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "totalBorrows", + "type": "uint256" + } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "badDebtDelta", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "badDebtOld", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "badDebtNew", + "type": "uint256" + } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "badDebtOld", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "badDebtNew", + "type": "uint256" + } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "accountBorrows", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "totalBorrows", + "type": "uint256" + } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "payer", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "seizeTokens", + "type": "uint256" + } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "mintTokens", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "accountBalance", + "type": "uint256" + } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract ComptrollerInterface", + "name": "oldComptroller", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract ComptrollerInterface", + "name": "newComptroller", + "type": "address" + } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldProtocolSeizeShareMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newProtocolSeizeShareMantissa", + "type": "uint256" + } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldProtocolShareReserve", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newProtocolShareReserve", + "type": "address" + } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldReduceReservesBlockOrTimestampDelta", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newReduceReservesBlockOrTimestampDelta", + "type": "uint256" + } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldReserveFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newReserveFactorMantissa", + "type": "uint256" + } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldShortfall", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newShortfall", + "type": "address" + } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "redeemAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "accountBalance", + "type": "uint256" + } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "payer", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "accountBorrows", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "totalBorrows", + "type": "uint256" + } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "benefactor", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "addAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newTotalReserves", + "type": "uint256" + } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "protocolShareReserve", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "reduceAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newTotalReserves", + "type": "uint256" + } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "token", + "type": "address" + } + ], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "addAmount", + "type": "uint256" + } + ], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "address", + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "recoveredAmount_", + "type": "uint256" + } + ], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + } + ], + "name": "balanceOfUnderlying", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "borrow", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "borrowBalanceCurrent", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "borrowBalanceStored", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "borrowBehalf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [ + { + "internalType": "contract ComptrollerInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "internalType": "contract VTokenInterface", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "bool", + "name": "skipLiquidityCheck", + "type": "bool" + } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAccountSnapshot", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "vTokenBalance", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowBalance", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "exchangeRate", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "payer", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "underlying_", + "type": "address" + }, + { + "internalType": "contract ComptrollerInterface", + "name": "comptroller_", + "type": "address" + }, + { + "internalType": "contract InterestRateModel", + "name": "interestRateModel_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "initialExchangeRateMantissa_", + "type": "uint256" + }, + { + "internalType": "string", + "name": "name_", + "type": "string" + }, + { + "internalType": "string", + "name": "symbol_", + "type": "string" + }, + { + "internalType": "uint8", + "name": "decimals_", + "type": "uint8" + }, + { + "internalType": "address", + "name": "admin_", + "type": "address" + }, + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + }, + { + "components": [ + { + "internalType": "address", + "name": "shortfall", + "type": "address" + }, + { + "internalType": "address payable", + "name": "protocolShareReserve", + "type": "address" + } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "reserveFactorMantissa_", + "type": "uint256" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [ + { + "internalType": "contract InterestRateModel", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "internalType": "contract VTokenInterface", + "name": "vTokenCollateral", + "type": "address" + } + ], + "name": "liquidateBorrow", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "mintBehalf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [ + { + "internalType": "address payable", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "redeem", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "redeemBehalf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "redeemAmount", + "type": "uint256" + } + ], + "name": "redeemUnderlying", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemAmount", + "type": "uint256" + } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "reduceAmount", + "type": "uint256" + } + ], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "name": "repayBorrow", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "name": "repayBorrowBehalf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "seizeTokens", + "type": "uint256" + } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newProtocolSeizeShareMantissa_", + "type": "uint256" + } + ], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address payable", + "name": "protocolShareReserve_", + "type": "address" + } + ], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_newReduceReservesBlockOrTimestampDelta", + "type": "uint256" + } + ], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newReserveFactorMantissa", + "type": "uint256" + } + ], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "shortfall_", + "type": "address" + } + ], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract IERC20Upgradeable", + "name": "token", + "type": "address" + } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/zksyncsepolia/vip-012/index.ts b/multisig/simulations/zksyncsepolia/vip-012/index.ts new file mode 100644 index 000000000..03622f955 --- /dev/null +++ b/multisig/simulations/zksyncsepolia/vip-012/index.ts @@ -0,0 +1,113 @@ +import { expect } from "chai"; +import { BigNumber, Contract } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip } from "src/vip-framework"; +import { checkVToken } from "src/vip-framework/checks/checkVToken"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; + +import vip012, { MOCK_USDC, VUSDC_CORE } from "../../../proposals/zksyncsepolia/vip-012"; +import COMPTROLLER_ABI from "./abi/comptroller.json"; +import ERC20_ABI from "./abi/erc20.json"; +import VTOKEN_ABI from "./abi/vToken.json"; + +const { zksyncsepolia } = NETWORK_ADDRESSES; + +const COMPTROLLER_CORE = "0xC527DE08E43aeFD759F7c0e6aE85433923064669"; +const PSR = "0x5722B43BD91fAaDC4E7f384F4d6Fb32456Ec5ffB"; + +const BLOCKS_PER_YEAR = BigNumber.from("31536000"); // equal to seconds in a year as it is timebased deployment + +forking(4120238, async () => { + describe("Post-Execution state", () => { + let allMarkets: any; + let vToken: Contract; + let comptroller: Contract; + + before(async () => { + comptroller = await ethers.getContractAt(COMPTROLLER_ABI, COMPTROLLER_CORE); + vToken = await ethers.getContractAt(VTOKEN_ABI, VUSDC_CORE); + + allMarkets = await comptroller.getAllMarkets(); + await pretendExecutingVip(await vip012()); + }); + + it("should register Core pool vTokens in Core pool Comptroller", async () => { + const poolVTokens = await comptroller.getAllMarkets(); + expect(poolVTokens).to.have.lengthOf(BigNumber.from(allMarkets.length).add(1)); + expect(poolVTokens).to.include(VUSDC_CORE); + }); + + it(`should set PSR`, async () => { + expect(await vToken.protocolShareReserve()).to.equal(PSR); + }); + + it(`should mint initial supply of VUSDC to VTreasury`, async () => { + // Since we're distributing 1:1, decimals should be accounted for in the exchange rate + const expectedSupply = parseUnits("5000", 8); + expect(await vToken.balanceOf(zksyncsepolia.VTREASURY)).to.equal(expectedSupply); + }); + + describe("Risk parameters", () => { + describe(`risk parameters`, () => { + let underlyingDecimals: number; + + before(async () => { + const underlying = await ethers.getContractAt(ERC20_ABI, MOCK_USDC); + underlyingDecimals = await underlying.decimals(); + }); + + it(`should set VUSDC reserve factor to 10%`, async () => { + expect(await vToken.reserveFactorMantissa()).to.equal(parseUnits("0.1", 18)); + }); + + it(`should set VUSDC collateral factor to 72%`, async () => { + const market = await comptroller.markets(VUSDC_CORE); + expect(market.collateralFactorMantissa).to.equal(parseUnits("0.72", 18)); + }); + + it(`should set VUSDC liquidation threshold to 75%`, async () => { + const market = await comptroller.markets(VUSDC_CORE); + expect(market.liquidationThresholdMantissa).to.equal(parseUnits("0.75", 18)); + }); + + it(`should set VUSDC protocol seize share to 0.05`, async () => { + expect(await vToken.protocolSeizeShareMantissa()).to.equal(parseUnits("0.05", 18)); + }); + + it(`should set VUSDC supply cap to 1250000`, async () => { + expect(await comptroller.supplyCaps(VUSDC_CORE)).to.equal(parseUnits("1250000", underlyingDecimals)); + }); + + it(`should set VUSDC borrow cap to 1000000`, async () => { + expect(await comptroller.borrowCaps(VUSDC_CORE)).to.equal(parseUnits("1000000", underlyingDecimals)); + }); + }); + + it("Interest rates", async () => { + checkInterestRate( + "0x782D1BA04d28dbbf1Ff664B62993f69cd6225466", // IRM + "VUSDC_CORE", + { + base: "0", + multiplier: "0.0875", + jump: "0.8", + kink: "0.8", + }, + BLOCKS_PER_YEAR, + ); + }); + it("check vtoken", async () => { + checkVToken(VUSDC_CORE, { + name: "Venus USDC (Core)", + symbol: "vUSDC_Core", + decimals: 8, + underlying: MOCK_USDC, + exchangeRate: parseUnits("1", 16), + comptroller: COMPTROLLER_CORE, + }); + }); + }); + }); +}); From e30387cbb5f388246a5d0e716bdf614a2c93c9ea Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Mon, 4 Nov 2024 20:56:31 +0530 Subject: [PATCH 092/178] refactor: configure prime on arbitrum sepolia --- .../arbitrumsepolia/vip-015/index.ts | 102 ++++++ .../arbitrumsepolia/vip-015/abi/Prime.json | 336 +++++++++++++++--- .../arbitrumsepolia/vip-015/index.ts | 14 +- 3 files changed, 397 insertions(+), 55 deletions(-) diff --git a/multisig/proposals/arbitrumsepolia/vip-015/index.ts b/multisig/proposals/arbitrumsepolia/vip-015/index.ts index 320f30898..d7eeff842 100644 --- a/multisig/proposals/arbitrumsepolia/vip-015/index.ts +++ b/multisig/proposals/arbitrumsepolia/vip-015/index.ts @@ -1,6 +1,9 @@ import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { makeProposal } from "src/utils"; +const { arbitrumsepolia } = NETWORK_ADDRESSES; + export const COMPTROLLER_CORE = "0x006D44b6f5927b3eD83bD0c1C36Fb1A3BaCaC208"; export const COMPTROLLER_LST = "0x3D04F926b2a165BBa17FBfccCCB61513634fa5e4"; export const PRIME = "0xAdB04AC4942683bc41E27d18234C8DC884786E89"; @@ -10,14 +13,113 @@ export const USDT = "0xf3118a17863996B9F2A073c9A66Faaa664355cf8"; export const USDC = "0x86f096B1D970990091319835faF3Ee011708eAe8"; export const WBTC = "0xFb8d93FD3Cf18386a5564bb5619cD1FdB130dF7D"; export const WETH = "0x980B62Da83eFf3D4576C647993b0c1D7faf17c73"; +export const PRIME_NEW_IMPLEMENTATION = "0x507866eCb585275E006D9098867a0e9B08C11CCe"; // contains the setter for the pool registry address +export const PRIME_OLD_IMPLEMENTATION = "0x255EFC81Ba715FA7C2C27bdd983A3CeF9BB07fEf"; +export const PROXY_ADMIN = "0xA78A1Df376c3CEeBC5Fab574fe6EdDbbF76fd03e"; export const VUSDT_CORE = "0xdEFbf0F9Ab6CdDd0a1FdDC894b358D0c0a39B052"; export const VUSDC_CORE = "0xd9d1e754464eFc7493B177d2c7be04816E089b4C"; export const VWBTC_CORE = "0x49FB90A5815904649C44B87001a160C1301D6a2C"; export const VWETH_LST = "0xd7057250b439c0849377bB6C3263eb8f9cf49d98"; +const ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; const vip015 = () => { return makeProposal([ + { + target: PROXY_ADMIN, + signature: "upgrade(address,address)", + params: [PRIME, PRIME_NEW_IMPLEMENTATION], + }, + { + target: PRIME, + signature: "setPoolRegistry(address)", + params: [arbitrumsepolia.POOL_REGISTRY], + }, + { + target: PROXY_ADMIN, + signature: "upgrade(address,address)", + params: [PRIME, PRIME_OLD_IMPLEMENTATION], + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [PLP, "setTokensDistributionSpeed(address[],uint256[])", arbitrumsepolia.GUARDIAN], + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [PLP, "setMaxTokensDistributionSpeed(address[],uint256[])", arbitrumsepolia.GUARDIAN], + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [PLP, "setMaxLoopsLimit(uint256)", arbitrumsepolia.GUARDIAN], + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [PLP, "pauseFundsTransfer()", arbitrumsepolia.GUARDIAN], + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [PLP, "resumeFundsTransfer()", arbitrumsepolia.GUARDIAN], + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [PRIME, "updateAlpha(uint128,uint128)", arbitrumsepolia.GUARDIAN], + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [PRIME, "updateMultipliers(address,uint256,uint256)", arbitrumsepolia.GUARDIAN], + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [PRIME, "setStakedAt(address[],uint256[])", arbitrumsepolia.GUARDIAN], + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [PRIME, "addMarket(address,address,uint256,uint256)", arbitrumsepolia.GUARDIAN], + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [PRIME, "setLimit(uint256,uint256)", arbitrumsepolia.GUARDIAN], + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [PRIME, "setMaxLoopsLimit(uint256)", arbitrumsepolia.GUARDIAN], + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [PRIME, "issue(bool,address[])", arbitrumsepolia.GUARDIAN], + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [PRIME, "burn(address)", arbitrumsepolia.GUARDIAN], + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [PRIME, "togglePause()", arbitrumsepolia.GUARDIAN], + }, + { + target: COMPTROLLER_CORE, + signature: "setPrimeToken(address)", + params: [PRIME], + }, + { + target: COMPTROLLER_LST, + signature: "setPrimeToken(address)", + params: [PRIME], + }, { target: PLP, signature: "initializeTokens(address[])", diff --git a/multisig/simulations/arbitrumsepolia/vip-015/abi/Prime.json b/multisig/simulations/arbitrumsepolia/vip-015/abi/Prime.json index 971299cad..0895c7575 100644 --- a/multisig/simulations/arbitrumsepolia/vip-015/abi/Prime.json +++ b/multisig/simulations/arbitrumsepolia/vip-015/abi/Prime.json @@ -3,12 +3,12 @@ "inputs": [ { "internalType": "address", - "name": "_wbnb", + "name": "_wrappedNativeToken", "type": "address" }, { "internalType": "address", - "name": "_vbnb", + "name": "_nativeMarket", "type": "address" }, { @@ -30,6 +30,11 @@ "internalType": "uint256", "name": "_maximumXVSCap", "type": "uint256" + }, + { + "internalType": "bool", + "name": "_timeBased", + "type": "bool" } ], "stateMutability": "nonpayable", @@ -71,11 +76,6 @@ "name": "InvalidBlocksPerYear", "type": "error" }, - { - "inputs": [], - "name": "InvalidCaller", - "type": "error" - }, { "inputs": [], "name": "InvalidComptroller", @@ -112,6 +112,16 @@ "name": "InvalidLimit", "type": "error" }, + { + "inputs": [], + "name": "InvalidTimeBasedConfiguration", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidTimestamp", + "type": "error" + }, { "inputs": [], "name": "InvalidVToken", @@ -289,17 +299,23 @@ { "indexed": true, "internalType": "address", - "name": "market", + "name": "comptroller", "type": "address" }, { "indexed": true, + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "indexed": false, "internalType": "uint256", "name": "supplyMultiplier", "type": "uint256" }, { - "indexed": true, + "indexed": false, "internalType": "uint256", "name": "borrowMultiplier", "type": "uint256" @@ -544,7 +560,7 @@ }, { "inputs": [], - "name": "BLOCKS_PER_YEAR", + "name": "MAXIMUM_XVS_CAP", "outputs": [ { "internalType": "uint256", @@ -557,7 +573,7 @@ }, { "inputs": [], - "name": "MAXIMUM_XVS_CAP", + "name": "MINIMUM_STAKED_XVS", "outputs": [ { "internalType": "uint256", @@ -570,12 +586,12 @@ }, { "inputs": [], - "name": "MINIMUM_STAKED_XVS", + "name": "NATIVE_MARKET", "outputs": [ { - "internalType": "uint256", + "internalType": "address", "name": "", - "type": "uint256" + "type": "address" } ], "stateMutability": "view", @@ -596,20 +612,7 @@ }, { "inputs": [], - "name": "VBNB", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "WBNB", + "name": "WRAPPED_NATIVE_TOKEN", "outputs": [ { "internalType": "address", @@ -673,6 +676,11 @@ }, { "inputs": [ + { + "internalType": "address", + "name": "comptroller", + "type": "address" + }, { "internalType": "address", "name": "market", @@ -720,6 +728,19 @@ "stateMutability": "view", "type": "function" }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, { "inputs": [ { @@ -749,14 +770,61 @@ "name": "calculateAPR", "outputs": [ { - "internalType": "uint256", - "name": "supplyAPR", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "borrowAPR", - "type": "uint256" + "components": [ + { + "internalType": "uint256", + "name": "supplyAPR", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAPR", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "totalScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "userScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "xvsBalanceForScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "capital", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "cappedSupply", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "cappedBorrow", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supplyCapUSD", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowCapUSD", + "type": "uint256" + } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" } ], "stateMutability": "view", @@ -875,14 +943,61 @@ "name": "estimateAPR", "outputs": [ { - "internalType": "uint256", - "name": "supplyAPR", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "borrowAPR", - "type": "uint256" + "components": [ + { + "internalType": "uint256", + "name": "supplyAPR", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAPR", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "totalScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "userScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "xvsBalanceForScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "capital", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "cappedSupply", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "cappedBorrow", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supplyCapUSD", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowCapUSD", + "type": "uint256" + } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" } ], "stateMutability": "view", @@ -901,6 +1016,19 @@ "stateMutability": "view", "type": "function" }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, { "inputs": [ { @@ -933,13 +1061,18 @@ "type": "address" } ], - "name": "getPendingInterests", + "name": "getPendingRewards", "outputs": [ { "components": [ { "internalType": "address", - "name": "market", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "rewardToken", "type": "address" }, { @@ -948,14 +1081,33 @@ "type": "uint256" } ], - "internalType": "struct PrimeStorageV1.PendingInterest[]", - "name": "pendingInterests", + "internalType": "struct PrimeStorageV1.PendingReward[]", + "name": "pendingRewards", "type": "tuple[]" } ], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "incomeDistributionYearly", + "outputs": [ + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, { "inputs": [ { @@ -1014,6 +1166,19 @@ "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { + "internalType": "address", + "name": "poolRegistry_", + "type": "address" + } + ], + "name": "initializeV2", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, { "inputs": [ { @@ -1085,6 +1250,38 @@ "stateMutability": "view", "type": "function" }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "isUserPrimeHolder", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, { "inputs": [ { @@ -1235,7 +1432,7 @@ }, { "inputs": [], - "name": "primeLiquidityProvider", + "name": "poolRegistry", "outputs": [ { "internalType": "address", @@ -1248,7 +1445,7 @@ }, { "inputs": [], - "name": "protocolShareReserve", + "name": "primeLiquidityProvider", "outputs": [ { "internalType": "address", @@ -1547,5 +1744,44 @@ "outputs": [], "stateMutability": "nonpayable", "type": "function" + }, + { + "inputs": [], + "name": "xvsVault", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultPoolId", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultRewardToken", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" } ] diff --git a/multisig/simulations/arbitrumsepolia/vip-015/index.ts b/multisig/simulations/arbitrumsepolia/vip-015/index.ts index a65c516a6..8a227910d 100644 --- a/multisig/simulations/arbitrumsepolia/vip-015/index.ts +++ b/multisig/simulations/arbitrumsepolia/vip-015/index.ts @@ -1,9 +1,7 @@ -/* eslint-disable @typescript-eslint/no-unused-vars */ import { expect } from "chai"; -import { BigNumber, Contract, Signer } from "ethers"; -import { parseUnits } from "ethers/lib/utils"; +import { Contract } from "ethers"; import { ethers } from "hardhat"; -import { initMainnetUser } from "src/utils"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { forking, pretendExecutingVip } from "src/vip-framework"; import vip015, { @@ -24,7 +22,9 @@ import COMPTROLLER_ABI from "./abi/ILComptroller.json"; import PRIME_ABI from "./abi/Prime.json"; import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; -forking(92376372, async () => { +const { arbitrumsepolia } = NETWORK_ADDRESSES; + +forking(94278700, async () => { const provider = ethers.provider; let prime: Contract; let plp: Contract; @@ -61,6 +61,10 @@ forking(92376372, async () => { plp = new ethers.Contract(PLP, PLP_ABI, provider); }); + it("prime should have correct pool registry address", async () => { + expect(await prime.poolRegistry()).to.be.equal(arbitrumsepolia.POOL_REGISTRY); + }); + it("Comptroller lst and core should have correct Prime token address", async () => { const comptrollerCore = new ethers.Contract(COMPTROLLER_CORE, COMPTROLLER_ABI, provider); expect(await comptrollerCore.prime()).to.be.equal(PRIME); From 3be9976ac0a5eb4efaa11254f35cb399c05852de Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Tue, 5 Nov 2024 00:41:09 +0530 Subject: [PATCH 093/178] feat: configure converters on arbitrum sepolia --- .../arbitrumsepolia/vip-016/Addresses.ts | 41 + .../arbitrumsepolia/vip-016/commands.ts | 107 ++ .../arbitrumsepolia/vip-016/index.ts | 101 ++ .../vip-016/abi/ConverterNetwork.json | 448 ++++++ .../arbitrumsepolia/vip-016/abi/ERC20.json | 289 ++++ .../vip-016/abi/ProtocolShareReserve.json | 800 ++++++++++ .../vip-016/abi/SingleTokenConverter.json | 1381 +++++++++++++++++ .../vip-016/abi/XVSVaultTreasury.json | 306 ++++ .../arbitrumsepolia/vip-016/index.ts | 207 +++ 9 files changed, 3680 insertions(+) create mode 100644 multisig/proposals/arbitrumsepolia/vip-016/Addresses.ts create mode 100644 multisig/proposals/arbitrumsepolia/vip-016/commands.ts create mode 100644 multisig/proposals/arbitrumsepolia/vip-016/index.ts create mode 100644 multisig/simulations/arbitrumsepolia/vip-016/abi/ConverterNetwork.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-016/abi/ERC20.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-016/abi/ProtocolShareReserve.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-016/abi/SingleTokenConverter.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-016/abi/XVSVaultTreasury.json create mode 100644 multisig/simulations/arbitrumsepolia/vip-016/index.ts diff --git a/multisig/proposals/arbitrumsepolia/vip-016/Addresses.ts b/multisig/proposals/arbitrumsepolia/vip-016/Addresses.ts new file mode 100644 index 000000000..ca277586a --- /dev/null +++ b/multisig/proposals/arbitrumsepolia/vip-016/Addresses.ts @@ -0,0 +1,41 @@ +export const Assets = [ + "0xf3118a17863996B9F2A073c9A66Faaa664355cf8", // USDT + "0x86f096B1D970990091319835faF3Ee011708eAe8", // USDC + "0xFb8d93FD3Cf18386a5564bb5619cD1FdB130dF7D", // WBTC + "0x980B62Da83eFf3D4576C647993b0c1D7faf17c73", // WETH + "0x877Dc896e7b13096D3827872e396927BbE704407", // XVS +]; + +export const BaseAssets = [ + "0xf3118a17863996B9F2A073c9A66Faaa664355cf8", // USDT USDTPrimeConverter BaseAsset + "0x86f096B1D970990091319835faF3Ee011708eAe8", // USDC USDCPrimeConverter BaseAsset + "0xFb8d93FD3Cf18386a5564bb5619cD1FdB130dF7D", // WBTC WBTCPrimeConverter BaseAsset + "0x980B62Da83eFf3D4576C647993b0c1D7faf17c73", // WETH WETHPrimeConverter BaseAsset + "0x877Dc896e7b13096D3827872e396927BbE704407", // XVS XVSPrimeConverter BaseAsset +]; + +export const CONVERTER_NETWORK = "0x9dD63dC8DADf90B67511939C00607484567B0D7A"; +export const USDT_PRIME_CONVERTER = "0xFC0ec257d3ec4D673cB4e2CD3827C202e75fd0be"; +export const USDC_PRIME_CONVERTER = "0xE88ed530597bc8D50e8CfC0EecAAFf6A93248C74"; +export const WBTC_PRIME_CONVERTER = "0x3089F46caf6611806caA39Ffaf672097156b893a"; +export const WETH_PRIME_CONVERTER = "0x0d1e90c1F86CD1c1dF514B493c5985B3FD9CD6C8"; +export const XVS_VAULT_CONVERTER = "0x99942a033454Cef6Ffb2843886C8b2E658E7D5fd"; + +export const ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; + +export const converters: string[] = [ + USDT_PRIME_CONVERTER, + USDC_PRIME_CONVERTER, + WBTC_PRIME_CONVERTER, + WETH_PRIME_CONVERTER, + XVS_VAULT_CONVERTER, +]; + +// Function to filter assets based on a base asset +const filterAssets = (assets: string[], baseAsset: string) => assets.filter(asset => asset !== baseAsset); + +export const USDTPrimeConverterTokenOuts = filterAssets(Assets, BaseAssets[0]); +export const USDCPrimeConverterTokenOuts = filterAssets(Assets, BaseAssets[1]); +export const WBTCPrimeConverterTokenOuts = filterAssets(Assets, BaseAssets[2]); +export const WETHPrimeConverterTokenOuts = filterAssets(Assets, BaseAssets[3]); +export const XVSVaultConverterTokenOuts = filterAssets(Assets, BaseAssets[4]); diff --git a/multisig/proposals/arbitrumsepolia/vip-016/commands.ts b/multisig/proposals/arbitrumsepolia/vip-016/commands.ts new file mode 100644 index 000000000..9e48e39ed --- /dev/null +++ b/multisig/proposals/arbitrumsepolia/vip-016/commands.ts @@ -0,0 +1,107 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; + +import { ACM, Assets, CONVERTER_NETWORK, converters } from "./Addresses"; + +const { arbitrumsepolia } = NETWORK_ADDRESSES; + +type IncentiveAndAccessibility = [number, number]; + +interface AcceptOwnership { + target: string; + signature: string; + params: []; +} + +interface ConverterCommand { + target: string; + signature: string; + params: [string]; +} + +interface CallPermission { + target: string; + signature: string; + params: [string, string, string]; +} + +export const grant = (target: string, signature: string, caller: string): CallPermission => { + const config: CallPermission = { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [target, signature, caller], + }; + + return config; +}; + +const incentiveAndAccessibility: IncentiveAndAccessibility = [0, 1]; + +function generateAcceptOwnershipCommands(ConvertersArray: string[]): AcceptOwnership[] { + const acceptOwnershipCommandsArray: AcceptOwnership[] = []; + + for (const converter of ConvertersArray) { + const config: AcceptOwnership = { + target: converter, + signature: "acceptOwnership()", + params: [], + }; + + acceptOwnershipCommandsArray.push(config); + } + + return acceptOwnershipCommandsArray; +} + +function generateConverterCommands(ConvertersArray: string[]): ConverterCommand[] { + const commandsArray: ConverterCommand[] = []; + + for (const converter of ConvertersArray) { + // Add AddConverterNetwork command + const addConverterNetworkConfig: ConverterCommand = { + target: converter, + signature: "setConverterNetwork(address)", + params: [CONVERTER_NETWORK], + }; + + // Add AddTokenConverter command + const addTokenConverterConfig: ConverterCommand = { + target: CONVERTER_NETWORK, + signature: "addTokenConverter(address)", + params: [converter], + }; + + commandsArray.push(addConverterNetworkConfig); + commandsArray.push(addTokenConverterConfig); + } + + return commandsArray; +} + +function generateCallPermissionCommands(ConvertersArray: string[]): CallPermission[] { + const callPermissionCommandsArray: CallPermission[] = []; + + for (const converter of ConvertersArray) { + const config1 = grant(converter, "setConversionConfig(address,address,ConversionConfig)", arbitrumsepolia.GUARDIAN); + const config2 = grant(converter, "pauseConversion()", arbitrumsepolia.GUARDIAN); + const config3 = grant(converter, "resumeConversion()", arbitrumsepolia.GUARDIAN); + const config4 = grant(converter, "setMinAmountToConvert(uint256)", arbitrumsepolia.GUARDIAN); + + callPermissionCommandsArray.push(config1); + callPermissionCommandsArray.push(config2); + callPermissionCommandsArray.push(config3); + callPermissionCommandsArray.push(config4); + } + return callPermissionCommandsArray; +} + +export const incentiveAndAccessibilities: IncentiveAndAccessibility[] = []; + +for (let i = 0; i < Assets.length - 1; i++) { + incentiveAndAccessibilities.push(incentiveAndAccessibility); +} + +export const acceptOwnershipCommandsAllConverters: AcceptOwnership[] = generateAcceptOwnershipCommands(converters); + +export const converterCommands: ConverterCommand[] = generateConverterCommands(converters); + +export const callPermissionCommandsAllConverter: CallPermission[] = generateCallPermissionCommands(converters); diff --git a/multisig/proposals/arbitrumsepolia/vip-016/index.ts b/multisig/proposals/arbitrumsepolia/vip-016/index.ts new file mode 100644 index 000000000..35ba7d41f --- /dev/null +++ b/multisig/proposals/arbitrumsepolia/vip-016/index.ts @@ -0,0 +1,101 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { makeProposal } from "src/utils"; + +import { + BaseAssets, + CONVERTER_NETWORK, + USDCPrimeConverterTokenOuts, + USDC_PRIME_CONVERTER, + USDTPrimeConverterTokenOuts, + USDT_PRIME_CONVERTER, + WBTCPrimeConverterTokenOuts, + WBTC_PRIME_CONVERTER, + WETHPrimeConverterTokenOuts, + WETH_PRIME_CONVERTER, + XVSVaultConverterTokenOuts, + XVS_VAULT_CONVERTER, +} from "./Addresses"; +import { + acceptOwnershipCommandsAllConverters, + callPermissionCommandsAllConverter, + converterCommands, + grant, + incentiveAndAccessibilities, +} from "./commands"; + +const { arbitrumsepolia } = NETWORK_ADDRESSES; + +export const COMPTROLLER_CORE = "0x006D44b6f5927b3eD83bD0c1C36Fb1A3BaCaC208"; +export const COMPTROLLER_LST = "0x3D04F926b2a165BBa17FBfccCCB61513634fa5e4"; +export const PRIME = "0xAdB04AC4942683bc41E27d18234C8DC884786E89"; +export const PLP = "0xE82c2c10F55D3268126C29ec813dC6F086904694"; + +export const XVS_VAULT_TREASURY = "0x309b71a417dA9CfA8aC47e6038000B1739d9A3A6"; +export const PROTOCOL_SHARE_RESERVE_PROXY = "0x09267d30798B59c581ce54E861A084C6FC298666"; +export const VTREASURY = "0x4e7ab1fD841E1387Df4c91813Ae03819C33D5bdB"; + +const vip016 = () => { + return makeProposal([ + ...acceptOwnershipCommandsAllConverters, + { + target: XVS_VAULT_TREASURY, + signature: "acceptOwnership()", + params: [], + }, + { + target: CONVERTER_NETWORK, + signature: "acceptOwnership()", + params: [], + }, + ...callPermissionCommandsAllConverter, + + grant(CONVERTER_NETWORK, "addTokenConverter(address)", arbitrumsepolia.GUARDIAN), + grant(CONVERTER_NETWORK, "removeTokenConverter(address)", arbitrumsepolia.GUARDIAN), + grant(XVS_VAULT_TREASURY, "fundXVSVault(uint256)", arbitrumsepolia.GUARDIAN), + + { + target: PROTOCOL_SHARE_RESERVE_PROXY, + signature: "addOrUpdateDistributionConfigs((uint8,uint16,address)[])", + params: [ + [ + [0, 6000, VTREASURY], + [0, 2000, XVS_VAULT_CONVERTER], + [0, 500, USDC_PRIME_CONVERTER], // 25% of the Prime allocation + [0, 500, USDT_PRIME_CONVERTER], // 25% of the Prime allocation + [0, 300, WBTC_PRIME_CONVERTER], // 15% of the Prime allocation + [0, 700, WETH_PRIME_CONVERTER], // 35% of the Prime allocation + [1, 8000, VTREASURY], + [1, 2000, XVS_VAULT_CONVERTER], + ], + ], + }, + ...converterCommands, + { + target: USDT_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[0], USDTPrimeConverterTokenOuts, incentiveAndAccessibilities], + }, + { + target: USDC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[1], USDCPrimeConverterTokenOuts, incentiveAndAccessibilities], + }, + { + target: WBTC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[2], WBTCPrimeConverterTokenOuts, incentiveAndAccessibilities], + }, + { + target: WETH_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[3], WETHPrimeConverterTokenOuts, incentiveAndAccessibilities], + }, + { + target: XVS_VAULT_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[4], XVSVaultConverterTokenOuts, incentiveAndAccessibilities], + }, + ]); +}; + +export default vip016; diff --git a/multisig/simulations/arbitrumsepolia/vip-016/abi/ConverterNetwork.json b/multisig/simulations/arbitrumsepolia/vip-016/abi/ConverterNetwork.json new file mode 100644 index 000000000..0fa27deec --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-016/abi/ConverterNetwork.json @@ -0,0 +1,448 @@ +[ + { + "inputs": [], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [], + "name": "ConverterAlreadyExists", + "type": "error" + }, + { + "inputs": [], + "name": "ConverterDoesNotExist", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "loopsLimit", + "type": "uint256" + } + ], + "name": "InvalidMaxLoopsLimit", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidTokenConverterAddress", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "loopsLimit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "requiredLoops", + "type": "uint256" + } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "converter", + "type": "address" + } + ], + "name": "ConverterAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "converter", + "type": "address" + } + ], + "name": "ConverterRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMaxLoopsLimit", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newmaxLoopsLimit", + "type": "uint256" + } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract IAbstractTokenConverter", + "name": "_tokenConverter", + "type": "address" + } + ], + "name": "addTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "allConverters", + "outputs": [ + { + "internalType": "contract IAbstractTokenConverter", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "_tokenAddressOut", + "type": "address" + } + ], + "name": "findTokenConverters", + "outputs": [ + { + "internalType": "address[]", + "name": "converters", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "convertersBalance", + "type": "uint256[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "_tokenAddressOut", + "type": "address" + } + ], + "name": "findTokenConvertersForConverters", + "outputs": [ + { + "internalType": "address[]", + "name": "converters", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "convertersBalance", + "type": "uint256[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getAllConverters", + "outputs": [ + { + "internalType": "contract IAbstractTokenConverter[]", + "name": "converters", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_accessControlManager", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_loopsLimit", + "type": "uint256" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_tokenConverter", + "type": "address" + } + ], + "name": "isTokenConverter", + "outputs": [ + { + "internalType": "bool", + "name": "isConverter", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract IAbstractTokenConverter", + "name": "_tokenConverter", + "type": "address" + } + ], + "name": "removeTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "limit", + "type": "uint256" + } + ], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-016/abi/ERC20.json b/multisig/simulations/arbitrumsepolia/vip-016/abi/ERC20.json new file mode 100644 index 000000000..28715d783 --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-016/abi/ERC20.json @@ -0,0 +1,289 @@ +[ + { + "inputs": [ + { + "internalType": "uint256", + "name": "_initialAmount", + "type": "uint256" + }, + { + "internalType": "string", + "name": "_tokenName", + "type": "string" + }, + { + "internalType": "uint8", + "name": "_decimalUnits", + "type": "uint8" + }, + { + "internalType": "string", + "name": "_tokenSymbol", + "type": "string" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "_owner", + "type": "address" + }, + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "allocateTo", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "_spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-016/abi/ProtocolShareReserve.json b/multisig/simulations/arbitrumsepolia/vip-016/abi/ProtocolShareReserve.json new file mode 100644 index 000000000..c845d8745 --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-016/abi/ProtocolShareReserve.json @@ -0,0 +1,800 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "_corePoolComptroller", + "type": "address" + }, + { + "internalType": "address", + "name": "_wbnb", + "type": "address" + }, + { + "internalType": "address", + "name": "_vbnb", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [], + "name": "InvalidAddress", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidTotalPercentage", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "loopsLimit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "requiredLoops", + "type": "uint256" + } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "destination", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "enum ProtocolShareReserve.Schema", + "name": "schema", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "percent", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "AssetReleased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "enum IProtocolShareReserve.IncomeType", + "name": "incomeType", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum ProtocolShareReserve.Schema", + "name": "schema", + "type": "uint8" + } + ], + "name": "AssetsReservesUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "destination", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint16", + "name": "percentage", + "type": "uint16" + }, + { + "indexed": false, + "internalType": "enum ProtocolShareReserve.Schema", + "name": "schema", + "type": "uint8" + } + ], + "name": "DistributionConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "destination", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint16", + "name": "percentage", + "type": "uint16" + }, + { + "indexed": false, + "internalType": "enum ProtocolShareReserve.Schema", + "name": "schema", + "type": "uint8" + } + ], + "name": "DistributionConfigRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "destination", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint16", + "name": "oldPercentage", + "type": "uint16" + }, + { + "indexed": false, + "internalType": "uint16", + "name": "newPercentage", + "type": "uint16" + }, + { + "indexed": false, + "internalType": "enum ProtocolShareReserve.Schema", + "name": "schema", + "type": "uint8" + } + ], + "name": "DistributionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMaxLoopsLimit", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newmaxLoopsLimit", + "type": "uint256" + } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldPoolRegistry", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newPoolRegistry", + "type": "address" + } + ], + "name": "PoolRegistryUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "enum ProtocolShareReserve.Schema", + "name": "schema", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldBalance", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newBalance", + "type": "uint256" + } + ], + "name": "ReservesUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "CORE_POOL_COMPTROLLER", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MAX_PERCENT", + "outputs": [ + { + "internalType": "uint16", + "name": "", + "type": "uint16" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WBNB", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "enum ProtocolShareReserve.Schema", + "name": "schema", + "type": "uint8" + }, + { + "internalType": "uint16", + "name": "percentage", + "type": "uint16" + }, + { + "internalType": "address", + "name": "destination", + "type": "address" + } + ], + "internalType": "struct ProtocolShareReserve.DistributionConfig[]", + "name": "configs", + "type": "tuple[]" + } + ], + "name": "addOrUpdateDistributionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "enum ProtocolShareReserve.Schema", + "name": "", + "type": "uint8" + } + ], + "name": "assetsReserves", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "distributionTargets", + "outputs": [ + { + "internalType": "enum ProtocolShareReserve.Schema", + "name": "schema", + "type": "uint8" + }, + { + "internalType": "uint16", + "name": "percentage", + "type": "uint16" + }, + { + "internalType": "address", + "name": "destination", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "destination", + "type": "address" + }, + { + "internalType": "enum ProtocolShareReserve.Schema", + "name": "schema", + "type": "uint8" + } + ], + "name": "getPercentageDistribution", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "internalType": "enum ProtocolShareReserve.Schema", + "name": "schema", + "type": "uint8" + }, + { + "internalType": "address", + "name": "destination", + "type": "address" + }, + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getUnreleasedFunds", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_accessControlManager", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_loopsLimit", + "type": "uint256" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "internalType": "address[]", + "name": "assets", + "type": "address[]" + } + ], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "enum ProtocolShareReserve.Schema", + "name": "schema", + "type": "uint8" + }, + { + "internalType": "address", + "name": "destination", + "type": "address" + } + ], + "name": "removeDistributionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_poolRegistry", + "type": "address" + } + ], + "name": "setPoolRegistry", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "totalAssetReserve", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalDistributions", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum IProtocolShareReserve.IncomeType", + "name": "incomeType", + "type": "uint8" + } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBNB", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-016/abi/SingleTokenConverter.json b/multisig/simulations/arbitrumsepolia/vip-016/abi/SingleTokenConverter.json new file mode 100644 index 000000000..c8d0f7077 --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-016/abi/SingleTokenConverter.json @@ -0,0 +1,1381 @@ +[ + { + "inputs": [], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { + "inputs": [], + "name": "AmountInMismatched", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { + "inputs": [], + "name": "AmountOutMismatched", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionConfigNotEnabled", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionEnabledOnlyForPrivateConversions", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionTokensActive", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionTokensPaused", + "type": "error" + }, + { + "inputs": [], + "name": "DeflationaryTokenNotSupported", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxIncentive", + "type": "uint256" + } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { + "inputs": [], + "name": "InputLengthMisMatch", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientInputAmount", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientOutputAmount", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientPoolLiquidity", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidConverterNetwork", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidMinimumAmountToConvert", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidToAddress", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidTokenConfigAddresses", + "type": "error" + }, + { + "inputs": [], + "name": "NonZeroIncentiveForPrivateConversion", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroValueNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "AssetTransferredToDestination", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldBaseAsset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newBaseAsset", + "type": "address" + } + ], + "name": "BaseAssetUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldIncentive", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newIncentive", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + } + ], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + } + ], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldConverterNetwork", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "converterNetwork", + "type": "address" + } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldDestinationAddress", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "destinationAddress", + "type": "address" + } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMinAmountToConvert", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMinAmountToConvert", + "type": "uint256" + } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract ResilientOracle", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract ResilientOracle", + "name": "priceOracle", + "type": "address" + } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "token", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "tokenBalance", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "baseAsset", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "conversionConfigurations", + "outputs": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertExactTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertForExactTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [ + { + "internalType": "contract IConverterNetwork", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getAmountIn", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getAmountOut", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + }, + { + "internalType": "contract ResilientOracle", + "name": "priceOracle_", + "type": "address" + }, + { + "internalType": "address", + "name": "destinationAddress_", + "type": "address" + }, + { + "internalType": "address", + "name": "baseAsset_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "minAmountToConvert_", + "type": "uint256" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pauseConversion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [ + { + "internalType": "contract ResilientOracle", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "resumeConversion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "baseAsset_", + "type": "address" + } + ], + "name": "setBaseAsset", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address[]", + "name": "tokenAddressesOut", + "type": "address[]" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract IConverterNetwork", + "name": "converterNetwork_", + "type": "address" + } + ], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "destinationAddress_", + "type": "address" + } + ], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "minAmountToConvert_", + "type": "uint256" + } + ], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract ResilientOracle", + "name": "priceOracle_", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-016/abi/XVSVaultTreasury.json b/multisig/simulations/arbitrumsepolia/vip-016/abi/XVSVaultTreasury.json new file mode 100644 index 000000000..6f6f3cf38 --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-016/abi/XVSVaultTreasury.json @@ -0,0 +1,306 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "xvsAddress_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [], + "name": "InsufficientBalance", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroValueNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "xvsStore", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountMantissa", + "type": "uint256" + } + ], + "name": "FundsTransferredToXVSStore", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldXVSVault", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newXVSVault", + "type": "address" + } + ], + "name": "XVSVaultUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "XVS_ADDRESS", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountMantissa", + "type": "uint256" + } + ], + "name": "fundXVSVault", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + }, + { + "internalType": "address", + "name": "xvsVault_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "xvsVault_", + "type": "address" + } + ], + "name": "setXVSVault", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVault", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-016/index.ts b/multisig/simulations/arbitrumsepolia/vip-016/index.ts new file mode 100644 index 000000000..f99c6d4a7 --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-016/index.ts @@ -0,0 +1,207 @@ +/* eslint-disable @typescript-eslint/no-unused-vars */ +import { expect } from "chai"; +import { BigNumber, Contract, Signer } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { initMainnetUser } from "src/utils"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip016, { + COMPTROLLER_CORE, + PLP, + PROTOCOL_SHARE_RESERVE_PROXY, + VTREASURY, + XVS_VAULT_TREASURY, +} from "../../../proposals/arbitrumsepolia/vip-016"; +import { + CONVERTER_NETWORK, + USDC_PRIME_CONVERTER, + USDT_PRIME_CONVERTER, + XVS_VAULT_CONVERTER, + converters, +} from "../../../proposals/arbitrumsepolia/vip-016/Addresses"; +import CONVERTER_NETWORK_ABI from "./abi/ConverterNetwork.json"; +import ERC20_ABI from "./abi/ERC20.json"; +import PROTOCOL_SHARE_RESERVE_ABI from "./abi/ProtocolShareReserve.json"; +import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; +import XVS_VAULT_TREASURY_ABI from "./abi/XVSVaultTreasury.json"; + +const { arbitrumsepolia } = NETWORK_ADDRESSES; +const XVS = "0x877Dc896e7b13096D3827872e396927BbE704407"; +const XVS_VAULT = "0x407507DC2809D3aa31D54EcA3BEde5C5c4C8A17F"; +const USDT_HOLDER = "0x4e7ab1fD841E1387Df4c91813Ae03819C33D5bdB"; +const USDC_HOLDER = "0x4e7ab1fD841E1387Df4c91813Ae03819C33D5bdB"; +const USDT = "0xf3118a17863996B9F2A073c9A66Faaa664355cf8"; +const USDC = "0x86f096B1D970990091319835faF3Ee011708eAe8"; +forking(94312350, async () => { + const provider = ethers.provider; + let converterNetwork: Contract; + let xvsVaultTreasury: Contract; + let protocolShareReserve: Contract; + let usdtPrimeConverter: Contract; + let usdcPrimeConverter: Contract; + + before(async () => { + usdcPrimeConverter = new ethers.Contract(USDC_PRIME_CONVERTER, SINGLE_TOKEN_CONVERTER_ABI, provider); + usdtPrimeConverter = new ethers.Contract(USDT_PRIME_CONVERTER, SINGLE_TOKEN_CONVERTER_ABI, provider); + + converterNetwork = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); + protocolShareReserve = new ethers.Contract(PROTOCOL_SHARE_RESERVE_PROXY, PROTOCOL_SHARE_RESERVE_ABI, provider); + xvsVaultTreasury = new ethers.Contract(XVS_VAULT_TREASURY, XVS_VAULT_TREASURY_ABI, provider); + + await pretendExecutingVip(await vip016()); + }); + + describe("Owner checks", () => { + it("Timelock should be the owner of all converters", async () => { + for (const converter of converters) { + const Converter = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); + expect(await Converter.owner()).to.equal(arbitrumsepolia.GUARDIAN); + } + }); + + it("Timelock should be the owner of ConverterNetwork", async () => { + expect(await converterNetwork.owner()).to.equal(arbitrumsepolia.GUARDIAN); + }); + + it("Timelock should be the owner of XVSVaultTreasury", async () => { + expect(await xvsVaultTreasury.owner()).to.equal(arbitrumsepolia.GUARDIAN); + }); + }); + + describe("Generic checks", () => { + let usdt: Contract; + let usdc: Contract; + let user1: Signer; + let usdtHolder: Signer; + let usdcHolder: Signer; + let user1Address: string; + + const amount = parseUnits("1000", 6); + + before(async () => { + usdt = new ethers.Contract(USDT, ERC20_ABI, provider); + usdc = new ethers.Contract(USDC, ERC20_ABI, provider); + + [, user1] = await ethers.getSigners(); + user1Address = await user1.getAddress(); + + usdcHolder = await initMainnetUser(USDC_HOLDER, ethers.utils.parseEther("1")); + usdtHolder = await initMainnetUser(USDT_HOLDER, ethers.utils.parseEther("1")); + + await usdt.connect(usdtHolder).transfer(user1Address, amount); + await usdc.connect(usdcHolder).transfer(user1Address, amount); + }); + + it("PSR should have correct distribution configs", async () => { + const percentageDistributionConverters = [500, 500, 300, 700, 2000]; + expect(await protocolShareReserve.totalDistributions()).to.equal(8); + + for (let i = 0; i < 5; i++) { + expect(await protocolShareReserve.getPercentageDistribution(converters[i], 0)).to.equal( + percentageDistributionConverters[i], + ); + } + + expect(await protocolShareReserve.getPercentageDistribution(VTREASURY, 0)).to.equal(6000); + expect(await protocolShareReserve.getPercentageDistribution(VTREASURY, 1)).to.equal(8000); + expect(await protocolShareReserve.getPercentageDistribution(XVS_VAULT_CONVERTER, 1)).to.equal(2000); + }); + + it("XVSVaultTreasury should have correct state variables", async () => { + expect(await xvsVaultTreasury.XVS_ADDRESS()).to.equal(XVS); + expect(await xvsVaultTreasury.xvsVault()).to.equal(XVS_VAULT); + }); + + it("ConverterNetwork should contain all converters", async () => { + expect(await converterNetwork.getAllConverters()).to.deep.equal(converters); + }); + + it("Convert exact tokens should work correctly", async () => { + const amountInMantissa = amount.div(2); + await usdt.connect(usdtHolder).transfer(user1Address, amount); + await usdc.connect(usdtHolder).transfer(USDT_PRIME_CONVERTER, amount); + + const usdcBalanceOfUsdtPrimeConverterPrevious = await usdtPrimeConverter.balanceOf(USDC); + const usdtBalanceOfUsdtPrimePrevious = await usdt.balanceOf(PLP); + const usdtBalanceOfUserPrevious = await usdt.balanceOf(user1Address); + + const [, amountOutMantissa] = await usdtPrimeConverter + .connect(user1) + .callStatic.getUpdatedAmountOut(amountInMantissa, USDT, USDC); + + await usdt.connect(user1).approve(USDT_PRIME_CONVERTER, amountInMantissa); + await usdtPrimeConverter + .connect(user1) + .convertExactTokens(amountInMantissa, amountInMantissa.div(2), USDT, USDC, user1Address); + + expect(await usdt.balanceOf(user1Address)).to.equal(usdtBalanceOfUserPrevious.sub(amountInMantissa)); + expect(await usdtPrimeConverter.balanceOf(USDT)).to.equal(0); + expect(await usdtPrimeConverter.balanceOf(USDC)).to.equal( + usdcBalanceOfUsdtPrimeConverterPrevious.sub(amountOutMantissa), + ); + expect(await usdt.balanceOf(PLP)).to.equal(BigNumber.from(usdtBalanceOfUsdtPrimePrevious).add(amountInMantissa)); + }); + + it("ConvertForExactTokens should work properly", async () => { + await usdc.connect(usdcHolder).transfer(user1Address, amount); + await usdc.connect(user1).transfer(USDT_PRIME_CONVERTER, amount); + + const amountOutMantissa = amount.div(2); + const amountInMaxMantissa = amount; + await usdt.connect(usdtHolder).transfer(user1Address, amount); + + const usdcBalanceOfUsdtPrimeConverterPrevious = await usdtPrimeConverter.balanceOf(USDC); + const usdtBalanceOfUsdtPrimePrevious = await usdt.balanceOf(PLP); + const usdtBalanceOfUserPrevious = await usdt.balanceOf(user1Address); + + const [, amountInMantissa] = await usdtPrimeConverter.connect(user1).getAmountIn(amountOutMantissa, USDT, USDC); + + await usdt.connect(user1).approve(USDT_PRIME_CONVERTER, amount); + await usdtPrimeConverter + .connect(user1) + .convertForExactTokens(amountInMaxMantissa, amountOutMantissa, USDT, USDC, user1Address); + + expect(await usdt.balanceOf(user1Address)).to.equal(usdtBalanceOfUserPrevious.sub(amountInMantissa)); + expect(await usdtPrimeConverter.balanceOf(USDT)).to.equal(0); + expect(await usdtPrimeConverter.balanceOf(USDC)).to.equal( + usdcBalanceOfUsdtPrimeConverterPrevious.sub(amountOutMantissa), + ); + expect(await usdt.balanceOf(PLP)).to.equal(BigNumber.from(usdtBalanceOfUsdtPrimePrevious).add(amountInMantissa)); + }); + + it("Private conversion should occur on updateAssetsState", async () => { + const newAmount = amount.mul(2); + await usdc.connect(usdcHolder).transfer(user1Address, newAmount); + await usdt.connect(usdtHolder).transfer(user1Address, newAmount); + + const destinationAddressForUsdcConverter = await usdcPrimeConverter.destinationAddress(); + + await usdc.connect(user1).transfer(USDT_PRIME_CONVERTER, amount); + await usdtPrimeConverter.connect(user1).updateAssetsState(COMPTROLLER_CORE, USDC); + + const usdcBalanceUsdtPrimeConverterPrevious = await usdtPrimeConverter.balanceOf(USDC); + const usdtBalanceUsdtPrimePrevious = await usdt.balanceOf(PLP); + + const plpBalanceForUsdcPrevious = await usdc.balanceOf(destinationAddressForUsdcConverter); + await usdt.connect(user1).transfer(USDC_PRIME_CONVERTER, amount); + + // Private Conversion will occur + await usdcPrimeConverter.connect(user1).updateAssetsState(COMPTROLLER_CORE, USDT); + + const usdcBalanceUsdtPrimeConverterCurrent = await usdtPrimeConverter.balanceOf(USDC); + const usdtBalanceUsdtPrimeCurrent = await usdt.balanceOf(PLP); + + expect(usdtBalanceUsdtPrimeCurrent).to.equal(usdtBalanceUsdtPrimePrevious.add(amount)); + expect(usdcBalanceUsdtPrimeConverterCurrent).to.closeTo( + usdcBalanceUsdtPrimeConverterPrevious.sub(amount), + parseUnits("1", 7), + ); + expect(await usdc.balanceOf(destinationAddressForUsdcConverter)).to.closeTo( + plpBalanceForUsdcPrevious.add(amount), + parseUnits("1", 7), + ); + }); + }); +}); From 2c783d482efd8abf82f696f34c4fb2b90fed3e0b Mon Sep 17 00:00:00 2001 From: web3rover Date: Tue, 5 Nov 2024 16:41:34 +0400 Subject: [PATCH 094/178] fix: added bscmainnet vip --- simulations/vip-392/abi/VTokenCorePool.json | 688 ++++++++++++++++++++ simulations/vip-392/bscmainnet.ts | 39 ++ vips/vip-392/bscmainnet.ts | 37 ++ 3 files changed, 764 insertions(+) create mode 100644 simulations/vip-392/abi/VTokenCorePool.json create mode 100644 simulations/vip-392/bscmainnet.ts create mode 100644 vips/vip-392/bscmainnet.ts diff --git a/simulations/vip-392/abi/VTokenCorePool.json b/simulations/vip-392/abi/VTokenCorePool.json new file mode 100644 index 000000000..c0187a7ca --- /dev/null +++ b/simulations/vip-392/abi/VTokenCorePool.json @@ -0,0 +1,688 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address payable", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "implementation_", "type": "address" }, + { "internalType": "bytes", "name": "becomeImplementationData", "type": "bytes" } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "error", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "info", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "detail", "type": "uint256" } + ], + "name": "Failure", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAdmin", "type": "address" } + ], + "name": "NewAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ComptrollerInterface", + "name": "oldComptroller", + "type": "address" + }, + { "indexed": false, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldImplementation", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newImplementation", "type": "address" } + ], + "name": "NewImplementation", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldPendingAdmin", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newPendingAdmin", "type": "address" } + ], + "name": "NewPendingAdmin", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "admin", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { "payable": true, "stateMutability": "payable", "type": "fallback" }, + { + "constant": false, + "inputs": [], + "name": "_acceptAdmin", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "_addReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "_reduceReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" }], + "name": "_setComptroller", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "implementation_", "type": "address" }, + { "internalType": "bool", "name": "allowResign", "type": "bool" }, + { "internalType": "bytes", "name": "becomeImplementationData", "type": "bytes" } + ], + "name": "_setImplementation", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "_setInterestRateModel", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address payable", "name": "newPendingAdmin", "type": "address" }], + "name": "_setPendingAdmin", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "_setReserveFactor", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "bytes", "name": "data", "type": "bytes" }], + "name": "delegateToImplementation", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "bytes", "name": "data", "type": "bytes" }], + "name": "delegateToViewImplementation", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "pendingAdmin", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-392/bscmainnet.ts b/simulations/vip-392/bscmainnet.ts new file mode 100644 index 000000000..fea846aaa --- /dev/null +++ b/simulations/vip-392/bscmainnet.ts @@ -0,0 +1,39 @@ +import { expect } from "chai"; +import { ethers } from "hardhat"; +import { forking, testVip } from "src/vip-framework"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; + +import vip392, { VETH_LST_IRM, vETH_CORE_IRM, vETH_CORE, vETH_LST } from "../../vips/vip-392/bscmainnet"; +import VTOKEN_CORE_POOL_ABI from "./abi/VTokenCorePool.json"; + +forking(43743361, async () => { + const provider = ethers.provider; + + const vETHCore = new ethers.Contract(vETH_CORE, VTOKEN_CORE_POOL_ABI, provider); + const vETHLST = new ethers.Contract(vETH_LST, VTOKEN_CORE_POOL_ABI, provider); + + testVip("VIP-392", await vip392()); + + describe("Post-VIP behavior", async () => { + it("has the new interest rate model addresses", async () => { + expect(await vETHCore.interestRateModel()).to.equal(vETH_CORE_IRM); + expect(await vETHLST.interestRateModel()).to.equal(VETH_LST_IRM); + }); + + describe("new interest rate model parameters", async () => { + checkInterestRate(vETH_CORE_IRM, "vETH (Core)", { + base: "0", + multiplier: "0.03", + jump: "4.5", + kink: "0.9", + }); + + checkInterestRate(VETH_LST_IRM, "vETH (LST)", { + base: "0", + multiplier: "0.03", + jump: "4.5", + kink: "0.9", + }); + }); + }); +}); diff --git a/vips/vip-392/bscmainnet.ts b/vips/vip-392/bscmainnet.ts new file mode 100644 index 000000000..cd62439af --- /dev/null +++ b/vips/vip-392/bscmainnet.ts @@ -0,0 +1,37 @@ +import { ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const VETH_LST_IRM = "0x49a06B82b3c907AB140879F73f1d8dE262962c30"; +export const vETH_CORE_IRM = "0x3aa125788FC6b9F801772baEa887aA40328015e9"; +export const vETH_CORE = "0xf508fCD89b8bd15579dc79A6827cB4686A3592c8"; +export const vETH_LST = "0xeCCACF760FEA7943C5b0285BD09F601505A29c05"; + +const vip392 = () => { + const meta = { + version: "v2", + title: "VIP-392", + description: ``, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + + return makeProposal( + [ + { + target: vETH_CORE, + signature: "_setInterestRateModel(address)", + params: [vETH_CORE_IRM], + }, + { + target: vETH_LST, + signature: "setInterestRateModel(address)", + params: [VETH_LST_IRM], + }, + ], + meta, + ProposalType.FAST_TRACK, + ); +}; + +export default vip392; From 6925357b3e3fe15cd7cf05db8a9e1b89451f781d Mon Sep 17 00:00:00 2001 From: web3rover Date: Tue, 5 Nov 2024 16:50:34 +0400 Subject: [PATCH 095/178] fix: added ethereum vip --- multisig/proposals/ethereum/vip-068/index.ts | 22 + .../ethereum/vip-068/abi/vToken.json | 861 ++++++++++++++++++ .../simulations/ethereum/vip-068/index.ts | 47 + 3 files changed, 930 insertions(+) create mode 100644 multisig/proposals/ethereum/vip-068/index.ts create mode 100644 multisig/simulations/ethereum/vip-068/abi/vToken.json create mode 100644 multisig/simulations/ethereum/vip-068/index.ts diff --git a/multisig/proposals/ethereum/vip-068/index.ts b/multisig/proposals/ethereum/vip-068/index.ts new file mode 100644 index 000000000..af2e51ad0 --- /dev/null +++ b/multisig/proposals/ethereum/vip-068/index.ts @@ -0,0 +1,22 @@ +import { makeProposal } from "../../../../src/utils"; + +export const vETH_CORE = "0x7c8ff7d2A1372433726f879BD945fFb250B94c65"; +export const vETH_LST = "0xc82780Db1257C788F262FBbDA960B3706Dfdcaf2"; +export const IRM = "0x2F81dAA9de0fD60fb9B105Cfc5b67A31Fda547b6"; + +export const vip068 = () => { + return makeProposal([ + { + target: vETH_CORE, + signature: "setInterestRateModel(address)", + params: [IRM], + }, + { + target: vETH_LST, + signature: "setInterestRateModel(address)", + params: [IRM], + }, + ]); +}; + +export default vip068; diff --git a/multisig/simulations/ethereum/vip-068/abi/vToken.json b/multisig/simulations/ethereum/vip-068/abi/vToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/multisig/simulations/ethereum/vip-068/abi/vToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-068/index.ts b/multisig/simulations/ethereum/vip-068/index.ts new file mode 100644 index 000000000..13c1924de --- /dev/null +++ b/multisig/simulations/ethereum/vip-068/index.ts @@ -0,0 +1,47 @@ +import { expect } from "chai"; +import { BigNumber } from "ethers"; +import { Contract } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; + +import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; +import { vip068, IRM, vETH_CORE, vETH_LST } from "../../../proposals/ethereum/vip-068"; +import VTOKEN_ABI from "./abi/vToken.json"; + +forking(21121545, async () => { + let vETHCore: Contract; + let vETHLST: Contract; + + before(async () => { + vETHCore = await ethers.getContractAt(VTOKEN_ABI, vETH_CORE); + vETHLST = await ethers.getContractAt(VTOKEN_ABI, vETH_LST); + }); + + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip068()); + }); + + it("check it correctly sets new interest rate model", async () => { + const BLOCKS_PER_YEAR = BigNumber.from(2628000); + + let interestRateModel = await vETHCore.interestRateModel(); + expect(interestRateModel).to.equal(IRM); + interestRateModel = await vETHLST.interestRateModel(); + expect(interestRateModel).to.equal(IRM); + + checkInterestRate( + IRM, + "vETH", + { + base: "0", + multiplier: "0.03", + jump: "4.5", + kink: "0.9", + }, + BLOCKS_PER_YEAR, + ); + }); + }); +}); From 32f430b43c344182efbfcfa830255d2ebc96a89b Mon Sep 17 00:00:00 2001 From: web3rover Date: Tue, 5 Nov 2024 16:55:18 +0400 Subject: [PATCH 096/178] fix: added arbitrum vip --- .../proposals/arbitrumone/vip-018/index.ts | 22 + .../arbitrumone/vip-018/abi/vToken.json | 861 ++++++++++++++++++ .../simulations/arbitrumone/vip-018/index.ts | 47 + 3 files changed, 930 insertions(+) create mode 100644 multisig/proposals/arbitrumone/vip-018/index.ts create mode 100644 multisig/simulations/arbitrumone/vip-018/abi/vToken.json create mode 100644 multisig/simulations/arbitrumone/vip-018/index.ts diff --git a/multisig/proposals/arbitrumone/vip-018/index.ts b/multisig/proposals/arbitrumone/vip-018/index.ts new file mode 100644 index 000000000..fd1ed0334 --- /dev/null +++ b/multisig/proposals/arbitrumone/vip-018/index.ts @@ -0,0 +1,22 @@ +import { makeProposal } from "../../../../src/utils"; + +export const vETH_CORE = "0x68a34332983f4Bf866768DD6D6E638b02eF5e1f0"; +export const vETH_LST = "0x39D6d13Ea59548637104E40e729E4aABE27FE106"; +export const IRM = "0x425dde630be832195619a06175ba45C827Dd3DCa"; + +export const vip018 = () => { + return makeProposal([ + { + target: vETH_CORE, + signature: "setInterestRateModel(address)", + params: [IRM], + }, + { + target: vETH_LST, + signature: "setInterestRateModel(address)", + params: [IRM], + }, + ]); +}; + +export default vip018; diff --git a/multisig/simulations/arbitrumone/vip-018/abi/vToken.json b/multisig/simulations/arbitrumone/vip-018/abi/vToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-018/abi/vToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-018/index.ts b/multisig/simulations/arbitrumone/vip-018/index.ts new file mode 100644 index 000000000..939b1e09d --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-018/index.ts @@ -0,0 +1,47 @@ +import { expect } from "chai"; +import { BigNumber } from "ethers"; +import { Contract } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; + +import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; +import { vip018, IRM, vETH_CORE, vETH_LST } from "../../../proposals/arbitrumone/vip-018"; +import VTOKEN_ABI from "./abi/vToken.json"; + +forking(271293785, async () => { + let vETHCore: Contract; + let vETHLST: Contract; + + before(async () => { + vETHCore = await ethers.getContractAt(VTOKEN_ABI, vETH_CORE); + vETHLST = await ethers.getContractAt(VTOKEN_ABI, vETH_LST); + }); + + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip018()); + }); + + it("check it correctly sets new interest rate model", async () => { + const BLOCKS_PER_YEAR = BigNumber.from("31536000"); // equal to seconds in a year as it is timebased deployment + + let interestRateModel = await vETHCore.interestRateModel(); + expect(interestRateModel).to.equal(IRM); + interestRateModel = await vETHLST.interestRateModel(); + expect(interestRateModel).to.equal(IRM); + + checkInterestRate( + IRM, + "vETH", + { + base: "0", + multiplier: "0.03", + jump: "4.5", + kink: "0.9", + }, + BLOCKS_PER_YEAR, + ); + }); + }); +}); From 47617675f83e61b8fa94c7a6183f58967b3f1e96 Mon Sep 17 00:00:00 2001 From: web3rover Date: Tue, 5 Nov 2024 17:01:54 +0400 Subject: [PATCH 097/178] fix: added opbnb vip --- .../proposals/opbnbmainnet/vip-024/index.ts | 16 + .../opbnbmainnet/vip-024/abi/vToken.json | 861 ++++++++++++++++++ .../simulations/opbnbmainnet/vip-024/index.ts | 43 + 3 files changed, 920 insertions(+) create mode 100644 multisig/proposals/opbnbmainnet/vip-024/index.ts create mode 100644 multisig/simulations/opbnbmainnet/vip-024/abi/vToken.json create mode 100644 multisig/simulations/opbnbmainnet/vip-024/index.ts diff --git a/multisig/proposals/opbnbmainnet/vip-024/index.ts b/multisig/proposals/opbnbmainnet/vip-024/index.ts new file mode 100644 index 000000000..d251815b1 --- /dev/null +++ b/multisig/proposals/opbnbmainnet/vip-024/index.ts @@ -0,0 +1,16 @@ +import { makeProposal } from "../../../../src/utils"; + +export const vETH_CORE = "0x509e81eF638D489936FA85BC58F52Df01190d26C"; +export const IRM = "0x0d75544019e3015eEbF61F26595D08d60f3aC841"; + +export const vip024 = () => { + return makeProposal([ + { + target: vETH_CORE, + signature: "setInterestRateModel(address)", + params: [IRM], + }, + ]); +}; + +export default vip024; diff --git a/multisig/simulations/opbnbmainnet/vip-024/abi/vToken.json b/multisig/simulations/opbnbmainnet/vip-024/abi/vToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-024/abi/vToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/opbnbmainnet/vip-024/index.ts b/multisig/simulations/opbnbmainnet/vip-024/index.ts new file mode 100644 index 000000000..732af7bdf --- /dev/null +++ b/multisig/simulations/opbnbmainnet/vip-024/index.ts @@ -0,0 +1,43 @@ +import { expect } from "chai"; +import { BigNumber } from "ethers"; +import { Contract } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; + +import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; +import { vip024, IRM, vETH_CORE } from "../../../proposals/opbnbmainnet/vip-024"; +import VTOKEN_ABI from "./abi/vToken.json"; + +forking(39057882, async () => { + let vETHCore: Contract; + + before(async () => { + vETHCore = await ethers.getContractAt(VTOKEN_ABI, vETH_CORE); + }); + + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip024()); + }); + + it("check it correctly sets new interest rate model", async () => { + const BLOCKS_PER_YEAR = BigNumber.from("31536000"); + + let interestRateModel = await vETHCore.interestRateModel(); + expect(interestRateModel).to.equal(IRM); + + checkInterestRate( + IRM, + "vETH", + { + base: "0", + multiplier: "0.03", + jump: "4.5", + kink: "0.9", + }, + BLOCKS_PER_YEAR, + ); + }); + }); +}); From 0b152573bd0f1e154d5ca36931b912a35cecd16a Mon Sep 17 00:00:00 2001 From: web3rover Date: Tue, 5 Nov 2024 17:05:13 +0400 Subject: [PATCH 098/178] fix: fixed lint --- multisig/simulations/arbitrumone/vip-018/index.ts | 5 ++--- multisig/simulations/ethereum/vip-068/index.ts | 5 ++--- multisig/simulations/opbnbmainnet/vip-024/index.ts | 7 +++---- simulations/vip-392/bscmainnet.ts | 2 +- 4 files changed, 8 insertions(+), 11 deletions(-) diff --git a/multisig/simulations/arbitrumone/vip-018/index.ts b/multisig/simulations/arbitrumone/vip-018/index.ts index 939b1e09d..0fbbae7b2 100644 --- a/multisig/simulations/arbitrumone/vip-018/index.ts +++ b/multisig/simulations/arbitrumone/vip-018/index.ts @@ -1,12 +1,11 @@ import { expect } from "chai"; import { BigNumber } from "ethers"; import { Contract } from "ethers"; -import { parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; -import { vip018, IRM, vETH_CORE, vETH_LST } from "../../../proposals/arbitrumone/vip-018"; +import { IRM, vETH_CORE, vETH_LST, vip018 } from "../../../proposals/arbitrumone/vip-018"; import VTOKEN_ABI from "./abi/vToken.json"; forking(271293785, async () => { @@ -25,7 +24,7 @@ forking(271293785, async () => { it("check it correctly sets new interest rate model", async () => { const BLOCKS_PER_YEAR = BigNumber.from("31536000"); // equal to seconds in a year as it is timebased deployment - + let interestRateModel = await vETHCore.interestRateModel(); expect(interestRateModel).to.equal(IRM); interestRateModel = await vETHLST.interestRateModel(); diff --git a/multisig/simulations/ethereum/vip-068/index.ts b/multisig/simulations/ethereum/vip-068/index.ts index 13c1924de..fcfcaca98 100644 --- a/multisig/simulations/ethereum/vip-068/index.ts +++ b/multisig/simulations/ethereum/vip-068/index.ts @@ -1,12 +1,11 @@ import { expect } from "chai"; import { BigNumber } from "ethers"; import { Contract } from "ethers"; -import { parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; -import { vip068, IRM, vETH_CORE, vETH_LST } from "../../../proposals/ethereum/vip-068"; +import { IRM, vETH_CORE, vETH_LST, vip068 } from "../../../proposals/ethereum/vip-068"; import VTOKEN_ABI from "./abi/vToken.json"; forking(21121545, async () => { @@ -25,7 +24,7 @@ forking(21121545, async () => { it("check it correctly sets new interest rate model", async () => { const BLOCKS_PER_YEAR = BigNumber.from(2628000); - + let interestRateModel = await vETHCore.interestRateModel(); expect(interestRateModel).to.equal(IRM); interestRateModel = await vETHLST.interestRateModel(); diff --git a/multisig/simulations/opbnbmainnet/vip-024/index.ts b/multisig/simulations/opbnbmainnet/vip-024/index.ts index 732af7bdf..86ded067d 100644 --- a/multisig/simulations/opbnbmainnet/vip-024/index.ts +++ b/multisig/simulations/opbnbmainnet/vip-024/index.ts @@ -1,12 +1,11 @@ import { expect } from "chai"; import { BigNumber } from "ethers"; import { Contract } from "ethers"; -import { parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; -import { vip024, IRM, vETH_CORE } from "../../../proposals/opbnbmainnet/vip-024"; +import { IRM, vETH_CORE, vip024 } from "../../../proposals/opbnbmainnet/vip-024"; import VTOKEN_ABI from "./abi/vToken.json"; forking(39057882, async () => { @@ -23,8 +22,8 @@ forking(39057882, async () => { it("check it correctly sets new interest rate model", async () => { const BLOCKS_PER_YEAR = BigNumber.from("31536000"); - - let interestRateModel = await vETHCore.interestRateModel(); + + const interestRateModel = await vETHCore.interestRateModel(); expect(interestRateModel).to.equal(IRM); checkInterestRate( diff --git a/simulations/vip-392/bscmainnet.ts b/simulations/vip-392/bscmainnet.ts index fea846aaa..ff94da606 100644 --- a/simulations/vip-392/bscmainnet.ts +++ b/simulations/vip-392/bscmainnet.ts @@ -3,7 +3,7 @@ import { ethers } from "hardhat"; import { forking, testVip } from "src/vip-framework"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; -import vip392, { VETH_LST_IRM, vETH_CORE_IRM, vETH_CORE, vETH_LST } from "../../vips/vip-392/bscmainnet"; +import vip392, { VETH_LST_IRM, vETH_CORE, vETH_CORE_IRM, vETH_LST } from "../../vips/vip-392/bscmainnet"; import VTOKEN_CORE_POOL_ABI from "./abi/VTokenCorePool.json"; forking(43743361, async () => { From 769c469343c180cee4f46ca27d464b0c7ff682e8 Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Wed, 2 Oct 2024 13:20:07 +0300 Subject: [PATCH 099/178] feat: add sepolia VIP simulations for pufETH support --- multisig/proposals/sepolia/vip-100/index.ts | 116 ++ .../sepolia/vip-100/abi/PoolRegistry.json | 310 ++++ .../sepolia/vip-100/abi/ResilientOracle.json | 301 ++++ .../sepolia/vip-100/abi/comptroller.json | 1496 +++++++++++++++++ .../sepolia/vip-100/abi/erc20.json | 134 ++ .../sepolia/vip-100/abi/vToken.json | 861 ++++++++++ .../simulations/sepolia/vip-100/abi/weth.json | 125 ++ multisig/simulations/sepolia/vip-100/index.ts | 104 ++ 8 files changed, 3447 insertions(+) create mode 100644 multisig/proposals/sepolia/vip-100/index.ts create mode 100644 multisig/simulations/sepolia/vip-100/abi/PoolRegistry.json create mode 100644 multisig/simulations/sepolia/vip-100/abi/ResilientOracle.json create mode 100644 multisig/simulations/sepolia/vip-100/abi/comptroller.json create mode 100644 multisig/simulations/sepolia/vip-100/abi/erc20.json create mode 100644 multisig/simulations/sepolia/vip-100/abi/vToken.json create mode 100644 multisig/simulations/sepolia/vip-100/abi/weth.json create mode 100644 multisig/simulations/sepolia/vip-100/index.ts diff --git a/multisig/proposals/sepolia/vip-100/index.ts b/multisig/proposals/sepolia/vip-100/index.ts new file mode 100644 index 000000000..7ffff9a6f --- /dev/null +++ b/multisig/proposals/sepolia/vip-100/index.ts @@ -0,0 +1,116 @@ +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { makeProposal } from "src/utils"; + +const { sepolia } = NETWORK_ADDRESSES; + +const PUFETH = "0x6D9f78b57AEeB0543a3c3B32Cc038bFB14a4bA68"; +const PUFETH_VTOKEN = "0x1E4d64B7c6f1F71969E5137B5Ee8cBa9Ab9c9356"; +const LST_ETH_COMPTROLLER = "0xd79CeB8EF8188E44b7Eb899094e8A3A4d7A1e236"; +const REDUCE_RESERVES_BLOCK_DELTA = "7200"; + +const { POOL_REGISTRY, VTREASURY, REDSTONE_ORACLE, RESILIENT_ORACLE } = sepolia; + +export const marketSpec = { + vToken: { + address: PUFETH_VTOKEN, + name: "Venus pufETH (Liquid Staked ETH)", + symbol: "vpufETH_LiquidStakedETH", + underlying: { + address: PUFETH, + decimals: 18, + symbol: "pufETH", + }, + decimals: 8, + exchangeRate: parseUnits("1", 28), + comptroller: LST_ETH_COMPTROLLER, + }, + interestRateModel: { + address: "0x9404B140E5384326ef108B089EBDa71a7f23Cd55", + base: "0", + multiplier: "0.045", + jump: "2", + kink: "0.45", + }, + initialSupply: { + amount: parseUnits("5", 18), + vTokenReceiver: VTREASURY, + }, + riskParameters: { + supplyCap: parseUnits("3000", 18), + borrowCap: parseUnits("300", 18), + collateralFactor: parseUnits("0.8", 18), + liquidationThreshold: parseUnits("0.85", 18), + reserveFactor: parseUnits("0.2", 18), + protocolSeizeShare: parseUnits("0.01", 18), + }, +}; + +const pufETH_ONE_JUMP_REDSTONE_ORACLE = "0xB6aA35247097a2711CF4941DECD00b858124d959"; + +export const vip100 = () => { + return makeProposal([ + // Configure Oracle + { + target: REDSTONE_ORACLE, + signature: "setDirectPrice(address,uint256)", + params: [marketSpec.vToken.underlying.address, parseUnits("1", 18)], + }, + { + target: RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [ + marketSpec.vToken.underlying.address, + [pufETH_ONE_JUMP_REDSTONE_ORACLE, ethers.constants.AddressZero, ethers.constants.AddressZero], + [true, false, false], + ], + ], + }, + + // Add Market + { + target: marketSpec.vToken.underlying.address, + signature: "faucet(uint256)", + params: [marketSpec.initialSupply.amount], + }, + { + target: marketSpec.vToken.underlying.address, + signature: "approve(address,uint256)", + params: [POOL_REGISTRY, marketSpec.initialSupply.amount], + }, + { + target: marketSpec.vToken.address, + signature: "setReduceReservesBlockDelta(uint256)", + params: [REDUCE_RESERVES_BLOCK_DELTA], + }, + { + target: POOL_REGISTRY, + signature: "addMarket((address,uint256,uint256,uint256,address,uint256,uint256))", + params: [ + [ + marketSpec.vToken.address, + marketSpec.riskParameters.collateralFactor, + marketSpec.riskParameters.liquidationThreshold, + marketSpec.initialSupply.amount, + marketSpec.initialSupply.vTokenReceiver, + marketSpec.riskParameters.supplyCap, + marketSpec.riskParameters.borrowCap, + ], + ], + }, + { + target: marketSpec.vToken.underlying.address, + signature: "approve(address,uint256)", + params: [POOL_REGISTRY, 0], + }, + { + target: marketSpec.vToken.address, + signature: "setProtocolSeizeShare(uint256)", + params: [marketSpec.riskParameters.protocolSeizeShare], + }, + ]); +}; + +export default vip100; diff --git a/multisig/simulations/sepolia/vip-100/abi/PoolRegistry.json b/multisig/simulations/sepolia/vip-100/abi/PoolRegistry.json new file mode 100644 index 000000000..8f15277d2 --- /dev/null +++ b/multisig/simulations/sepolia/vip-100/abi/PoolRegistry.json @@ -0,0 +1,310 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "vTokenAddress", "type": "address" } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "oldMetadata", + "type": "tuple" + }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "newMetadata", + "type": "tuple" + } + ], + "name": "PoolMetadataUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "oldName", "type": "string" }, + { "indexed": false, "internalType": "string", "name": "newName", "type": "string" } + ], + "name": "PoolNameSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPool", + "name": "pool", + "type": "tuple" + } + ], + "name": "PoolRegistered", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "collateralFactor", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThreshold", "type": "uint256" }, + { "internalType": "uint256", "name": "initialSupply", "type": "uint256" }, + { "internalType": "address", "name": "vTokenReceiver", "type": "address" }, + { "internalType": "uint256", "name": "supplyCap", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCap", "type": "uint256" } + ], + "internalType": "struct PoolRegistry.AddMarketInput", + "name": "input", + "type": "tuple" + } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "contract Comptroller", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "closeFactor", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationIncentive", "type": "uint256" }, + { "internalType": "uint256", "name": "minLiquidatableCollateral", "type": "uint256" } + ], + "name": "addPool", + "outputs": [{ "internalType": "uint256", "name": "index", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getAllPools", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool[]", + "name": "", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "comptroller", "type": "address" }], + "name": "getPoolByComptroller", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPoolsSupportedByAsset", + "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "getVTokenForAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "comptroller", "type": "address" }], + "name": "getVenusPoolMetadata", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "metadata", + "outputs": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "string", "name": "name", "type": "string" } + ], + "name": "setPoolName", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "metadata_", + "type": "tuple" + } + ], + "name": "updatePoolMetadata", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-100/abi/ResilientOracle.json b/multisig/simulations/sepolia/vip-100/abi/ResilientOracle.json new file mode 100644 index 000000000..e2f944a9d --- /dev/null +++ b/multisig/simulations/sepolia/vip-100/abi/ResilientOracle.json @@ -0,0 +1,301 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "nativeMarketAddress", "type": "address" }, + { "internalType": "address", "name": "vaiAddress", "type": "address" }, + { "internalType": "contract BoundValidatorInterface", "name": "_boundValidator", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "role", "type": "uint256" }, + { "indexed": true, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "oracle", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "role", "type": "uint256" } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "mainOracle", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "pivotOracle", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "fallbackOracle", "type": "address" } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [{ "internalType": "contract BoundValidatorInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" } + ], + "name": "getOracle", + "outputs": [ + { "internalType": "address", "name": "oracle", "type": "address" }, + { "internalType": "bool", "name": "enabled", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getUnderlyingPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address", "name": "oracle", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-100/abi/comptroller.json b/multisig/simulations/sepolia/vip-100/abi/comptroller.json new file mode 100644 index 000000000..fafe7b35e --- /dev/null +++ b/multisig/simulations/sepolia/vip-100/abi/comptroller.json @@ -0,0 +1,1496 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "poolRegistry_", + "type": "address" + }, + { + "internalType": "address", + "name": "accessControl_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedLessThanOrEqualTo", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { + "inputs": [], + "name": "ComptrollerMismatch", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "collateralToSeize", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "availableCollateral", + "type": "uint256" + } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientLiquidity", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientShortfall", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidCollateralFactor", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidLiquidationThreshold", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedGreaterThan", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { + "inputs": [], + "name": "NonzeroBorrowBalance", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { + "inputs": [], + "name": "TooMuchRepay", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "expectedSender", + "type": "address" + }, + { + "internalType": "address", + "name": "actualSender", + "type": "address" + } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "bool", + "name": "pauseState", + "type": "bool" + } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newBorrowCap", + "type": "uint256" + } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldCloseFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldCollateralFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationIncentiveMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationThresholdMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMinLiquidatableCollateral", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "rewardsDistributor", + "type": "address" + } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSupplyCap", + "type": "uint256" + } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControl", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "accountAssets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "actionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract RewardsDistributor", + "name": "_rewardsDistributor", + "type": "address" + } + ], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "allMarkets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "borrowCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "checkMembership", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "vTokens", + "type": "address[]" + } + ], + "name": "enterMarkets", + "outputs": [ + { + "internalType": "uint256[]", + "name": "", + "type": "uint256[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenAddress", + "type": "address" + } + ], + "name": "exitMarket", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAssetsIn", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenModify", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [ + { + "internalType": "contract RewardsDistributor[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "rewardToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "supplySpeed", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowSpeed", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isDeprecated", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isMarketListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "components": [ + { + "internalType": "contract VToken", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokensToSeize", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "markets", + "outputs": [ + { + "internalType": "bool", + "name": "isListed", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "collateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidationThresholdMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [ + { + "internalType": "contract PriceOracle", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "skipLiquidityCheck", + "type": "bool" + } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "seizerContract", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "transferTokens", + "type": "uint256" + } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "marketsList", + "type": "address[]" + }, + { + "internalType": "enum ComptrollerStorage.Action[]", + "name": "actionsList", + "type": "uint8[]" + }, + { + "internalType": "bool", + "name": "paused", + "type": "bool" + } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newBorrowCaps", + "type": "uint256[]" + } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newSupplyCaps", + "type": "uint256[]" + } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract PriceOracle", + "name": "newOracle", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "supplyCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-100/abi/erc20.json b/multisig/simulations/sepolia/vip-100/abi/erc20.json new file mode 100644 index 000000000..3a509c9c4 --- /dev/null +++ b/multisig/simulations/sepolia/vip-100/abi/erc20.json @@ -0,0 +1,134 @@ +[ + { + "inputs": [ + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "name": "faucet", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "from", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-100/abi/vToken.json b/multisig/simulations/sepolia/vip-100/abi/vToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/multisig/simulations/sepolia/vip-100/abi/vToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/sepolia/vip-100/abi/weth.json b/multisig/simulations/sepolia/vip-100/abi/weth.json new file mode 100644 index 000000000..cf8da14a9 --- /dev/null +++ b/multisig/simulations/sepolia/vip-100/abi/weth.json @@ -0,0 +1,125 @@ +[ + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "src", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "guy", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "wad", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "dst", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "wad", "type": "uint256" } + ], + "name": "Deposit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "src", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "dst", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "wad", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "src", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "wad", "type": "uint256" } + ], + "name": "Withdrawal", + "type": "event" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "guy", "type": "address" }, + { "internalType": "uint256", "name": "wad", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "deposit", "outputs": [], "stateMutability": "payable", "type": "function" }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "wad", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "wad", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "wad", "type": "uint256" }], + "name": "withdraw", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "stateMutability": "payable", "type": "receive" } +] diff --git a/multisig/simulations/sepolia/vip-100/index.ts b/multisig/simulations/sepolia/vip-100/index.ts new file mode 100644 index 000000000..a2ce01fda --- /dev/null +++ b/multisig/simulations/sepolia/vip-100/index.ts @@ -0,0 +1,104 @@ +import { impersonateAccount, setBalance } from "@nomicfoundation/hardhat-network-helpers"; +import { expect } from "chai"; +import { BigNumber, Contract } from "ethers"; +import { parseEther, parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { initMainnetUser } from "src/utils"; +import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIsolatedPoolsComptrollers"; +import { checkRiskParameters } from "src/vip-framework/checks/checkRiskParameters"; +import { checkVToken } from "src/vip-framework/checks/checkVToken"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; +import { forking, pretendExecutingVip } from "src/vip-framework/index"; + +import vip100, { marketSpec } from "../../../proposals/sepolia/vip-100"; +import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; +import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; +import COMPTROLLER_ABI from "./abi/comptroller.json"; +import ERC20_ABI from "./abi/erc20.json"; +import VTOKEN_ABI from "./abi/vToken.json"; + +const { sepolia } = NETWORK_ADDRESSES; +const PROTOCOL_SHARE_RESERVE = "0xbea70755cc3555708ca11219adB0db4C80F6721B"; +const BLOCKS_PER_YEAR = BigNumber.from(2628000); + +const { POOL_REGISTRY, RESILIENT_ORACLE, GUARDIAN, VTREASURY, NORMAL_TIMELOCK } = sepolia; + +forking(6799700, async () => { + const resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, ethers.provider); + const poolRegistry = new ethers.Contract(POOL_REGISTRY, POOL_REGISTRY_ABI, ethers.provider); + const vToken = new ethers.Contract(marketSpec.vToken.address, VTOKEN_ABI, ethers.provider); + const comptroller = new ethers.Contract(marketSpec.vToken.comptroller, COMPTROLLER_ABI, ethers.provider); + const underlying = new ethers.Contract(marketSpec.vToken.underlying.address, ERC20_ABI, ethers.provider); + + describe("Pre-VIP behavior", () => { + it("check price", async () => { + await expect(resilientOracle.getPrice(marketSpec.vToken.underlying.address)).to.be.reverted; + }); + + it("should have 8 markets in liquid staked pool", async () => { + const poolVTokens = await comptroller.getAllMarkets(); + expect(poolVTokens).to.have.lengthOf(8); + }); + }); + + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip100()); + }); + + it("check price", async () => { + expect(await resilientOracle.getPrice(marketSpec.vToken.underlying.address)).to.be.closeTo( + parseUnits("2484.93914048", 18), + parseUnits("1", 18), + ); + expect(await resilientOracle.getUnderlyingPrice(marketSpec.vToken.address)).to.be.closeTo( + parseUnits("2484.93914048", 18), + parseUnits("1", 18), + ); + }); + + it("should have 9 markets in liquid staked pool", async () => { + const poolVTokens = await comptroller.getAllMarkets(); + expect(poolVTokens).to.have.lengthOf(9); + }); + + it(`should add ${marketSpec.vToken.symbol} to the pool`, async () => { + const registeredVToken = await poolRegistry.getVTokenForAsset( + comptroller.address, + marketSpec.vToken.underlying.address, + ); + expect(registeredVToken).to.equal(marketSpec.vToken.address); + }); + + it("check ownership", async () => { + expect(await vToken.owner()).to.equal(GUARDIAN); + }); + + it("check supply", async () => { + const expectedSupply = parseUnits("5", 8); + expect(await vToken.balanceOf(VTREASURY)).to.equal(expectedSupply); + }); + + it("has correct protocol share reserve", async () => { + expect(await vToken.protocolShareReserve()).equals(PROTOCOL_SHARE_RESERVE); + }); + + checkRiskParameters(marketSpec.vToken.address, marketSpec.vToken, marketSpec.riskParameters); + checkVToken(marketSpec.vToken.address, marketSpec.vToken); + checkInterestRate( + marketSpec.interestRateModel.address, + marketSpec.vToken.symbol, + marketSpec.interestRateModel, + BLOCKS_PER_YEAR, + ); + + it("check Pool", async () => { + const timelock = await initMainnetUser(NORMAL_TIMELOCK, parseEther("5")); + await underlying.connect(timelock).faucet(parseUnits("100", 18)); + checkIsolatedPoolsComptrollers({ + [marketSpec.vToken.comptroller]: NORMAL_TIMELOCK, + }); + }); + }); +}); From 43c319fd69f778a2d163322083f4d7bd2cebada4 Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Thu, 3 Oct 2024 11:55:16 +0300 Subject: [PATCH 100/178] fixup! feat: add sepolia VIP simulations for pufETH support --- multisig/simulations/sepolia/vip-100/index.ts | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/multisig/simulations/sepolia/vip-100/index.ts b/multisig/simulations/sepolia/vip-100/index.ts index a2ce01fda..842589b68 100644 --- a/multisig/simulations/sepolia/vip-100/index.ts +++ b/multisig/simulations/sepolia/vip-100/index.ts @@ -1,6 +1,5 @@ -import { impersonateAccount, setBalance } from "@nomicfoundation/hardhat-network-helpers"; import { expect } from "chai"; -import { BigNumber, Contract } from "ethers"; +import { BigNumber } from "ethers"; import { parseEther, parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; @@ -24,7 +23,7 @@ const BLOCKS_PER_YEAR = BigNumber.from(2628000); const { POOL_REGISTRY, RESILIENT_ORACLE, GUARDIAN, VTREASURY, NORMAL_TIMELOCK } = sepolia; -forking(6799700, async () => { +forking(6805700, async () => { const resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, ethers.provider); const poolRegistry = new ethers.Contract(POOL_REGISTRY, POOL_REGISTRY_ABI, ethers.provider); const vToken = new ethers.Contract(marketSpec.vToken.address, VTOKEN_ABI, ethers.provider); @@ -49,11 +48,11 @@ forking(6799700, async () => { it("check price", async () => { expect(await resilientOracle.getPrice(marketSpec.vToken.underlying.address)).to.be.closeTo( - parseUnits("2484.93914048", 18), + parseUnits("2368.35", 18), parseUnits("1", 18), ); expect(await resilientOracle.getUnderlyingPrice(marketSpec.vToken.address)).to.be.closeTo( - parseUnits("2484.93914048", 18), + parseUnits("2368.35", 18), parseUnits("1", 18), ); }); From 299938135bfcaf80a1609bf0809d55329a0bf154 Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 6 Nov 2024 15:41:23 +0400 Subject: [PATCH 101/178] fix: coverted to multichain vip --- multisig/proposals/ethereum/vip-067/index.ts | 114 -- .../ethereum/vip-067/abi/PoolRegistry.json | 310 ---- .../ethereum/vip-067/abi/PrimeConverter.json | 587 ------- .../ethereum/vip-067/abi/ResilientOracle.json | 301 ---- .../ethereum/vip-067/abi/comptroller.json | 1496 ----------------- .../ethereum/vip-067/abi/erc20.json | 134 -- .../ethereum/vip-067/abi/vToken.json | 861 ---------- .../simulations/ethereum/vip-067/index.ts | 161 -- 8 files changed, 3964 deletions(-) delete mode 100644 multisig/proposals/ethereum/vip-067/index.ts delete mode 100644 multisig/simulations/ethereum/vip-067/abi/PoolRegistry.json delete mode 100644 multisig/simulations/ethereum/vip-067/abi/PrimeConverter.json delete mode 100644 multisig/simulations/ethereum/vip-067/abi/ResilientOracle.json delete mode 100644 multisig/simulations/ethereum/vip-067/abi/comptroller.json delete mode 100644 multisig/simulations/ethereum/vip-067/abi/erc20.json delete mode 100644 multisig/simulations/ethereum/vip-067/abi/vToken.json delete mode 100644 multisig/simulations/ethereum/vip-067/index.ts diff --git a/multisig/proposals/ethereum/vip-067/index.ts b/multisig/proposals/ethereum/vip-067/index.ts deleted file mode 100644 index 1e54df982..000000000 --- a/multisig/proposals/ethereum/vip-067/index.ts +++ /dev/null @@ -1,114 +0,0 @@ -import { parseUnits } from "ethers/lib/utils"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; - -import { makeProposal } from "../../../../src/utils"; - -const { ethereum } = NETWORK_ADDRESSES; - -export const EIGEN = "0xec53bF9167f50cDEB3Ae105f56099aaaB9061F83"; -const INITIAL_SUPPLY = parseUnits("500", 18); -export const SUPPLY_CAP = parseUnits("3000000", 18); -export const BORROW_CAP = parseUnits("1500000", 18); -const CF = parseUnits("0.5", 18); -const LT = parseUnits("0.6", 18); -export const vEIGEN = "0x256AdDBe0a387c98f487e44b85c29eb983413c5e"; -export const CORE_COMPTROLLER = "0x687a01ecF6d3907658f7A7c714749fAC32336D1B"; - -export const USDT_PRIME_CONVERTER = "0x4f55cb0a24D5542a3478B0E284259A6B850B06BD"; -export const USDC_PRIME_CONVERTER = "0xcEB9503f10B781E30213c0b320bCf3b3cE54216E"; -export const WBTC_PRIME_CONVERTER = "0xDcCDE673Cd8988745dA384A7083B0bd22085dEA0"; -export const WETH_PRIME_CONVERTER = "0xb8fD67f215117FADeF06447Af31590309750529D"; -export const XVS_VAULT_CONVERTER = "0x1FD30e761C3296fE36D9067b1e398FD97B4C0407"; -export const BaseAssets = [ - "0xdAC17F958D2ee523a2206206994597C13D831ec7", // USDT USDTTokenConverter BaseAsset - "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48", // USDC USDCTokenConverter BaseAsset - "0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599", // WBTC WBTCTokenConverter BaseAsset - "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2", // WETH WETHTokenConverter BaseAsset - "0xd3CC9d8f3689B83c91b7B59cAB4946B063EB894A", // XVS XVSTokenConverter BaseAsset -]; -const CONVERSION_INCENTIVE = parseUnits("0.0001", 18); -const CHAINLINK_FEED = "0xf2917e602C2dCa458937fad715bb1E465305A4A1"; -const MAX_STALE_PERIOD = 30 * 3600; - -export const vip067 = () => { - return makeProposal([ - { - target: ethereum.CHAINLINK_ORACLE, - signature: "setTokenConfig((address,address,uint256))", - params: [[EIGEN, CHAINLINK_FEED, MAX_STALE_PERIOD]], - }, - { - target: ethereum.RESILIENT_ORACLE, - signature: "setTokenConfig((address,address[3],bool[3]))", - params: [ - [ - EIGEN, - [ethereum.CHAINLINK_ORACLE, ethers.constants.AddressZero, ethers.constants.AddressZero], - [true, false, false], - ], - ], - }, - - // Add Market - { - target: ethereum.VTREASURY, - signature: "withdrawTreasuryToken(address,uint256,address)", - params: [EIGEN, INITIAL_SUPPLY, ethereum.GUARDIAN], - }, - { - target: EIGEN, - signature: "approve(address,uint256)", - params: [ethereum.POOL_REGISTRY, 0], - }, - { - target: EIGEN, - signature: "approve(address,uint256)", - params: [ethereum.POOL_REGISTRY, INITIAL_SUPPLY], - }, - { - target: vEIGEN, - signature: "setReduceReservesBlockDelta(uint256)", - params: ["7200"], - }, - { - target: ethereum.POOL_REGISTRY, - signature: "addMarket((address,uint256,uint256,uint256,address,uint256,uint256))", - params: [[vEIGEN, CF, LT, INITIAL_SUPPLY, ethereum.VTREASURY, SUPPLY_CAP, BORROW_CAP]], - }, - { - target: vEIGEN, - signature: "setProtocolSeizeShare(uint256)", - params: [parseUnits("0.01", 18)], - }, - - // Conversion config - { - target: USDT_PRIME_CONVERTER, - signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[0], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], - }, - { - target: USDC_PRIME_CONVERTER, - signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[1], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], - }, - { - target: WBTC_PRIME_CONVERTER, - signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[2], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], - }, - { - target: WETH_PRIME_CONVERTER, - signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[3], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], - }, - { - target: XVS_VAULT_CONVERTER, - signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[4], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], - }, - ]); -}; - -export default vip067; diff --git a/multisig/simulations/ethereum/vip-067/abi/PoolRegistry.json b/multisig/simulations/ethereum/vip-067/abi/PoolRegistry.json deleted file mode 100644 index 8f15277d2..000000000 --- a/multisig/simulations/ethereum/vip-067/abi/PoolRegistry.json +++ /dev/null @@ -1,310 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "vTokenAddress", "type": "address" } - ], - "name": "MarketAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { - "components": [ - { "internalType": "string", "name": "category", "type": "string" }, - { "internalType": "string", "name": "logoURL", "type": "string" }, - { "internalType": "string", "name": "description", "type": "string" } - ], - "indexed": false, - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", - "name": "oldMetadata", - "type": "tuple" - }, - { - "components": [ - { "internalType": "string", "name": "category", "type": "string" }, - { "internalType": "string", "name": "logoURL", "type": "string" }, - { "internalType": "string", "name": "description", "type": "string" } - ], - "indexed": false, - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", - "name": "newMetadata", - "type": "tuple" - } - ], - "name": "PoolMetadataUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": false, "internalType": "string", "name": "oldName", "type": "string" }, - { "indexed": false, "internalType": "string", "name": "newName", "type": "string" } - ], - "name": "PoolNameSet", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { - "components": [ - { "internalType": "string", "name": "name", "type": "string" }, - { "internalType": "address", "name": "creator", "type": "address" }, - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, - { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } - ], - "indexed": false, - "internalType": "struct PoolRegistryInterface.VenusPool", - "name": "pool", - "type": "tuple" - } - ], - "name": "PoolRegistered", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "internalType": "uint256", "name": "collateralFactor", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidationThreshold", "type": "uint256" }, - { "internalType": "uint256", "name": "initialSupply", "type": "uint256" }, - { "internalType": "address", "name": "vTokenReceiver", "type": "address" }, - { "internalType": "uint256", "name": "supplyCap", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCap", "type": "uint256" } - ], - "internalType": "struct PoolRegistry.AddMarketInput", - "name": "input", - "type": "tuple" - } - ], - "name": "addMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "string", "name": "name", "type": "string" }, - { "internalType": "contract Comptroller", "name": "comptroller", "type": "address" }, - { "internalType": "uint256", "name": "closeFactor", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidationIncentive", "type": "uint256" }, - { "internalType": "uint256", "name": "minLiquidatableCollateral", "type": "uint256" } - ], - "name": "addPool", - "outputs": [{ "internalType": "uint256", "name": "index", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getAllPools", - "outputs": [ - { - "components": [ - { "internalType": "string", "name": "name", "type": "string" }, - { "internalType": "address", "name": "creator", "type": "address" }, - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, - { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool[]", - "name": "", - "type": "tuple[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "comptroller", "type": "address" }], - "name": "getPoolByComptroller", - "outputs": [ - { - "components": [ - { "internalType": "string", "name": "name", "type": "string" }, - { "internalType": "address", "name": "creator", "type": "address" }, - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, - { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool", - "name": "", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], - "name": "getPoolsSupportedByAsset", - "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "getVTokenForAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "comptroller", "type": "address" }], - "name": "getVenusPoolMetadata", - "outputs": [ - { - "components": [ - { "internalType": "string", "name": "category", "type": "string" }, - { "internalType": "string", "name": "logoURL", "type": "string" }, - { "internalType": "string", "name": "description", "type": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", - "name": "", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "metadata", - "outputs": [ - { "internalType": "string", "name": "category", "type": "string" }, - { "internalType": "string", "name": "logoURL", "type": "string" }, - { "internalType": "string", "name": "description", "type": "string" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "string", "name": "name", "type": "string" } - ], - "name": "setPoolName", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { - "components": [ - { "internalType": "string", "name": "category", "type": "string" }, - { "internalType": "string", "name": "logoURL", "type": "string" }, - { "internalType": "string", "name": "description", "type": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", - "name": "metadata_", - "type": "tuple" - } - ], - "name": "updatePoolMetadata", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-067/abi/PrimeConverter.json b/multisig/simulations/ethereum/vip-067/abi/PrimeConverter.json deleted file mode 100644 index 8ea10cc8d..000000000 --- a/multisig/simulations/ethereum/vip-067/abi/PrimeConverter.json +++ /dev/null @@ -1,587 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } - ], - "name": "AmountInHigherThanMax", - "type": "error" - }, - { "inputs": [], "name": "AmountInMismatched", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } - ], - "name": "AmountOutLowerThanMinRequired", - "type": "error" - }, - { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, - { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, - { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, - { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, - { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, - { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } - ], - "name": "IncentiveTooHigh", - "type": "error" - }, - { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, - { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, - { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, - { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, - { "inputs": [], "name": "InvalidToAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, - { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetTransferredToDestination", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } - ], - "name": "BaseAssetUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "oldAccess", - "type": "uint8" - }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "newAccess", - "type": "uint8" - } - ], - "name": "ConversionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } - ], - "name": "ConverterNetworkAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } - ], - "name": "DestinationAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } - ], - "name": "MinAmountToConvertUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, - { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } - ], - "name": "PriceOracleUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "inputs": [], - "name": "MAX_INCENTIVE", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "baseAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "conversionConfigurations", - "outputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "conversionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "converterNetwork", - "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "destinationAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, - { "internalType": "address", "name": "destinationAddress_", "type": "address" }, - { "internalType": "address", "name": "baseAsset_", "type": "address" }, - { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "minAmountToConvert", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "priceOracle", - "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], - "name": "setBaseAsset", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig", - "name": "conversionConfig", - "type": "tuple" - } - ], - "name": "setConversionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", - "name": "conversionConfigs", - "type": "tuple[]" - } - ], - "name": "setConversionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], - "name": "setConverterNetwork", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], - "name": "setDestination", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], - "name": "setMinAmountToConvert", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-067/abi/ResilientOracle.json b/multisig/simulations/ethereum/vip-067/abi/ResilientOracle.json deleted file mode 100644 index e2f944a9d..000000000 --- a/multisig/simulations/ethereum/vip-067/abi/ResilientOracle.json +++ /dev/null @@ -1,301 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "nativeMarketAddress", "type": "address" }, - { "internalType": "address", "name": "vaiAddress", "type": "address" }, - { "internalType": "contract BoundValidatorInterface", "name": "_boundValidator", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "role", "type": "uint256" }, - { "indexed": true, "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "OracleEnabled", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "oracle", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "role", "type": "uint256" } - ], - "name": "OracleSet", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "mainOracle", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "pivotOracle", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "fallbackOracle", "type": "address" } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "INVALID_PRICE", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_TOKEN_ADDR", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "boundValidator", - "outputs": [{ "internalType": "contract BoundValidatorInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" }, - { "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "enableOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" } - ], - "name": "getOracle", - "outputs": [ - { "internalType": "address", "name": "oracle", "type": "address" }, - { "internalType": "bool", "name": "enabled", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], - "name": "getPrice", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], - "name": "getTokenConfig", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, - { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "getUnderlyingPrice", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "nativeMarket", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "address", "name": "oracle", "type": "address" }, - { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" } - ], - "name": "setOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, - { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, - { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } - ], - "internalType": "struct ResilientOracle.TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], - "name": "updateAssetPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "updatePrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-067/abi/comptroller.json b/multisig/simulations/ethereum/vip-067/abi/comptroller.json deleted file mode 100644 index fafe7b35e..000000000 --- a/multisig/simulations/ethereum/vip-067/abi/comptroller.json +++ /dev/null @@ -1,1496 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "poolRegistry_", - "type": "address" - }, - { - "internalType": "address", - "name": "accessControl_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "market", - "type": "address" - }, - { - "internalType": "enum ComptrollerStorage.Action", - "name": "action", - "type": "uint8" - } - ], - "name": "ActionPaused", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "market", - "type": "address" - }, - { - "internalType": "uint256", - "name": "cap", - "type": "uint256" - } - ], - "name": "BorrowCapExceeded", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "expectedLessThanOrEqualTo", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "actual", - "type": "uint256" - } - ], - "name": "CollateralExceedsThreshold", - "type": "error" - }, - { - "inputs": [], - "name": "ComptrollerMismatch", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "collateralToSeize", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "availableCollateral", - "type": "uint256" - } - ], - "name": "InsufficientCollateral", - "type": "error" - }, - { - "inputs": [], - "name": "InsufficientLiquidity", - "type": "error" - }, - { - "inputs": [], - "name": "InsufficientShortfall", - "type": "error" - }, - { - "inputs": [], - "name": "InvalidCollateralFactor", - "type": "error" - }, - { - "inputs": [], - "name": "InvalidLiquidationThreshold", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "market", - "type": "address" - } - ], - "name": "MarketAlreadyListed", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "market", - "type": "address" - } - ], - "name": "MarketNotListed", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "expectedGreaterThan", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "actual", - "type": "uint256" - } - ], - "name": "MinimalCollateralViolated", - "type": "error" - }, - { - "inputs": [], - "name": "NonzeroBorrowBalance", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "PriceError", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "address", - "name": "user", - "type": "address" - } - ], - "name": "SnapshotError", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "market", - "type": "address" - }, - { - "internalType": "uint256", - "name": "cap", - "type": "uint256" - } - ], - "name": "SupplyCapExceeded", - "type": "error" - }, - { - "inputs": [], - "name": "TooMuchRepay", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "expectedSender", - "type": "address" - }, - { - "internalType": "address", - "name": "actualSender", - "type": "address" - } - ], - "name": "UnexpectedSender", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "enum ComptrollerStorage.Action", - "name": "action", - "type": "uint8" - }, - { - "indexed": false, - "internalType": "bool", - "name": "pauseState", - "type": "bool" - } - ], - "name": "ActionPausedMarket", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "MarketEntered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "MarketExited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - } - ], - "name": "MarketSupported", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newBorrowCap", - "type": "uint256" - } - ], - "name": "NewBorrowCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "oldCloseFactorMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newCloseFactorMantissa", - "type": "uint256" - } - ], - "name": "NewCloseFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "oldCollateralFactorMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newCollateralFactorMantissa", - "type": "uint256" - } - ], - "name": "NewCollateralFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "oldLiquidationIncentiveMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLiquidationIncentiveMantissa", - "type": "uint256" - } - ], - "name": "NewLiquidationIncentive", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "oldLiquidationThresholdMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLiquidationThresholdMantissa", - "type": "uint256" - } - ], - "name": "NewLiquidationThreshold", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "oldMinLiquidatableCollateral", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newMinLiquidatableCollateral", - "type": "uint256" - } - ], - "name": "NewMinLiquidatableCollateral", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract PriceOracle", - "name": "oldPriceOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "contract PriceOracle", - "name": "newPriceOracle", - "type": "address" - } - ], - "name": "NewPriceOracle", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "rewardsDistributor", - "type": "address" - } - ], - "name": "NewRewardsDistributor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newSupplyCap", - "type": "uint256" - } - ], - "name": "NewSupplyCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControl", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - }, - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "name": "accountAssets", - "outputs": [ - { - "internalType": "contract VToken", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "market", - "type": "address" - }, - { - "internalType": "enum ComptrollerStorage.Action", - "name": "action", - "type": "uint8" - } - ], - "name": "actionPaused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract RewardsDistributor", - "name": "_rewardsDistributor", - "type": "address" - } - ], - "name": "addRewardsDistributor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "name": "allMarkets", - "outputs": [ - { - "internalType": "contract VToken", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "borrowCaps", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - } - ], - "name": "checkMembership", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "closeFactorMantissa", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address[]", - "name": "vTokens", - "type": "address[]" - } - ], - "name": "enterMarkets", - "outputs": [ - { - "internalType": "uint256[]", - "name": "", - "type": "uint256[]" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vTokenAddress", - "type": "address" - } - ], - "name": "exitMarket", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "getAccountLiquidity", - "outputs": [ - { - "internalType": "uint256", - "name": "error", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "liquidity", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "shortfall", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [ - { - "internalType": "contract VToken[]", - "name": "", - "type": "address[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "getAssetsIn", - "outputs": [ - { - "internalType": "contract VToken[]", - "name": "", - "type": "address[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "internalType": "address", - "name": "vTokenModify", - "type": "address" - }, - { - "internalType": "uint256", - "name": "redeemTokens", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "borrowAmount", - "type": "uint256" - } - ], - "name": "getHypotheticalAccountLiquidity", - "outputs": [ - { - "internalType": "uint256", - "name": "error", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "liquidity", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "shortfall", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getRewardDistributors", - "outputs": [ - { - "internalType": "contract RewardsDistributor[]", - "name": "", - "type": "address[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getRewardsByMarket", - "outputs": [ - { - "components": [ - { - "internalType": "address", - "name": "rewardToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "supplySpeed", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "borrowSpeed", - "type": "uint256" - } - ], - "internalType": "struct ComptrollerStorage.RewardSpeeds[]", - "name": "rewardSpeeds", - "type": "tuple[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user", - "type": "address" - } - ], - "name": "healAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isComptroller", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - } - ], - "name": "isDeprecated", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - } - ], - "name": "isMarketListed", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "borrower", - "type": "address" - }, - { - "components": [ - { - "internalType": "contract VToken", - "name": "vTokenCollateral", - "type": "address" - }, - { - "internalType": "contract VToken", - "name": "vTokenBorrowed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "repayAmount", - "type": "uint256" - } - ], - "internalType": "struct ComptrollerStorage.LiquidationOrder[]", - "name": "orders", - "type": "tuple[]" - } - ], - "name": "liquidateAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vTokenBorrowed", - "type": "address" - }, - { - "internalType": "address", - "name": "vTokenCollateral", - "type": "address" - }, - { - "internalType": "uint256", - "name": "actualRepayAmount", - "type": "uint256" - } - ], - "name": "liquidateCalculateSeizeTokens", - "outputs": [ - { - "internalType": "uint256", - "name": "error", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "tokensToSeize", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "liquidationIncentiveMantissa", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "markets", - "outputs": [ - { - "internalType": "bool", - "name": "isListed", - "type": "bool" - }, - { - "internalType": "uint256", - "name": "collateralFactorMantissa", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "liquidationThresholdMantissa", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "minLiquidatableCollateral", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [ - { - "internalType": "contract PriceOracle", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "address", - "name": "borrower", - "type": "address" - }, - { - "internalType": "uint256", - "name": "borrowAmount", - "type": "uint256" - } - ], - "name": "preBorrowHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vTokenBorrowed", - "type": "address" - }, - { - "internalType": "address", - "name": "vTokenCollateral", - "type": "address" - }, - { - "internalType": "address", - "name": "borrower", - "type": "address" - }, - { - "internalType": "uint256", - "name": "repayAmount", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "skipLiquidityCheck", - "type": "bool" - } - ], - "name": "preLiquidateHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "internalType": "uint256", - "name": "mintAmount", - "type": "uint256" - } - ], - "name": "preMintHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "address", - "name": "redeemer", - "type": "address" - }, - { - "internalType": "uint256", - "name": "redeemTokens", - "type": "uint256" - } - ], - "name": "preRedeemHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "address", - "name": "borrower", - "type": "address" - } - ], - "name": "preRepayHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vTokenCollateral", - "type": "address" - }, - { - "internalType": "address", - "name": "seizerContract", - "type": "address" - }, - { - "internalType": "address", - "name": "liquidator", - "type": "address" - }, - { - "internalType": "address", - "name": "borrower", - "type": "address" - } - ], - "name": "preSeizeHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "address", - "name": "src", - "type": "address" - }, - { - "internalType": "address", - "name": "dst", - "type": "address" - }, - { - "internalType": "uint256", - "name": "transferTokens", - "type": "uint256" - } - ], - "name": "preTransferHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VToken[]", - "name": "marketsList", - "type": "address[]" - }, - { - "internalType": "enum ComptrollerStorage.Action[]", - "name": "actionsList", - "type": "uint8[]" - }, - { - "internalType": "bool", - "name": "paused", - "type": "bool" - } - ], - "name": "setActionsPaused", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "newCloseFactorMantissa", - "type": "uint256" - } - ], - "name": "setCloseFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "newCollateralFactorMantissa", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "newLiquidationThresholdMantissa", - "type": "uint256" - } - ], - "name": "setCollateralFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "newLiquidationIncentiveMantissa", - "type": "uint256" - } - ], - "name": "setLiquidationIncentive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VToken[]", - "name": "vTokens", - "type": "address[]" - }, - { - "internalType": "uint256[]", - "name": "newBorrowCaps", - "type": "uint256[]" - } - ], - "name": "setMarketBorrowCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VToken[]", - "name": "vTokens", - "type": "address[]" - }, - { - "internalType": "uint256[]", - "name": "newSupplyCaps", - "type": "uint256[]" - } - ], - "name": "setMarketSupplyCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "newMinLiquidatableCollateral", - "type": "uint256" - } - ], - "name": "setMinLiquidatableCollateral", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract PriceOracle", - "name": "newOracle", - "type": "address" - } - ], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "supplyCaps", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - } - ], - "name": "supportMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-067/abi/erc20.json b/multisig/simulations/ethereum/vip-067/abi/erc20.json deleted file mode 100644 index 3a509c9c4..000000000 --- a/multisig/simulations/ethereum/vip-067/abi/erc20.json +++ /dev/null @@ -1,134 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "string", "name": "name_", "type": "string" }, - { "internalType": "string", "name": "symbol_", "type": "string" }, - { "internalType": "uint8", "name": "decimals_", "type": "uint8" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } - ], - "name": "Transfer", - "type": "event" - }, - { - "inputs": [ - { "internalType": "address", "name": "owner", "type": "address" }, - { "internalType": "address", "name": "spender", "type": "address" } - ], - "name": "allowance", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "approve", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } - ], - "name": "decreaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], - "name": "faucet", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "addedValue", "type": "uint256" } - ], - "name": "increaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "to", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transfer", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "from", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transferFrom", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-067/abi/vToken.json b/multisig/simulations/ethereum/vip-067/abi/vToken.json deleted file mode 100644 index d8cc1aae4..000000000 --- a/multisig/simulations/ethereum/vip-067/abi/vToken.json +++ /dev/null @@ -1,861 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], - "name": "AddReservesFactorFreshCheck", - "type": "error" - }, - { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, - { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, - { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], - "name": "LiquidateAccrueCollateralInterestFailed", - "type": "error" - }, - { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, - { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, - { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, - { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, - { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, - { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, - { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "AccrueInterest", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtRecovered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "Borrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "HealBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "LiquidateBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } - ], - "name": "NewComptroller", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "oldInterestRateModel", - "type": "address" - }, - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "newInterestRateModel", - "type": "address" - } - ], - "name": "NewMarketInterestRateModel", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } - ], - "name": "NewProtocolSeizeShare", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } - ], - "name": "NewProtocolShareReserve", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } - ], - "name": "NewReduceReservesBlockDelta", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } - ], - "name": "NewReserveFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } - ], - "name": "NewShortfallContract", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ProtocolSeize", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Redeem", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "RepayBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "ReservesAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "SpreadReservesReduced", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Transfer", - "type": "event" - }, - { - "inputs": [], - "name": "NO_ERROR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrualBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrueInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], - "name": "addReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "owner", "type": "address" }, - { "internalType": "address", "name": "spender", "type": "address" } - ], - "name": "allowance", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "approve", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "badDebt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], - "name": "badDebtRecovered", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOfUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], - "name": "borrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "borrowIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "borrowRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } - ], - "name": "decreaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "forceLiquidateBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountSnapshot", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCash", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "healBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "addedValue", "type": "uint256" } - ], - "name": "increaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "underlying_", "type": "address" }, - { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, - { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, - { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, - { "internalType": "string", "name": "name_", "type": "string" }, - { "internalType": "string", "name": "symbol_", "type": "string" }, - { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, - { "internalType": "address", "name": "admin_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { - "components": [ - { "internalType": "address", "name": "shortfall", "type": "address" }, - { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } - ], - "internalType": "struct VTokenInterface.RiskManagementInit", - "name": "riskManagement", - "type": "tuple" - }, - { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "interestRateModel", - "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isVToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } - ], - "name": "liquidateBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], - "name": "mint", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "mintBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolSeizeShareMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolShareReserve", - "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], - "name": "redeem", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], - "name": "redeemUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } - ], - "name": "redeemUnderlyingBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], - "name": "reduceReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockDelta", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], - "name": "repayBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "repayBorrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reserveFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], - "name": "setInterestRateModel", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], - "name": "setProtocolSeizeShare", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], - "name": "setProtocolShareReserve", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], - "name": "setReduceReservesBlockDelta", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], - "name": "setReserveFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], - "name": "setShortfallContract", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "shortfall", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "supplyRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrows", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrowsCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "totalReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transfer", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transferFrom", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "underlying", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-067/index.ts b/multisig/simulations/ethereum/vip-067/index.ts deleted file mode 100644 index 37ef48461..000000000 --- a/multisig/simulations/ethereum/vip-067/index.ts +++ /dev/null @@ -1,161 +0,0 @@ -import { impersonateAccount, setBalance } from "@nomicfoundation/hardhat-network-helpers"; -import { expect } from "chai"; -import { BigNumber, Contract } from "ethers"; -import { parseUnits } from "ethers/lib/utils"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIsolatedPoolsComptrollers"; -import { checkVToken } from "src/vip-framework/checks/checkVToken"; -import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; - -import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; -import vip067, { - BORROW_CAP, - BaseAssets, - CORE_COMPTROLLER, - EIGEN, - SUPPLY_CAP, - USDT_PRIME_CONVERTER, - vEIGEN, -} from "../../../proposals/ethereum/vip-067"; -import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; -import PRIME_CONVERTER_ABI from "./abi/PrimeConverter.json"; -import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; -import COMPTROLLER_ABI from "./abi/comptroller.json"; -import ERC20_ABI from "./abi/erc20.json"; -import VTOKEN_ABI from "./abi/vToken.json"; - -const { ethereum } = NETWORK_ADDRESSES; -const PROTOCOL_SHARE_RESERVE = "0x8c8c8530464f7D95552A11eC31Adbd4dC4AC4d3E"; -const USDT_USER = "0xF977814e90dA44bFA03b6295A0616a897441aceC"; -const EIGEN_USER = "0x56A59D9cF7bc539ADc29537280023543C5c38A00"; - -forking(21079955, async () => { - let resilientOracle: Contract; - let poolRegistry: Contract; - let vEIGENContract: Contract; - let comptroller: Contract; - let eigenContract: Contract; - let usdtPrimeConverter: Contract; - let usdt: Contract; - - describe("Post-VIP behavior", async () => { - before(async () => { - await impersonateAccount(ethereum.NORMAL_TIMELOCK); - await setBalance(ethereum.NORMAL_TIMELOCK, parseUnits("1000", 18)); - await impersonateAccount(USDT_USER); - await setBalance(USDT_USER, parseUnits("1000", 18)); - await impersonateAccount(USDT_PRIME_CONVERTER); - await setBalance(USDT_PRIME_CONVERTER, parseUnits("1000", 18)); - await impersonateAccount(EIGEN_USER); - await setBalance(EIGEN_USER, parseUnits("1000", 18)); - - resilientOracle = await ethers.getContractAt(RESILIENT_ORACLE_ABI, ethereum.RESILIENT_ORACLE); - poolRegistry = await ethers.getContractAt(POOL_REGISTRY_ABI, ethereum.POOL_REGISTRY); - vEIGENContract = await ethers.getContractAt(VTOKEN_ABI, vEIGEN); - comptroller = await ethers.getContractAt(COMPTROLLER_ABI, CORE_COMPTROLLER); - eigenContract = await ethers.getContractAt(ERC20_ABI, EIGEN, await ethers.getSigner(ethereum.NORMAL_TIMELOCK)); - usdtPrimeConverter = await ethers.getContractAt(PRIME_CONVERTER_ABI, USDT_PRIME_CONVERTER); - usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); - - await eigenContract - .connect(await ethers.getSigner(EIGEN_USER)) - .transfer(ethereum.VTREASURY, parseUnits("500", 18)); - - await pretendExecutingVip(await vip067()); - }); - - it("check price", async () => { - expect(await resilientOracle.getPrice(EIGEN)).to.be.equal(parseUnits("3.0196419", 18)); - expect(await resilientOracle.getUnderlyingPrice(vEIGEN)).to.be.equal(parseUnits("3.0196419", 18)); - }); - - it("should have 10 markets in core pool", async () => { - const poolVTokens = await comptroller.getAllMarkets(); - expect(poolVTokens).to.have.lengthOf(10); - }); - - it("should add vEIGEN to the pool", async () => { - const registeredVToken = await poolRegistry.getVTokenForAsset(comptroller.address, EIGEN); - expect(registeredVToken).to.equal(vEIGEN); - }); - - it("check ownership", async () => { - expect(await vEIGENContract.owner()).to.equal(ethereum.GUARDIAN); - }); - - it("check supply", async () => { - const expectedSupply = parseUnits("500", 8); - expect(await vEIGENContract.balanceOf(ethereum.VTREASURY)).to.equal(expectedSupply); - }); - - it("check borrow and supply caps", async () => { - expect(await comptroller.borrowCaps(vEIGEN)).equals(BORROW_CAP); - expect(await comptroller.supplyCaps(vEIGEN)).equals(SUPPLY_CAP); - }); - - it("should set vEIGEN collateral factor to 50% and Liquidation threshold to 60%", async () => { - const market = await comptroller.markets(vEIGEN); - expect(market.collateralFactorMantissa).to.equal(parseUnits("0.5", 18)); - expect(market.liquidationThresholdMantissa).to.equal(parseUnits("0.6", 18)); - }); - - it("check protocol share reserve", async () => { - expect(await vEIGENContract.protocolShareReserve()).equals(PROTOCOL_SHARE_RESERVE); - }); - - it("check reserve factor", async () => { - expect(await vEIGENContract.reserveFactorMantissa()).equals(parseUnits("0.25", 18)); - }); - - it("check protocol seize share", async () => { - expect(await vEIGENContract.protocolSeizeShareMantissa()).equals(parseUnits("0.01", 18)); - }); - - it("check vToken", async () => { - checkVToken(vEIGEN, { - name: "Venus EIGEN", - symbol: "vEIGEN", - decimals: 8, - underlying: EIGEN, - exchangeRate: parseUnits("10000000000", 18), - comptroller: CORE_COMPTROLLER, - }); - }); - - it("check IR", async () => { - const IR = await vEIGENContract.interestRateModel(); - checkInterestRate( - IR, - "vEIGENContract_Core", - { base: "0.02", multiplier: "0.15", jump: "3", kink: "0.45" }, - BigNumber.from(2628000), - ); - }); - - it("check Pool", async () => { - await checkIsolatedPoolsComptrollers(); - }); - - it("EIGEN conversion", async () => { - const usdtAmount = parseUnits("10", 6); - await usdt.connect(await ethers.getSigner(USDT_USER)).approve(usdtPrimeConverter.address, usdtAmount); - - const eigenAmount = parseUnits("2", 18); - await eigenContract.connect(await ethers.getSigner(EIGEN_USER)).transfer(usdtPrimeConverter.address, eigenAmount); - - const usdtBalanceBefore = await usdt.balanceOf(USDT_USER); - const eigenBalanceBefore = await eigenContract.balanceOf(USDT_USER); - - await usdtPrimeConverter - .connect(await ethers.getSigner(USDT_USER)) - .convertForExactTokens(usdtAmount, eigenAmount, usdt.address, eigenContract.address, USDT_USER); - - const usdtBalanceAfter = await usdt.balanceOf(USDT_USER); - const eigenBalanceAfter = await eigenContract.balanceOf(USDT_USER); - - expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("6.999301", 6)); - expect(eigenBalanceAfter.sub(eigenBalanceBefore)).to.be.equal(eigenAmount); - }); - }); -}); From 0b9bc2a9f3997fd5599d998594a59c0289405804 Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 6 Nov 2024 15:41:38 +0400 Subject: [PATCH 102/178] fix: added vip --- simulations/vip-389/bscmainnet.ts | 17 ++++ simulations/vip-389/ethereum.ts | 157 ++++++++++++++++++++++++++++++ vips/vip-389/bscmainnet.ts | 138 ++++++++++++++++++++++++++ 3 files changed, 312 insertions(+) create mode 100644 simulations/vip-389/bscmainnet.ts create mode 100644 simulations/vip-389/ethereum.ts create mode 100644 vips/vip-389/bscmainnet.ts diff --git a/simulations/vip-389/bscmainnet.ts b/simulations/vip-389/bscmainnet.ts new file mode 100644 index 000000000..afa63efa3 --- /dev/null +++ b/simulations/vip-389/bscmainnet.ts @@ -0,0 +1,17 @@ +import { expectEvents } from "../../src/utils"; +import { forking, testVip } from "../../src/vip-framework"; +import vip389 from "../../vips/vip-389/bscmainnet"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +forking(45188496, async () => { + testVip("vip389", await vip389(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [1, 0], + ); + }, + }); +}); diff --git a/simulations/vip-389/ethereum.ts b/simulations/vip-389/ethereum.ts new file mode 100644 index 000000000..50edb32de --- /dev/null +++ b/simulations/vip-389/ethereum.ts @@ -0,0 +1,157 @@ +import { impersonateAccount, setBalance } from "@nomicfoundation/hardhat-network-helpers"; +import { expect } from "chai"; +import { BigNumber, Contract } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; +import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIsolatedPoolsComptrollers"; +import { checkVToken } from "src/vip-framework/checks/checkVToken"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; + +import vip389, { + BORROW_CAP, + BaseAssets, + CORE_COMPTROLLER, + EIGEN, + SUPPLY_CAP, + USDT_PRIME_CONVERTER, + vEIGEN, +} from "../../vips/vip-389/bscmainnet"; +import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; +import PRIME_CONVERTER_ABI from "./abi/PrimeConverter.json"; +import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; +import COMPTROLLER_ABI from "./abi/comptroller.json"; +import ERC20_ABI from "./abi/erc20.json"; +import VTOKEN_ABI from "./abi/vToken.json"; + +const { ethereum } = NETWORK_ADDRESSES; +const PROTOCOL_SHARE_RESERVE = "0x8c8c8530464f7D95552A11eC31Adbd4dC4AC4d3E"; +const USDT_USER = "0xF977814e90dA44bFA03b6295A0616a897441aceC"; +const EIGEN_USER = "0x56A59D9cF7bc539ADc29537280023543C5c38A00"; + +forking(6969766, async () => { + let resilientOracle: Contract; + let poolRegistry: Contract; + let vEIGENContract: Contract; + let comptroller: Contract; + let eigenContract: Contract; + let usdtPrimeConverter: Contract; + let usdt: Contract; + + before(async () => { + await impersonateAccount(ethereum.NORMAL_TIMELOCK); + await setBalance(ethereum.NORMAL_TIMELOCK, parseUnits("1000", 18)); + await impersonateAccount(USDT_USER); + await setBalance(USDT_USER, parseUnits("1000", 18)); + await impersonateAccount(USDT_PRIME_CONVERTER); + await setBalance(USDT_PRIME_CONVERTER, parseUnits("1000", 18)); + await impersonateAccount(EIGEN_USER); + await setBalance(EIGEN_USER, parseUnits("1000", 18)); + + resilientOracle = await ethers.getContractAt(RESILIENT_ORACLE_ABI, ethereum.RESILIENT_ORACLE); + poolRegistry = await ethers.getContractAt(POOL_REGISTRY_ABI, ethereum.POOL_REGISTRY); + vEIGENContract = await ethers.getContractAt(VTOKEN_ABI, vEIGEN); + comptroller = await ethers.getContractAt(COMPTROLLER_ABI, CORE_COMPTROLLER); + eigenContract = await ethers.getContractAt(ERC20_ABI, EIGEN, await ethers.getSigner(ethereum.NORMAL_TIMELOCK)); + usdtPrimeConverter = await ethers.getContractAt(PRIME_CONVERTER_ABI, USDT_PRIME_CONVERTER); + usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); + }); + + testForkedNetworkVipCommands("vip389", await vip389()); + + describe("Post-VIP behavior", async () => { + it("check price", async () => { + expect(await resilientOracle.getPrice(EIGEN)).to.be.equal(parseUnits("3.0196419", 18)); + expect(await resilientOracle.getUnderlyingPrice(vEIGEN)).to.be.equal(parseUnits("3.0196419", 18)); + }); + + it("should have 10 markets in core pool", async () => { + const poolVTokens = await comptroller.getAllMarkets(); + expect(poolVTokens).to.have.lengthOf(10); + }); + + it("should add vEIGEN to the pool", async () => { + const registeredVToken = await poolRegistry.getVTokenForAsset(comptroller.address, EIGEN); + expect(registeredVToken).to.equal(vEIGEN); + }); + + it("check ownership", async () => { + expect(await vEIGENContract.owner()).to.equal(ethereum.GUARDIAN); + }); + + it("check supply", async () => { + const expectedSupply = parseUnits("500", 8); + expect(await vEIGENContract.balanceOf(ethereum.VTREASURY)).to.equal(expectedSupply); + }); + + it("check borrow and supply caps", async () => { + expect(await comptroller.borrowCaps(vEIGEN)).equals(BORROW_CAP); + expect(await comptroller.supplyCaps(vEIGEN)).equals(SUPPLY_CAP); + }); + + it("should set vEIGEN collateral factor to 50% and Liquidation threshold to 60%", async () => { + const market = await comptroller.markets(vEIGEN); + expect(market.collateralFactorMantissa).to.equal(parseUnits("0.5", 18)); + expect(market.liquidationThresholdMantissa).to.equal(parseUnits("0.6", 18)); + }); + + it("check protocol share reserve", async () => { + expect(await vEIGENContract.protocolShareReserve()).equals(PROTOCOL_SHARE_RESERVE); + }); + + it("check reserve factor", async () => { + expect(await vEIGENContract.reserveFactorMantissa()).equals(parseUnits("0.25", 18)); + }); + + it("check protocol seize share", async () => { + expect(await vEIGENContract.protocolSeizeShareMantissa()).equals(parseUnits("0.01", 18)); + }); + + it("check vToken", async () => { + checkVToken(vEIGEN, { + name: "Venus EIGEN", + symbol: "vEIGEN", + decimals: 8, + underlying: EIGEN, + exchangeRate: parseUnits("10000000000", 18), + comptroller: CORE_COMPTROLLER, + }); + }); + + it("check IR", async () => { + const IR = await vEIGENContract.interestRateModel(); + checkInterestRate( + IR, + "vEIGENContract_Core", + { base: "0.02", multiplier: "0.15", jump: "3", kink: "0.45" }, + BigNumber.from(2628000), + ); + }); + + it("check Pool", async () => { + await checkIsolatedPoolsComptrollers(); + }); + + it("EIGEN conversion", async () => { + const usdtAmount = parseUnits("10", 6); + await usdt.connect(await ethers.getSigner(USDT_USER)).approve(usdtPrimeConverter.address, usdtAmount); + + const eigenAmount = parseUnits("2", 18); + await eigenContract.connect(await ethers.getSigner(EIGEN_USER)).transfer(usdtPrimeConverter.address, eigenAmount); + + const usdtBalanceBefore = await usdt.balanceOf(USDT_USER); + const eigenBalanceBefore = await eigenContract.balanceOf(USDT_USER); + + await usdtPrimeConverter + .connect(await ethers.getSigner(USDT_USER)) + .convertForExactTokens(usdtAmount, eigenAmount, usdt.address, eigenContract.address, USDT_USER); + + const usdtBalanceAfter = await usdt.balanceOf(USDT_USER); + const eigenBalanceAfter = await eigenContract.balanceOf(USDT_USER); + + expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("6.999301", 6)); + expect(eigenBalanceAfter.sub(eigenBalanceBefore)).to.be.equal(eigenAmount); + }); + }); +}); diff --git a/vips/vip-389/bscmainnet.ts b/vips/vip-389/bscmainnet.ts new file mode 100644 index 000000000..1e524259d --- /dev/null +++ b/vips/vip-389/bscmainnet.ts @@ -0,0 +1,138 @@ +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +const { ethereum } = NETWORK_ADDRESSES; + +export const EIGEN = "0xec53bF9167f50cDEB3Ae105f56099aaaB9061F83"; +const INITIAL_SUPPLY = parseUnits("500", 18); +export const SUPPLY_CAP = parseUnits("3000000", 18); +export const BORROW_CAP = parseUnits("1500000", 18); +const CF = parseUnits("0.5", 18); +const LT = parseUnits("0.6", 18); +export const vEIGEN = "0x256AdDBe0a387c98f487e44b85c29eb983413c5e"; +export const CORE_COMPTROLLER = "0x687a01ecF6d3907658f7A7c714749fAC32336D1B"; + +export const USDT_PRIME_CONVERTER = "0x4f55cb0a24D5542a3478B0E284259A6B850B06BD"; +export const USDC_PRIME_CONVERTER = "0xcEB9503f10B781E30213c0b320bCf3b3cE54216E"; +export const WBTC_PRIME_CONVERTER = "0xDcCDE673Cd8988745dA384A7083B0bd22085dEA0"; +export const WETH_PRIME_CONVERTER = "0xb8fD67f215117FADeF06447Af31590309750529D"; +export const XVS_VAULT_CONVERTER = "0x1FD30e761C3296fE36D9067b1e398FD97B4C0407"; +export const BaseAssets = [ + "0xdAC17F958D2ee523a2206206994597C13D831ec7", // USDT USDTTokenConverter BaseAsset + "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48", // USDC USDCTokenConverter BaseAsset + "0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599", // WBTC WBTCTokenConverter BaseAsset + "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2", // WETH WETHTokenConverter BaseAsset + "0xd3CC9d8f3689B83c91b7B59cAB4946B063EB894A", // XVS XVSTokenConverter BaseAsset +]; +const CONVERSION_INCENTIVE = parseUnits("0.0001", 18); +const CHAINLINK_FEED = "0xf2917e602C2dCa458937fad715bb1E465305A4A1"; +const MAX_STALE_PERIOD = 30 * 3600; + +const vip389 = () => { + const meta = { + version: "v2", + title: "VIP-389", + description: `### Description`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: ethereum.CHAINLINK_ORACLE, + signature: "setTokenConfig((address,address,uint256))", + params: [[EIGEN, CHAINLINK_FEED, MAX_STALE_PERIOD]], + dstChainId: LzChainId.ethereum, + }, + { + target: ethereum.RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [ + EIGEN, + [ethereum.CHAINLINK_ORACLE, ethers.constants.AddressZero, ethers.constants.AddressZero], + [true, false, false], + ], + ], + dstChainId: LzChainId.ethereum, + }, + + // Add Market + { + target: ethereum.VTREASURY, + signature: "withdrawTreasuryToken(address,uint256,address)", + params: [EIGEN, INITIAL_SUPPLY, ethereum.GUARDIAN], + dstChainId: LzChainId.ethereum, + }, + { + target: EIGEN, + signature: "approve(address,uint256)", + params: [ethereum.POOL_REGISTRY, 0], + dstChainId: LzChainId.ethereum, + }, + { + target: EIGEN, + signature: "approve(address,uint256)", + params: [ethereum.POOL_REGISTRY, INITIAL_SUPPLY], + dstChainId: LzChainId.ethereum, + }, + { + target: vEIGEN, + signature: "setReduceReservesBlockDelta(uint256)", + params: ["7200"], + dstChainId: LzChainId.ethereum, + }, + { + target: ethereum.POOL_REGISTRY, + signature: "addMarket((address,uint256,uint256,uint256,address,uint256,uint256))", + params: [[vEIGEN, CF, LT, INITIAL_SUPPLY, ethereum.VTREASURY, SUPPLY_CAP, BORROW_CAP]], + dstChainId: LzChainId.ethereum, + }, + { + target: vEIGEN, + signature: "setProtocolSeizeShare(uint256)", + params: [parseUnits("0.01", 18)], + dstChainId: LzChainId.ethereum, + }, + + // Conversion config + { + target: USDT_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[0], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], + dstChainId: LzChainId.ethereum, + }, + { + target: USDC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[1], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], + dstChainId: LzChainId.ethereum, + }, + { + target: WBTC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[2], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], + dstChainId: LzChainId.ethereum, + }, + { + target: WETH_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[3], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], + dstChainId: LzChainId.ethereum, + }, + { + target: XVS_VAULT_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[4], [EIGEN], [[CONVERSION_INCENTIVE, 1]]], + dstChainId: LzChainId.ethereum, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip389; From 049287099bef1d260be8a14e690cfc1d358d4432 Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 6 Nov 2024 15:47:45 +0400 Subject: [PATCH 103/178] fix: converted to multichain vip --- multisig/proposals/ethereum/vip-068/index.ts | 108 -- .../ethereum/vip-068/abi/PoolRegistry.json | 310 ---- .../ethereum/vip-068/abi/PrimeConverter.json | 587 ------- .../ethereum/vip-068/abi/ResilientOracle.json | 301 ---- .../ethereum/vip-068/abi/comptroller.json | 1496 ----------------- .../ethereum/vip-068/abi/erc20.json | 134 -- .../ethereum/vip-068/abi/vToken.json | 861 ---------- simulations/vip-391/bscmainnet.ts | 17 + .../vip-391/ethereum.ts | 50 +- vips/vip-391/bscmainnet.ts | 131 ++ 10 files changed, 173 insertions(+), 3822 deletions(-) delete mode 100644 multisig/proposals/ethereum/vip-068/index.ts delete mode 100644 multisig/simulations/ethereum/vip-068/abi/PoolRegistry.json delete mode 100644 multisig/simulations/ethereum/vip-068/abi/PrimeConverter.json delete mode 100644 multisig/simulations/ethereum/vip-068/abi/ResilientOracle.json delete mode 100644 multisig/simulations/ethereum/vip-068/abi/comptroller.json delete mode 100644 multisig/simulations/ethereum/vip-068/abi/erc20.json delete mode 100644 multisig/simulations/ethereum/vip-068/abi/vToken.json create mode 100644 simulations/vip-391/bscmainnet.ts rename multisig/simulations/ethereum/vip-068/index.ts => simulations/vip-391/ethereum.ts (78%) create mode 100644 vips/vip-391/bscmainnet.ts diff --git a/multisig/proposals/ethereum/vip-068/index.ts b/multisig/proposals/ethereum/vip-068/index.ts deleted file mode 100644 index 5cbe5ed3b..000000000 --- a/multisig/proposals/ethereum/vip-068/index.ts +++ /dev/null @@ -1,108 +0,0 @@ -import { parseUnits } from "ethers/lib/utils"; -import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; - -import { makeProposal } from "../../../../src/utils"; - -const { ethereum } = NETWORK_ADDRESSES; - -export const eBTC = "0x657e8C867D8B37dCC18fA4Caead9C45EB088C642"; -const INITIAL_SUPPLY = parseUnits("0.14471345", 8); -export const SUPPLY_CAP = parseUnits("25", 8); -export const BORROW_CAP = parseUnits("12.6", 8); -const CF = parseUnits("0.68", 18); -const LT = parseUnits("0.72", 18); -export const veBTC = "0x325cEB02fe1C2fF816A83a5770eA0E88e2faEcF2"; -export const CORE_COMPTROLLER = "0x687a01ecF6d3907658f7A7c714749fAC32336D1B"; - -export const USDT_PRIME_CONVERTER = "0x4f55cb0a24D5542a3478B0E284259A6B850B06BD"; -export const USDC_PRIME_CONVERTER = "0xcEB9503f10B781E30213c0b320bCf3b3cE54216E"; -export const WBTC_PRIME_CONVERTER = "0xDcCDE673Cd8988745dA384A7083B0bd22085dEA0"; -export const WETH_PRIME_CONVERTER = "0xb8fD67f215117FADeF06447Af31590309750529D"; -export const XVS_VAULT_CONVERTER = "0x1Fd30E761C3296fe36d9068b1e398Fd97b4C0407"; -export const BaseAssets = [ - "0xdAC17F958D2ee523a2206206994597C13D831ec7", // USDT USDTTokenConverter BaseAsset - "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48", // USDC USDCTokenConverter BaseAsset - "0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599", // WBTC WBTCTokenConverter BaseAsset - "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2", // WETH WETHTokenConverter BaseAsset - "0xd3CC9d8f3689B83c91b7B59cAB4946B063EB894A", // XVS XVSTokenConverter BaseAsset -]; -const CONVERSION_INCENTIVE = parseUnits("0.0001", 18); -const eBTCAccountantOracle = "0x077A11d634be3498b9af3EbD3d5D35A0fC3569d8"; - -export const vip068 = () => { - return makeProposal([ - { - target: ethereum.RESILIENT_ORACLE, - signature: "setTokenConfig((address,address[3],bool[3]))", - params: [ - [ - eBTC, - [eBTCAccountantOracle, ethers.constants.AddressZero, ethers.constants.AddressZero], - [true, false, false], - ], - ], - }, - - // Add Market - { - target: ethereum.VTREASURY, - signature: "withdrawTreasuryToken(address,uint256,address)", - params: [eBTC, INITIAL_SUPPLY, ethereum.GUARDIAN], - }, - { - target: eBTC, - signature: "approve(address,uint256)", - params: [ethereum.POOL_REGISTRY, 0], - }, - { - target: eBTC, - signature: "approve(address,uint256)", - params: [ethereum.POOL_REGISTRY, INITIAL_SUPPLY], - }, - { - target: veBTC, - signature: "setReduceReservesBlockDelta(uint256)", - params: ["7200"], - }, - { - target: ethereum.POOL_REGISTRY, - signature: "addMarket((address,uint256,uint256,uint256,address,uint256,uint256))", - params: [[veBTC, CF, LT, INITIAL_SUPPLY, ethereum.VTREASURY, SUPPLY_CAP, BORROW_CAP]], - }, - { - target: veBTC, - signature: "setProtocolSeizeShare(uint256)", - params: [parseUnits("0.01", 18)], - }, - - // Conversion config - { - target: USDT_PRIME_CONVERTER, - signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[0], [eBTC], [[CONVERSION_INCENTIVE, 1]]], - }, - { - target: USDC_PRIME_CONVERTER, - signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[1], [eBTC], [[CONVERSION_INCENTIVE, 1]]], - }, - { - target: WBTC_PRIME_CONVERTER, - signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[2], [eBTC], [[CONVERSION_INCENTIVE, 1]]], - }, - { - target: WETH_PRIME_CONVERTER, - signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[3], [eBTC], [[CONVERSION_INCENTIVE, 1]]], - }, - { - target: XVS_VAULT_CONVERTER, - signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[4], [eBTC], [[CONVERSION_INCENTIVE, 1]]], - }, - ]); -}; - -export default vip068; diff --git a/multisig/simulations/ethereum/vip-068/abi/PoolRegistry.json b/multisig/simulations/ethereum/vip-068/abi/PoolRegistry.json deleted file mode 100644 index 8f15277d2..000000000 --- a/multisig/simulations/ethereum/vip-068/abi/PoolRegistry.json +++ /dev/null @@ -1,310 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "vTokenAddress", "type": "address" } - ], - "name": "MarketAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { - "components": [ - { "internalType": "string", "name": "category", "type": "string" }, - { "internalType": "string", "name": "logoURL", "type": "string" }, - { "internalType": "string", "name": "description", "type": "string" } - ], - "indexed": false, - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", - "name": "oldMetadata", - "type": "tuple" - }, - { - "components": [ - { "internalType": "string", "name": "category", "type": "string" }, - { "internalType": "string", "name": "logoURL", "type": "string" }, - { "internalType": "string", "name": "description", "type": "string" } - ], - "indexed": false, - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", - "name": "newMetadata", - "type": "tuple" - } - ], - "name": "PoolMetadataUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": false, "internalType": "string", "name": "oldName", "type": "string" }, - { "indexed": false, "internalType": "string", "name": "newName", "type": "string" } - ], - "name": "PoolNameSet", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { - "components": [ - { "internalType": "string", "name": "name", "type": "string" }, - { "internalType": "address", "name": "creator", "type": "address" }, - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, - { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } - ], - "indexed": false, - "internalType": "struct PoolRegistryInterface.VenusPool", - "name": "pool", - "type": "tuple" - } - ], - "name": "PoolRegistered", - "type": "event" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { "internalType": "contract VToken", "name": "vToken", "type": "address" }, - { "internalType": "uint256", "name": "collateralFactor", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidationThreshold", "type": "uint256" }, - { "internalType": "uint256", "name": "initialSupply", "type": "uint256" }, - { "internalType": "address", "name": "vTokenReceiver", "type": "address" }, - { "internalType": "uint256", "name": "supplyCap", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowCap", "type": "uint256" } - ], - "internalType": "struct PoolRegistry.AddMarketInput", - "name": "input", - "type": "tuple" - } - ], - "name": "addMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "string", "name": "name", "type": "string" }, - { "internalType": "contract Comptroller", "name": "comptroller", "type": "address" }, - { "internalType": "uint256", "name": "closeFactor", "type": "uint256" }, - { "internalType": "uint256", "name": "liquidationIncentive", "type": "uint256" }, - { "internalType": "uint256", "name": "minLiquidatableCollateral", "type": "uint256" } - ], - "name": "addPool", - "outputs": [{ "internalType": "uint256", "name": "index", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getAllPools", - "outputs": [ - { - "components": [ - { "internalType": "string", "name": "name", "type": "string" }, - { "internalType": "address", "name": "creator", "type": "address" }, - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, - { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool[]", - "name": "", - "type": "tuple[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "comptroller", "type": "address" }], - "name": "getPoolByComptroller", - "outputs": [ - { - "components": [ - { "internalType": "string", "name": "name", "type": "string" }, - { "internalType": "address", "name": "creator", "type": "address" }, - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, - { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } - ], - "internalType": "struct PoolRegistryInterface.VenusPool", - "name": "", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], - "name": "getPoolsSupportedByAsset", - "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "getVTokenForAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "comptroller", "type": "address" }], - "name": "getVenusPoolMetadata", - "outputs": [ - { - "components": [ - { "internalType": "string", "name": "category", "type": "string" }, - { "internalType": "string", "name": "logoURL", "type": "string" }, - { "internalType": "string", "name": "description", "type": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", - "name": "", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "", "type": "address" }], - "name": "metadata", - "outputs": [ - { "internalType": "string", "name": "category", "type": "string" }, - { "internalType": "string", "name": "logoURL", "type": "string" }, - { "internalType": "string", "name": "description", "type": "string" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "string", "name": "name", "type": "string" } - ], - "name": "setPoolName", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { - "components": [ - { "internalType": "string", "name": "category", "type": "string" }, - { "internalType": "string", "name": "logoURL", "type": "string" }, - { "internalType": "string", "name": "description", "type": "string" } - ], - "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", - "name": "metadata_", - "type": "tuple" - } - ], - "name": "updatePoolMetadata", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-068/abi/PrimeConverter.json b/multisig/simulations/ethereum/vip-068/abi/PrimeConverter.json deleted file mode 100644 index 8ea10cc8d..000000000 --- a/multisig/simulations/ethereum/vip-068/abi/PrimeConverter.json +++ /dev/null @@ -1,587 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" } - ], - "name": "AmountInHigherThanMax", - "type": "error" - }, - { "inputs": [], "name": "AmountInMismatched", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" } - ], - "name": "AmountOutLowerThanMinRequired", - "type": "error" - }, - { "inputs": [], "name": "AmountOutMismatched", "type": "error" }, - { "inputs": [], "name": "ConversionConfigNotEnabled", "type": "error" }, - { "inputs": [], "name": "ConversionEnabledOnlyForPrivateConversions", "type": "error" }, - { "inputs": [], "name": "ConversionTokensActive", "type": "error" }, - { "inputs": [], "name": "ConversionTokensPaused", "type": "error" }, - { "inputs": [], "name": "DeflationaryTokenNotSupported", "type": "error" }, - { - "inputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { "internalType": "uint256", "name": "maxIncentive", "type": "uint256" } - ], - "name": "IncentiveTooHigh", - "type": "error" - }, - { "inputs": [], "name": "InputLengthMisMatch", "type": "error" }, - { "inputs": [], "name": "InsufficientInputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientOutputAmount", "type": "error" }, - { "inputs": [], "name": "InsufficientPoolLiquidity", "type": "error" }, - { "inputs": [], "name": "InvalidConverterNetwork", "type": "error" }, - { "inputs": [], "name": "InvalidMinimumAmountToConvert", "type": "error" }, - { "inputs": [], "name": "InvalidToAddress", "type": "error" }, - { "inputs": [], "name": "InvalidTokenConfigAddresses", "type": "error" }, - { "inputs": [], "name": "NonZeroIncentiveForPrivateConversion", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { "inputs": [], "name": "ZeroValueNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "AssetTransferredToDestination", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldBaseAsset", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newBaseAsset", "type": "address" } - ], - "name": "BaseAssetUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "oldIncentive", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newIncentive", "type": "uint256" }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "oldAccess", - "type": "uint8" - }, - { - "indexed": false, - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "newAccess", - "type": "uint8" - } - ], - "name": "ConversionConfigUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionPaused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], - "name": "ConversionResumed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amountIn", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "amountOut", "type": "uint256" } - ], - "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldConverterNetwork", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "converterNetwork", "type": "address" } - ], - "name": "ConverterNetworkAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldDestinationAddress", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "destinationAddress", "type": "address" } - ], - "name": "DestinationAddressUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMinAmountToConvert", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMinAmountToConvert", "type": "uint256" } - ], - "name": "MinAmountToConvertUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ResilientOracle", "name": "oldPriceOracle", "type": "address" }, - { "indexed": true, "internalType": "contract ResilientOracle", "name": "priceOracle", "type": "address" } - ], - "name": "PriceOracleUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "SweepToken", - "type": "event" - }, - { - "inputs": [], - "name": "MAX_INCENTIVE", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "tokenAddress", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "tokenBalance", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "baseAsset", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "address", "name": "", "type": "address" } - ], - "name": "conversionConfigurations", - "outputs": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "conversionPaused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMinMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMaxMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" } - ], - "name": "convertForExactTokensSupportingFeeOnTransferTokens", - "outputs": [ - { "internalType": "uint256", "name": "actualAmountIn", "type": "uint256" }, - { "internalType": "uint256", "name": "actualAmountOut", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "converterNetwork", - "outputs": [{ "internalType": "contract IConverterNetwork", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "destinationAddress", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountIn", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint256", "name": "amountInMantissa", "type": "uint256" }, - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" } - ], - "name": "getUpdatedAmountOut", - "outputs": [ - { "internalType": "uint256", "name": "amountConvertedMantissa", "type": "uint256" }, - { "internalType": "uint256", "name": "amountOutMantissa", "type": "uint256" } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }, - { "internalType": "address", "name": "destinationAddress_", "type": "address" }, - { "internalType": "address", "name": "baseAsset_", "type": "address" }, - { "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "minAmountToConvert", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pauseConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "priceOracle", - "outputs": [{ "internalType": "contract ResilientOracle", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { "inputs": [], "name": "resumeConversion", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "baseAsset_", "type": "address" }], - "name": "setBaseAsset", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address", "name": "tokenAddressOut", "type": "address" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig", - "name": "conversionConfig", - "type": "tuple" - } - ], - "name": "setConversionConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddressIn", "type": "address" }, - { "internalType": "address[]", "name": "tokenAddressesOut", "type": "address[]" }, - { - "components": [ - { "internalType": "uint256", "name": "incentive", "type": "uint256" }, - { - "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", - "name": "conversionAccess", - "type": "uint8" - } - ], - "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", - "name": "conversionConfigs", - "type": "tuple[]" - } - ], - "name": "setConversionConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IConverterNetwork", "name": "converterNetwork_", "type": "address" }], - "name": "setConverterNetwork", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "destinationAddress_", "type": "address" }], - "name": "setDestination", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "minAmountToConvert_", "type": "uint256" }], - "name": "setMinAmountToConvert", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ResilientOracle", "name": "priceOracle_", "type": "address" }], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "tokenAddress", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "comptroller", "type": "address" }, - { "internalType": "address", "name": "asset", "type": "address" } - ], - "name": "updateAssetsState", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-068/abi/ResilientOracle.json b/multisig/simulations/ethereum/vip-068/abi/ResilientOracle.json deleted file mode 100644 index e2f944a9d..000000000 --- a/multisig/simulations/ethereum/vip-068/abi/ResilientOracle.json +++ /dev/null @@ -1,301 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "nativeMarketAddress", "type": "address" }, - { "internalType": "address", "name": "vaiAddress", "type": "address" }, - { "internalType": "contract BoundValidatorInterface", "name": "_boundValidator", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "role", "type": "uint256" }, - { "indexed": true, "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "OracleEnabled", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "oracle", "type": "address" }, - { "indexed": true, "internalType": "uint256", "name": "role", "type": "uint256" } - ], - "name": "OracleSet", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "mainOracle", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "pivotOracle", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "fallbackOracle", "type": "address" } - ], - "name": "TokenConfigAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "INVALID_PRICE", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "NATIVE_TOKEN_ADDR", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "boundValidator", - "outputs": [{ "internalType": "contract BoundValidatorInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" }, - { "internalType": "bool", "name": "enable", "type": "bool" } - ], - "name": "enableOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" } - ], - "name": "getOracle", - "outputs": [ - { "internalType": "address", "name": "oracle", "type": "address" }, - { "internalType": "bool", "name": "enabled", "type": "bool" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], - "name": "getPrice", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], - "name": "getTokenConfig", - "outputs": [ - { - "components": [ - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, - { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "getUnderlyingPrice", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "nativeMarket", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "address", "name": "oracle", "type": "address" }, - { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" } - ], - "name": "setOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, - { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } - ], - "internalType": "struct ResilientOracle.TokenConfig", - "name": "tokenConfig", - "type": "tuple" - } - ], - "name": "setTokenConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { "internalType": "address", "name": "asset", "type": "address" }, - { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, - { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } - ], - "internalType": "struct ResilientOracle.TokenConfig[]", - "name": "tokenConfigs_", - "type": "tuple[]" - } - ], - "name": "setTokenConfigs", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], - "name": "updateAssetPrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], - "name": "updatePrice", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "vai", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-068/abi/comptroller.json b/multisig/simulations/ethereum/vip-068/abi/comptroller.json deleted file mode 100644 index fafe7b35e..000000000 --- a/multisig/simulations/ethereum/vip-068/abi/comptroller.json +++ /dev/null @@ -1,1496 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "address", - "name": "poolRegistry_", - "type": "address" - }, - { - "internalType": "address", - "name": "accessControl_", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "market", - "type": "address" - }, - { - "internalType": "enum ComptrollerStorage.Action", - "name": "action", - "type": "uint8" - } - ], - "name": "ActionPaused", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "market", - "type": "address" - }, - { - "internalType": "uint256", - "name": "cap", - "type": "uint256" - } - ], - "name": "BorrowCapExceeded", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "expectedLessThanOrEqualTo", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "actual", - "type": "uint256" - } - ], - "name": "CollateralExceedsThreshold", - "type": "error" - }, - { - "inputs": [], - "name": "ComptrollerMismatch", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "collateralToSeize", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "availableCollateral", - "type": "uint256" - } - ], - "name": "InsufficientCollateral", - "type": "error" - }, - { - "inputs": [], - "name": "InsufficientLiquidity", - "type": "error" - }, - { - "inputs": [], - "name": "InsufficientShortfall", - "type": "error" - }, - { - "inputs": [], - "name": "InvalidCollateralFactor", - "type": "error" - }, - { - "inputs": [], - "name": "InvalidLiquidationThreshold", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "market", - "type": "address" - } - ], - "name": "MarketAlreadyListed", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "market", - "type": "address" - } - ], - "name": "MarketNotListed", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "expectedGreaterThan", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "actual", - "type": "uint256" - } - ], - "name": "MinimalCollateralViolated", - "type": "error" - }, - { - "inputs": [], - "name": "NonzeroBorrowBalance", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "PriceError", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "address", - "name": "user", - "type": "address" - } - ], - "name": "SnapshotError", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "market", - "type": "address" - }, - { - "internalType": "uint256", - "name": "cap", - "type": "uint256" - } - ], - "name": "SupplyCapExceeded", - "type": "error" - }, - { - "inputs": [], - "name": "TooMuchRepay", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "address", - "name": "calledContract", - "type": "address" - }, - { - "internalType": "string", - "name": "methodSignature", - "type": "string" - } - ], - "name": "Unauthorized", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "expectedSender", - "type": "address" - }, - { - "internalType": "address", - "name": "actualSender", - "type": "address" - } - ], - "name": "UnexpectedSender", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "enum ComptrollerStorage.Action", - "name": "action", - "type": "uint8" - }, - { - "indexed": false, - "internalType": "bool", - "name": "pauseState", - "type": "bool" - } - ], - "name": "ActionPausedMarket", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "MarketEntered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "MarketExited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - } - ], - "name": "MarketSupported", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newBorrowCap", - "type": "uint256" - } - ], - "name": "NewBorrowCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "oldCloseFactorMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newCloseFactorMantissa", - "type": "uint256" - } - ], - "name": "NewCloseFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "oldCollateralFactorMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newCollateralFactorMantissa", - "type": "uint256" - } - ], - "name": "NewCollateralFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "oldLiquidationIncentiveMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLiquidationIncentiveMantissa", - "type": "uint256" - } - ], - "name": "NewLiquidationIncentive", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "oldLiquidationThresholdMantissa", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newLiquidationThresholdMantissa", - "type": "uint256" - } - ], - "name": "NewLiquidationThreshold", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "oldMinLiquidatableCollateral", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newMinLiquidatableCollateral", - "type": "uint256" - } - ], - "name": "NewMinLiquidatableCollateral", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract PriceOracle", - "name": "oldPriceOracle", - "type": "address" - }, - { - "indexed": false, - "internalType": "contract PriceOracle", - "name": "newPriceOracle", - "type": "address" - } - ], - "name": "NewPriceOracle", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "rewardsDistributor", - "type": "address" - } - ], - "name": "NewRewardsDistributor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newSupplyCap", - "type": "uint256" - } - ], - "name": "NewSupplyCap", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "inputs": [], - "name": "acceptOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "accessControl", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - }, - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "name": "accountAssets", - "outputs": [ - { - "internalType": "contract VToken", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "market", - "type": "address" - }, - { - "internalType": "enum ComptrollerStorage.Action", - "name": "action", - "type": "uint8" - } - ], - "name": "actionPaused", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract RewardsDistributor", - "name": "_rewardsDistributor", - "type": "address" - } - ], - "name": "addRewardsDistributor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "name": "allMarkets", - "outputs": [ - { - "internalType": "contract VToken", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "borrowCaps", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - } - ], - "name": "checkMembership", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "closeFactorMantissa", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address[]", - "name": "vTokens", - "type": "address[]" - } - ], - "name": "enterMarkets", - "outputs": [ - { - "internalType": "uint256[]", - "name": "", - "type": "uint256[]" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vTokenAddress", - "type": "address" - } - ], - "name": "exitMarket", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "getAccountLiquidity", - "outputs": [ - { - "internalType": "uint256", - "name": "error", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "liquidity", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "shortfall", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getAllMarkets", - "outputs": [ - { - "internalType": "contract VToken[]", - "name": "", - "type": "address[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "getAssetsIn", - "outputs": [ - { - "internalType": "contract VToken[]", - "name": "", - "type": "address[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "internalType": "address", - "name": "vTokenModify", - "type": "address" - }, - { - "internalType": "uint256", - "name": "redeemTokens", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "borrowAmount", - "type": "uint256" - } - ], - "name": "getHypotheticalAccountLiquidity", - "outputs": [ - { - "internalType": "uint256", - "name": "error", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "liquidity", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "shortfall", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getRewardDistributors", - "outputs": [ - { - "internalType": "contract RewardsDistributor[]", - "name": "", - "type": "address[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - } - ], - "name": "getRewardsByMarket", - "outputs": [ - { - "components": [ - { - "internalType": "address", - "name": "rewardToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "supplySpeed", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "borrowSpeed", - "type": "uint256" - } - ], - "internalType": "struct ComptrollerStorage.RewardSpeeds[]", - "name": "rewardSpeeds", - "type": "tuple[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user", - "type": "address" - } - ], - "name": "healAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "isComptroller", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - } - ], - "name": "isDeprecated", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - } - ], - "name": "isMarketListed", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "borrower", - "type": "address" - }, - { - "components": [ - { - "internalType": "contract VToken", - "name": "vTokenCollateral", - "type": "address" - }, - { - "internalType": "contract VToken", - "name": "vTokenBorrowed", - "type": "address" - }, - { - "internalType": "uint256", - "name": "repayAmount", - "type": "uint256" - } - ], - "internalType": "struct ComptrollerStorage.LiquidationOrder[]", - "name": "orders", - "type": "tuple[]" - } - ], - "name": "liquidateAccount", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vTokenBorrowed", - "type": "address" - }, - { - "internalType": "address", - "name": "vTokenCollateral", - "type": "address" - }, - { - "internalType": "uint256", - "name": "actualRepayAmount", - "type": "uint256" - } - ], - "name": "liquidateCalculateSeizeTokens", - "outputs": [ - { - "internalType": "uint256", - "name": "error", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "tokensToSeize", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "liquidationIncentiveMantissa", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "markets", - "outputs": [ - { - "internalType": "bool", - "name": "isListed", - "type": "bool" - }, - { - "internalType": "uint256", - "name": "collateralFactorMantissa", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "liquidationThresholdMantissa", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "minLiquidatableCollateral", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "oracle", - "outputs": [ - { - "internalType": "contract PriceOracle", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "poolRegistry", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "address", - "name": "borrower", - "type": "address" - }, - { - "internalType": "uint256", - "name": "borrowAmount", - "type": "uint256" - } - ], - "name": "preBorrowHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vTokenBorrowed", - "type": "address" - }, - { - "internalType": "address", - "name": "vTokenCollateral", - "type": "address" - }, - { - "internalType": "address", - "name": "borrower", - "type": "address" - }, - { - "internalType": "uint256", - "name": "repayAmount", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "skipLiquidityCheck", - "type": "bool" - } - ], - "name": "preLiquidateHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "address", - "name": "minter", - "type": "address" - }, - { - "internalType": "uint256", - "name": "mintAmount", - "type": "uint256" - } - ], - "name": "preMintHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "address", - "name": "redeemer", - "type": "address" - }, - { - "internalType": "uint256", - "name": "redeemTokens", - "type": "uint256" - } - ], - "name": "preRedeemHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "address", - "name": "borrower", - "type": "address" - } - ], - "name": "preRepayHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vTokenCollateral", - "type": "address" - }, - { - "internalType": "address", - "name": "seizerContract", - "type": "address" - }, - { - "internalType": "address", - "name": "liquidator", - "type": "address" - }, - { - "internalType": "address", - "name": "borrower", - "type": "address" - } - ], - "name": "preSeizeHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "vToken", - "type": "address" - }, - { - "internalType": "address", - "name": "src", - "type": "address" - }, - { - "internalType": "address", - "name": "dst", - "type": "address" - }, - { - "internalType": "uint256", - "name": "transferTokens", - "type": "uint256" - } - ], - "name": "preTransferHook", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VToken[]", - "name": "marketsList", - "type": "address[]" - }, - { - "internalType": "enum ComptrollerStorage.Action[]", - "name": "actionsList", - "type": "uint8[]" - }, - { - "internalType": "bool", - "name": "paused", - "type": "bool" - } - ], - "name": "setActionsPaused", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "newCloseFactorMantissa", - "type": "uint256" - } - ], - "name": "setCloseFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "newCollateralFactorMantissa", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "newLiquidationThresholdMantissa", - "type": "uint256" - } - ], - "name": "setCollateralFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "newLiquidationIncentiveMantissa", - "type": "uint256" - } - ], - "name": "setLiquidationIncentive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VToken[]", - "name": "vTokens", - "type": "address[]" - }, - { - "internalType": "uint256[]", - "name": "newBorrowCaps", - "type": "uint256[]" - } - ], - "name": "setMarketBorrowCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VToken[]", - "name": "vTokens", - "type": "address[]" - }, - { - "internalType": "uint256[]", - "name": "newSupplyCaps", - "type": "uint256[]" - } - ], - "name": "setMarketSupplyCaps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "newMinLiquidatableCollateral", - "type": "uint256" - } - ], - "name": "setMinLiquidatableCollateral", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract PriceOracle", - "name": "newOracle", - "type": "address" - } - ], - "name": "setPriceOracle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "supplyCaps", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract VToken", - "name": "vToken", - "type": "address" - } - ], - "name": "supportMarket", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-068/abi/erc20.json b/multisig/simulations/ethereum/vip-068/abi/erc20.json deleted file mode 100644 index 3a509c9c4..000000000 --- a/multisig/simulations/ethereum/vip-068/abi/erc20.json +++ /dev/null @@ -1,134 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "string", "name": "name_", "type": "string" }, - { "internalType": "string", "name": "symbol_", "type": "string" }, - { "internalType": "uint8", "name": "decimals_", "type": "uint8" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } - ], - "name": "Transfer", - "type": "event" - }, - { - "inputs": [ - { "internalType": "address", "name": "owner", "type": "address" }, - { "internalType": "address", "name": "spender", "type": "address" } - ], - "name": "allowance", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "approve", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } - ], - "name": "decreaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], - "name": "faucet", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "addedValue", "type": "uint256" } - ], - "name": "increaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "to", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transfer", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "from", "type": "address" }, - { "internalType": "address", "name": "to", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transferFrom", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/multisig/simulations/ethereum/vip-068/abi/vToken.json b/multisig/simulations/ethereum/vip-068/abi/vToken.json deleted file mode 100644 index d8cc1aae4..000000000 --- a/multisig/simulations/ethereum/vip-068/abi/vToken.json +++ /dev/null @@ -1,861 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], - "name": "AddReservesFactorFreshCheck", - "type": "error" - }, - { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, - { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, - { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], - "name": "LiquidateAccrueCollateralInterestFailed", - "type": "error" - }, - { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, - { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, - { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, - { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, - { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, - { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, - { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "AccrueInterest", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtRecovered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "Borrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "HealBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "LiquidateBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } - ], - "name": "NewComptroller", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "oldInterestRateModel", - "type": "address" - }, - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "newInterestRateModel", - "type": "address" - } - ], - "name": "NewMarketInterestRateModel", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } - ], - "name": "NewProtocolSeizeShare", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } - ], - "name": "NewProtocolShareReserve", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } - ], - "name": "NewReduceReservesBlockDelta", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } - ], - "name": "NewReserveFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } - ], - "name": "NewShortfallContract", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ProtocolSeize", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Redeem", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "RepayBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "ReservesAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "SpreadReservesReduced", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Transfer", - "type": "event" - }, - { - "inputs": [], - "name": "NO_ERROR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrualBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrueInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], - "name": "addReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "owner", "type": "address" }, - { "internalType": "address", "name": "spender", "type": "address" } - ], - "name": "allowance", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "approve", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "badDebt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], - "name": "badDebtRecovered", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOfUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], - "name": "borrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "borrowIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "borrowRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } - ], - "name": "decreaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "forceLiquidateBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountSnapshot", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCash", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "healBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "addedValue", "type": "uint256" } - ], - "name": "increaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "underlying_", "type": "address" }, - { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, - { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, - { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, - { "internalType": "string", "name": "name_", "type": "string" }, - { "internalType": "string", "name": "symbol_", "type": "string" }, - { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, - { "internalType": "address", "name": "admin_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { - "components": [ - { "internalType": "address", "name": "shortfall", "type": "address" }, - { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } - ], - "internalType": "struct VTokenInterface.RiskManagementInit", - "name": "riskManagement", - "type": "tuple" - }, - { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "interestRateModel", - "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isVToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } - ], - "name": "liquidateBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], - "name": "mint", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "mintBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolSeizeShareMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolShareReserve", - "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], - "name": "redeem", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], - "name": "redeemUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } - ], - "name": "redeemUnderlyingBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], - "name": "reduceReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockDelta", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], - "name": "repayBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "repayBorrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reserveFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], - "name": "setInterestRateModel", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], - "name": "setProtocolSeizeShare", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], - "name": "setProtocolShareReserve", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], - "name": "setReduceReservesBlockDelta", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], - "name": "setReserveFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], - "name": "setShortfallContract", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "shortfall", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "supplyRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrows", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrowsCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "totalReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transfer", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transferFrom", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "underlying", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-391/bscmainnet.ts b/simulations/vip-391/bscmainnet.ts new file mode 100644 index 000000000..c3930af70 --- /dev/null +++ b/simulations/vip-391/bscmainnet.ts @@ -0,0 +1,17 @@ +import { expectEvents } from "../../src/utils"; +import { forking, testVip } from "../../src/vip-framework"; +import vip391 from "../../vips/vip-391/bscmainnet"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +forking(45194889, async () => { + testVip("vip391", await vip391(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [1, 0], + ); + }, + }); +}); diff --git a/multisig/simulations/ethereum/vip-068/index.ts b/simulations/vip-391/ethereum.ts similarity index 78% rename from multisig/simulations/ethereum/vip-068/index.ts rename to simulations/vip-391/ethereum.ts index 54d51244b..b0b017021 100644 --- a/multisig/simulations/ethereum/vip-068/index.ts +++ b/simulations/vip-391/ethereum.ts @@ -4,12 +4,12 @@ import { BigNumber, Contract } from "ethers"; import { parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIsolatedPoolsComptrollers"; import { checkVToken } from "src/vip-framework/checks/checkVToken"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; -import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; -import vip068, { +import vip391, { BORROW_CAP, BaseAssets, CORE_COMPTROLLER, @@ -17,7 +17,7 @@ import vip068, { USDT_PRIME_CONVERTER, eBTC, veBTC, -} from "../../../proposals/ethereum/vip-068"; +} from "../../vips/vip-391/bsctestnet"; import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; import PRIME_CONVERTER_ABI from "./abi/PrimeConverter.json"; import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; @@ -30,7 +30,7 @@ const PROTOCOL_SHARE_RESERVE = "0x8c8c8530464f7D95552A11eC31Adbd4dC4AC4d3E"; const USDT_USER = "0xF977814e90dA44bFA03b6295A0616a897441aceC"; const eBTC_USER = "0x7aCDF2012aAC69D70B86677FE91eb66e08961880"; -forking(21079955, async () => { +forking(6976822, async () => { let resilientOracle: Contract; let poolRegistry: Contract; let veBTCContract: Contract; @@ -39,28 +39,28 @@ forking(21079955, async () => { let usdtPrimeConverter: Contract; let usdt: Contract; - describe("Post-VIP behavior", async () => { - before(async () => { - await impersonateAccount(ethereum.NORMAL_TIMELOCK); - await setBalance(ethereum.NORMAL_TIMELOCK, parseUnits("1000", 18)); - await impersonateAccount(USDT_USER); - await setBalance(USDT_USER, parseUnits("1000", 18)); - await impersonateAccount(eBTC_USER); - await setBalance(eBTC_USER, parseUnits("1000", 18)); - await impersonateAccount(USDT_PRIME_CONVERTER); - await setBalance(USDT_PRIME_CONVERTER, parseUnits("1000", 18)); - - resilientOracle = await ethers.getContractAt(RESILIENT_ORACLE_ABI, ethereum.RESILIENT_ORACLE); - poolRegistry = await ethers.getContractAt(POOL_REGISTRY_ABI, ethereum.POOL_REGISTRY); - veBTCContract = await ethers.getContractAt(VTOKEN_ABI, veBTC); - comptroller = await ethers.getContractAt(COMPTROLLER_ABI, CORE_COMPTROLLER); - eBTCContract = await ethers.getContractAt(ERC20_ABI, eBTC, await ethers.getSigner(ethereum.NORMAL_TIMELOCK)); - usdtPrimeConverter = await ethers.getContractAt(PRIME_CONVERTER_ABI, USDT_PRIME_CONVERTER); - usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); - - await pretendExecutingVip(await vip068()); - }); + before(async () => { + await impersonateAccount(ethereum.NORMAL_TIMELOCK); + await setBalance(ethereum.NORMAL_TIMELOCK, parseUnits("1000", 18)); + await impersonateAccount(USDT_USER); + await setBalance(USDT_USER, parseUnits("1000", 18)); + await impersonateAccount(eBTC_USER); + await setBalance(eBTC_USER, parseUnits("1000", 18)); + await impersonateAccount(USDT_PRIME_CONVERTER); + await setBalance(USDT_PRIME_CONVERTER, parseUnits("1000", 18)); + + resilientOracle = await ethers.getContractAt(RESILIENT_ORACLE_ABI, ethereum.RESILIENT_ORACLE); + poolRegistry = await ethers.getContractAt(POOL_REGISTRY_ABI, ethereum.POOL_REGISTRY); + veBTCContract = await ethers.getContractAt(VTOKEN_ABI, veBTC); + comptroller = await ethers.getContractAt(COMPTROLLER_ABI, CORE_COMPTROLLER); + eBTCContract = await ethers.getContractAt(ERC20_ABI, eBTC, await ethers.getSigner(ethereum.NORMAL_TIMELOCK)); + usdtPrimeConverter = await ethers.getContractAt(PRIME_CONVERTER_ABI, USDT_PRIME_CONVERTER); + usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); + }); + testForkedNetworkVipCommands("vip391", await vip391()); + + describe("Post-VIP behavior", async () => { it("check price", async () => { expect(await resilientOracle.getPrice(eBTC)).to.be.equal(parseUnits("71835.7052865100", 28)); expect(await resilientOracle.getUnderlyingPrice(veBTC)).to.be.equal(parseUnits("71835.7052865100", 28)); diff --git a/vips/vip-391/bscmainnet.ts b/vips/vip-391/bscmainnet.ts new file mode 100644 index 000000000..75966cee5 --- /dev/null +++ b/vips/vip-391/bscmainnet.ts @@ -0,0 +1,131 @@ +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +const { ethereum } = NETWORK_ADDRESSES; + +export const eBTC = "0x657e8C867D8B37dCC18fA4Caead9C45EB088C642"; +const INITIAL_SUPPLY = parseUnits("0.14471345", 8); +export const SUPPLY_CAP = parseUnits("25", 8); +export const BORROW_CAP = parseUnits("12.6", 8); +const CF = parseUnits("0.68", 18); +const LT = parseUnits("0.72", 18); +export const veBTC = "0x325cEB02fe1C2fF816A83a5770eA0E88e2faEcF2"; +export const CORE_COMPTROLLER = "0x687a01ecF6d3907658f7A7c714749fAC32336D1B"; + +export const USDT_PRIME_CONVERTER = "0x4f55cb0a24D5542a3478B0E284259A6B850B06BD"; +export const USDC_PRIME_CONVERTER = "0xcEB9503f10B781E30213c0b320bCf3b3cE54216E"; +export const WBTC_PRIME_CONVERTER = "0xDcCDE673Cd8988745dA384A7083B0bd22085dEA0"; +export const WETH_PRIME_CONVERTER = "0xb8fD67f215117FADeF06447Af31590309750529D"; +export const XVS_VAULT_CONVERTER = "0x1Fd30E761C3296fe36d9068b1e398Fd97b4C0407"; +export const BaseAssets = [ + "0xdAC17F958D2ee523a2206206994597C13D831ec7", // USDT USDTTokenConverter BaseAsset + "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48", // USDC USDCTokenConverter BaseAsset + "0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599", // WBTC WBTCTokenConverter BaseAsset + "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2", // WETH WETHTokenConverter BaseAsset + "0xd3CC9d8f3689B83c91b7B59cAB4946B063EB894A", // XVS XVSTokenConverter BaseAsset +]; +const CONVERSION_INCENTIVE = parseUnits("0.0001", 18); +const eBTCAccountantOracle = "0x077A11d634be3498b9af3EbD3d5D35A0fC3569d8"; + +const vip391 = () => { + const meta = { + version: "v2", + title: "VIP-391", + description: `### Description`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: ethereum.RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [ + eBTC, + [eBTCAccountantOracle, ethers.constants.AddressZero, ethers.constants.AddressZero], + [true, false, false], + ], + ], + dstChainId: LzChainId.ethereum, + }, + + // Add Market + { + target: ethereum.VTREASURY, + signature: "withdrawTreasuryToken(address,uint256,address)", + params: [eBTC, INITIAL_SUPPLY, ethereum.GUARDIAN], + dstChainId: LzChainId.ethereum, + }, + { + target: eBTC, + signature: "approve(address,uint256)", + params: [ethereum.POOL_REGISTRY, 0], + dstChainId: LzChainId.ethereum, + }, + { + target: eBTC, + signature: "approve(address,uint256)", + params: [ethereum.POOL_REGISTRY, INITIAL_SUPPLY], + dstChainId: LzChainId.ethereum, + }, + { + target: veBTC, + signature: "setReduceReservesBlockDelta(uint256)", + params: ["7200"], + dstChainId: LzChainId.ethereum, + }, + { + target: ethereum.POOL_REGISTRY, + signature: "addMarket((address,uint256,uint256,uint256,address,uint256,uint256))", + params: [[veBTC, CF, LT, INITIAL_SUPPLY, ethereum.VTREASURY, SUPPLY_CAP, BORROW_CAP]], + dstChainId: LzChainId.ethereum, + }, + { + target: veBTC, + signature: "setProtocolSeizeShare(uint256)", + params: [parseUnits("0.01", 18)], + dstChainId: LzChainId.ethereum, + }, + + // Conversion config + { + target: USDT_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[0], [eBTC], [[CONVERSION_INCENTIVE, 1]]], + dstChainId: LzChainId.ethereum, + }, + { + target: USDC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[1], [eBTC], [[CONVERSION_INCENTIVE, 1]]], + dstChainId: LzChainId.ethereum, + }, + { + target: WBTC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[2], [eBTC], [[CONVERSION_INCENTIVE, 1]]], + dstChainId: LzChainId.ethereum, + }, + { + target: WETH_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[3], [eBTC], [[CONVERSION_INCENTIVE, 1]]], + dstChainId: LzChainId.ethereum, + }, + { + target: XVS_VAULT_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[4], [eBTC], [[CONVERSION_INCENTIVE, 1]]], + dstChainId: LzChainId.ethereum, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip391; From 53075c84421fa302172e77fb151d5fc1bfb20c79 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Mon, 4 Nov 2024 23:18:59 +0530 Subject: [PATCH 104/178] feat: add vip to include USDC market on zksync mainnet and BNB VIP to refund wallet --- .../proposals/zksyncmainnet/vip-015/index.ts | 73 + .../vip-015/abi/comptroller.json | 1496 ++++++++++++ .../zksyncmainnet/vip-015/abi/erc20.json | 295 +++ .../zksyncmainnet/vip-015/abi/rateModel.json | 118 + .../vip-015/abi/resilientOracle.json | 640 +++++ .../zksyncmainnet/vip-015/abi/vToken.json | 2066 +++++++++++++++++ .../zksyncmainnet/vip-015/index.ts | 120 + simulations/vip-392/abi/ERC20.json | 295 +++ simulations/vip-392/abi/VtreasuryAbi.json | 83 + simulations/vip-392/bscmainnet.ts | 39 + vips/vip-392/bscmainnet.ts | 85 + 11 files changed, 5310 insertions(+) create mode 100644 multisig/proposals/zksyncmainnet/vip-015/index.ts create mode 100644 multisig/simulations/zksyncmainnet/vip-015/abi/comptroller.json create mode 100644 multisig/simulations/zksyncmainnet/vip-015/abi/erc20.json create mode 100644 multisig/simulations/zksyncmainnet/vip-015/abi/rateModel.json create mode 100644 multisig/simulations/zksyncmainnet/vip-015/abi/resilientOracle.json create mode 100644 multisig/simulations/zksyncmainnet/vip-015/abi/vToken.json create mode 100644 multisig/simulations/zksyncmainnet/vip-015/index.ts create mode 100644 simulations/vip-392/abi/ERC20.json create mode 100644 simulations/vip-392/abi/VtreasuryAbi.json create mode 100644 simulations/vip-392/bscmainnet.ts create mode 100644 vips/vip-392/bscmainnet.ts diff --git a/multisig/proposals/zksyncmainnet/vip-015/index.ts b/multisig/proposals/zksyncmainnet/vip-015/index.ts new file mode 100644 index 000000000..254a8871f --- /dev/null +++ b/multisig/proposals/zksyncmainnet/vip-015/index.ts @@ -0,0 +1,73 @@ +import { parseUnits } from "ethers/lib/utils"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { makeProposal } from "src/utils"; + +const { zksyncmainnet } = NETWORK_ADDRESSES; + +export const USDC = "0x1d17CBcF0D6D143135aE902365D2E5e2A16538D4"; +export const VUSDC_CORE = "0x84064c058F2EFea4AB648bB6Bd7e40f83fFDe39a"; +export const INITIAL_SUPPLY = parseUnits("4998.378502", 6); +const CHAINLINK_USDC_FEED = "0x1824D297C6d6D311A204495277B63e943C2D376E"; +const STALE_PERIOD_26H = 26 * 60 * 60; // 26 hours (pricefeeds with heartbeat of 24 hr) + +const vip015 = () => { + return makeProposal([ + { + target: zksyncmainnet.CHAINLINK_ORACLE, + signature: "setTokenConfig((address,address,uint256))", + params: [[USDC, CHAINLINK_USDC_FEED, STALE_PERIOD_26H]], + }, + { + target: zksyncmainnet.RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [ + USDC, + [ + zksyncmainnet.CHAINLINK_ORACLE, + "0x0000000000000000000000000000000000000000", + "0x0000000000000000000000000000000000000000", + ], + [true, false, false], + ], + ], + }, + { + target: zksyncmainnet.VTREASURY, + signature: "withdrawTreasuryToken(address,uint256,address)", + params: [USDC, INITIAL_SUPPLY, zksyncmainnet.GUARDIAN], + }, + { + target: USDC, + signature: "approve(address,uint256)", + params: [zksyncmainnet.POOL_REGISTRY, 0], + }, + { + target: USDC, + signature: "approve(address,uint256)", + params: [zksyncmainnet.POOL_REGISTRY, INITIAL_SUPPLY], + }, + { + target: VUSDC_CORE, + signature: "setReduceReservesBlockDelta(uint256)", + params: ["86400"], + }, + { + target: zksyncmainnet.POOL_REGISTRY, + signature: "addMarket((address,uint256,uint256,uint256,address,uint256,uint256))", + params: [ + [ + VUSDC_CORE, + parseUnits("0.72", 18), // CF + parseUnits("0.75", 18), // LT + INITIAL_SUPPLY, // initial supply + zksyncmainnet.VTREASURY, + parseUnits("1250000", 6), // supply cap + parseUnits("1000000", 6), // borrow cap + ], + ], + }, + ]); +}; + +export default vip015; diff --git a/multisig/simulations/zksyncmainnet/vip-015/abi/comptroller.json b/multisig/simulations/zksyncmainnet/vip-015/abi/comptroller.json new file mode 100644 index 000000000..fafe7b35e --- /dev/null +++ b/multisig/simulations/zksyncmainnet/vip-015/abi/comptroller.json @@ -0,0 +1,1496 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "poolRegistry_", + "type": "address" + }, + { + "internalType": "address", + "name": "accessControl_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedLessThanOrEqualTo", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { + "inputs": [], + "name": "ComptrollerMismatch", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "collateralToSeize", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "availableCollateral", + "type": "uint256" + } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientLiquidity", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientShortfall", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidCollateralFactor", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidLiquidationThreshold", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedGreaterThan", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { + "inputs": [], + "name": "NonzeroBorrowBalance", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { + "inputs": [], + "name": "TooMuchRepay", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "expectedSender", + "type": "address" + }, + { + "internalType": "address", + "name": "actualSender", + "type": "address" + } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "bool", + "name": "pauseState", + "type": "bool" + } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newBorrowCap", + "type": "uint256" + } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldCloseFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldCollateralFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationIncentiveMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationThresholdMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMinLiquidatableCollateral", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "rewardsDistributor", + "type": "address" + } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSupplyCap", + "type": "uint256" + } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControl", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "accountAssets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "actionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract RewardsDistributor", + "name": "_rewardsDistributor", + "type": "address" + } + ], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "allMarkets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "borrowCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "checkMembership", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "vTokens", + "type": "address[]" + } + ], + "name": "enterMarkets", + "outputs": [ + { + "internalType": "uint256[]", + "name": "", + "type": "uint256[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenAddress", + "type": "address" + } + ], + "name": "exitMarket", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAssetsIn", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenModify", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [ + { + "internalType": "contract RewardsDistributor[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "rewardToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "supplySpeed", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowSpeed", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isDeprecated", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isMarketListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "components": [ + { + "internalType": "contract VToken", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokensToSeize", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "markets", + "outputs": [ + { + "internalType": "bool", + "name": "isListed", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "collateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidationThresholdMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [ + { + "internalType": "contract PriceOracle", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "skipLiquidityCheck", + "type": "bool" + } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "seizerContract", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "transferTokens", + "type": "uint256" + } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "marketsList", + "type": "address[]" + }, + { + "internalType": "enum ComptrollerStorage.Action[]", + "name": "actionsList", + "type": "uint8[]" + }, + { + "internalType": "bool", + "name": "paused", + "type": "bool" + } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newBorrowCaps", + "type": "uint256[]" + } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newSupplyCaps", + "type": "uint256[]" + } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract PriceOracle", + "name": "newOracle", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "supplyCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/zksyncmainnet/vip-015/abi/erc20.json b/multisig/simulations/zksyncmainnet/vip-015/abi/erc20.json new file mode 100644 index 000000000..374b04c75 --- /dev/null +++ b/multisig/simulations/zksyncmainnet/vip-015/abi/erc20.json @@ -0,0 +1,295 @@ +[ + { + "inputs": [ + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "userAddress", "type": "address" }, + { "indexed": false, "internalType": "address payable", "name": "relayerAddress", "type": "address" }, + { "indexed": false, "internalType": "bytes", "name": "functionSignature", "type": "bytes" } + ], + "name": "MetaTransactionExecuted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } + ], + "name": "RoleAdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_ADMIN_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "ERC712_VERSION", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "PREDICATE_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "userAddress", "type": "address" }, + { "internalType": "bytes", "name": "functionSignature", "type": "bytes" }, + { "internalType": "bytes32", "name": "sigR", "type": "bytes32" }, + { "internalType": "bytes32", "name": "sigS", "type": "bytes32" }, + { "internalType": "uint8", "name": "sigV", "type": "uint8" } + ], + "name": "executeMetaTransaction", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [], + "name": "getChainId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [], + "name": "getDomainSeperator", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "getNonce", + "outputs": [{ "internalType": "uint256", "name": "nonce", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleAdmin", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "uint256", "name": "index", "type": "uint256" } + ], + "name": "getRoleMember", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleMemberCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "grantRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "hasRole", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "renounceRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "revokeRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/zksyncmainnet/vip-015/abi/rateModel.json b/multisig/simulations/zksyncmainnet/vip-015/abi/rateModel.json new file mode 100644 index 000000000..8c04a8527 --- /dev/null +++ b/multisig/simulations/zksyncmainnet/vip-015/abi/rateModel.json @@ -0,0 +1,118 @@ +[ + { + "inputs": [ + { "internalType": "uint256", "name": "baseRatePerYear", "type": "uint256" }, + { "internalType": "uint256", "name": "multiplierPerYear", "type": "uint256" }, + { "internalType": "uint256", "name": "jumpMultiplierPerYear", "type": "uint256" }, + { "internalType": "uint256", "name": "kink_", "type": "uint256" } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "baseRatePerBlock", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "multiplierPerBlock", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "jumpMultiplierPerBlock", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "kink", "type": "uint256" } + ], + "name": "NewInterestParams", + "type": "event" + }, + { + "constant": true, + "inputs": [], + "name": "baseRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "blocksPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "uint256", "name": "cash", "type": "uint256" }, + { "internalType": "uint256", "name": "borrows", "type": "uint256" }, + { "internalType": "uint256", "name": "reserves", "type": "uint256" } + ], + "name": "getBorrowRate", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "uint256", "name": "cash", "type": "uint256" }, + { "internalType": "uint256", "name": "borrows", "type": "uint256" }, + { "internalType": "uint256", "name": "reserves", "type": "uint256" }, + { "internalType": "uint256", "name": "reserveFactorMantissa", "type": "uint256" } + ], + "name": "getSupplyRate", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isInterestRateModel", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "jumpMultiplierPerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "kink", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "multiplierPerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { "internalType": "uint256", "name": "cash", "type": "uint256" }, + { "internalType": "uint256", "name": "borrows", "type": "uint256" }, + { "internalType": "uint256", "name": "reserves", "type": "uint256" } + ], + "name": "utilizationRate", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "payable": false, + "stateMutability": "pure", + "type": "function" + } +] diff --git a/multisig/simulations/zksyncmainnet/vip-015/abi/resilientOracle.json b/multisig/simulations/zksyncmainnet/vip-015/abi/resilientOracle.json new file mode 100644 index 000000000..35f52caa0 --- /dev/null +++ b/multisig/simulations/zksyncmainnet/vip-015/abi/resilientOracle.json @@ -0,0 +1,640 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "nativeMarketAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + }, + { + "internalType": "contract BoundValidatorInterface", + "name": "_boundValidator", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "mainOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "pivotOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "fallbackOracle", + "type": "address" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [ + { + "internalType": "contract BoundValidatorInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "getOracle", + "outputs": [ + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "bool", + "name": "enabled", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/zksyncmainnet/vip-015/abi/vToken.json b/multisig/simulations/zksyncmainnet/vip-015/abi/vToken.json new file mode 100644 index 000000000..1ce01e4a8 --- /dev/null +++ b/multisig/simulations/zksyncmainnet/vip-015/abi/vToken.json @@ -0,0 +1,2066 @@ +[ + { + "inputs": [ + { + "internalType": "bool", + "name": "timeBased_", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "blocksPerYear_", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxBorrowRateMantissa_", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "actualAddAmount", + "type": "uint256" + } + ], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { + "inputs": [], + "name": "BorrowCashNotAvailable", + "type": "error" + }, + { + "inputs": [], + "name": "BorrowFreshnessCheck", + "type": "error" + }, + { + "inputs": [], + "name": "DelegateNotApproved", + "type": "error" + }, + { + "inputs": [], + "name": "ForceLiquidateBorrowUnauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "HealBorrowUnauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidBlocksPerYear", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidTimeBasedConfiguration", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "errorCode", + "type": "uint256" + } + ], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { + "inputs": [], + "name": "LiquidateCloseAmountIsUintMax", + "type": "error" + }, + { + "inputs": [], + "name": "LiquidateCloseAmountIsZero", + "type": "error" + }, + { + "inputs": [], + "name": "LiquidateCollateralFreshnessCheck", + "type": "error" + }, + { + "inputs": [], + "name": "LiquidateFreshnessCheck", + "type": "error" + }, + { + "inputs": [], + "name": "LiquidateLiquidatorIsBorrower", + "type": "error" + }, + { + "inputs": [], + "name": "LiquidateSeizeLiquidatorIsBorrower", + "type": "error" + }, + { + "inputs": [], + "name": "MintFreshnessCheck", + "type": "error" + }, + { + "inputs": [], + "name": "ProtocolSeizeShareTooBig", + "type": "error" + }, + { + "inputs": [], + "name": "RedeemFreshnessCheck", + "type": "error" + }, + { + "inputs": [], + "name": "RedeemTransferOutNotPossible", + "type": "error" + }, + { + "inputs": [], + "name": "ReduceReservesCashNotAvailable", + "type": "error" + }, + { + "inputs": [], + "name": "ReduceReservesCashValidation", + "type": "error" + }, + { + "inputs": [], + "name": "ReduceReservesFreshCheck", + "type": "error" + }, + { + "inputs": [], + "name": "RepayBorrowFreshnessCheck", + "type": "error" + }, + { + "inputs": [], + "name": "SetInterestRateModelFreshCheck", + "type": "error" + }, + { + "inputs": [], + "name": "SetReserveFactorBoundsCheck", + "type": "error" + }, + { + "inputs": [], + "name": "SetReserveFactorFreshCheck", + "type": "error" + }, + { + "inputs": [], + "name": "TransferNotAllowed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "cashPrior", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "interestAccumulated", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "borrowIndex", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "totalBorrows", + "type": "uint256" + } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "badDebtDelta", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "badDebtOld", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "badDebtNew", + "type": "uint256" + } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "badDebtOld", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "badDebtNew", + "type": "uint256" + } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "accountBorrows", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "totalBorrows", + "type": "uint256" + } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "payer", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "seizeTokens", + "type": "uint256" + } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "mintTokens", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "accountBalance", + "type": "uint256" + } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract ComptrollerInterface", + "name": "oldComptroller", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract ComptrollerInterface", + "name": "newComptroller", + "type": "address" + } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldProtocolSeizeShareMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newProtocolSeizeShareMantissa", + "type": "uint256" + } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldProtocolShareReserve", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newProtocolShareReserve", + "type": "address" + } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldReduceReservesBlockOrTimestampDelta", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newReduceReservesBlockOrTimestampDelta", + "type": "uint256" + } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldReserveFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newReserveFactorMantissa", + "type": "uint256" + } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldShortfall", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newShortfall", + "type": "address" + } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "redeemAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "accountBalance", + "type": "uint256" + } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "payer", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "accountBorrows", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "totalBorrows", + "type": "uint256" + } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "benefactor", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "addAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newTotalReserves", + "type": "uint256" + } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "protocolShareReserve", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "reduceAmount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newTotalReserves", + "type": "uint256" + } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "token", + "type": "address" + } + ], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "addAmount", + "type": "uint256" + } + ], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "address", + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "recoveredAmount_", + "type": "uint256" + } + ], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + } + ], + "name": "balanceOfUnderlying", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "borrow", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "borrowBalanceCurrent", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "borrowBalanceStored", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "borrowBehalf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [ + { + "internalType": "contract ComptrollerInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "internalType": "contract VTokenInterface", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "bool", + "name": "skipLiquidityCheck", + "type": "bool" + } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAccountSnapshot", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "vTokenBalance", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowBalance", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "exchangeRate", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "payer", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "underlying_", + "type": "address" + }, + { + "internalType": "contract ComptrollerInterface", + "name": "comptroller_", + "type": "address" + }, + { + "internalType": "contract InterestRateModel", + "name": "interestRateModel_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "initialExchangeRateMantissa_", + "type": "uint256" + }, + { + "internalType": "string", + "name": "name_", + "type": "string" + }, + { + "internalType": "string", + "name": "symbol_", + "type": "string" + }, + { + "internalType": "uint8", + "name": "decimals_", + "type": "uint8" + }, + { + "internalType": "address", + "name": "admin_", + "type": "address" + }, + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + }, + { + "components": [ + { + "internalType": "address", + "name": "shortfall", + "type": "address" + }, + { + "internalType": "address payable", + "name": "protocolShareReserve", + "type": "address" + } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "reserveFactorMantissa_", + "type": "uint256" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [ + { + "internalType": "contract InterestRateModel", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "internalType": "contract VTokenInterface", + "name": "vTokenCollateral", + "type": "address" + } + ], + "name": "liquidateBorrow", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "mintBehalf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [ + { + "internalType": "address payable", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "redeem", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "redeemBehalf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "redeemAmount", + "type": "uint256" + } + ], + "name": "redeemUnderlying", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemAmount", + "type": "uint256" + } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "reduceAmount", + "type": "uint256" + } + ], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "name": "repayBorrow", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "name": "repayBorrowBehalf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "seizeTokens", + "type": "uint256" + } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newProtocolSeizeShareMantissa_", + "type": "uint256" + } + ], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address payable", + "name": "protocolShareReserve_", + "type": "address" + } + ], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_newReduceReservesBlockOrTimestampDelta", + "type": "uint256" + } + ], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newReserveFactorMantissa", + "type": "uint256" + } + ], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "shortfall_", + "type": "address" + } + ], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract IERC20Upgradeable", + "name": "token", + "type": "address" + } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/zksyncmainnet/vip-015/index.ts b/multisig/simulations/zksyncmainnet/vip-015/index.ts new file mode 100644 index 000000000..e47891d01 --- /dev/null +++ b/multisig/simulations/zksyncmainnet/vip-015/index.ts @@ -0,0 +1,120 @@ +import { expect } from "chai"; +import { BigNumber, Contract } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip } from "src/vip-framework"; +import { checkVToken } from "src/vip-framework/checks/checkVToken"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; + +import vip015, { USDC, VUSDC_CORE } from "../../../proposals/zksyncmainnet/vip-015"; +import COMPTROLLER_ABI from "./abi/comptroller.json"; +import ERC20_ABI from "./abi/erc20.json"; +import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; +import VTOKEN_ABI from "./abi/vToken.json"; + +const { zksyncmainnet } = NETWORK_ADDRESSES; + +const COMPTROLLER_CORE = "0xddE4D098D9995B659724ae6d5E3FB9681Ac941B1"; +const PSR = "0xA1193e941BDf34E858f7F276221B4886EfdD040b"; + +const BLOCKS_PER_YEAR = BigNumber.from("31536000"); // equal to seconds in a year as it is timebased deployment + +forking(48211836, async () => { + describe("Post-Execution state", () => { + let allMarkets: any; + let vToken: Contract; + let comptroller: Contract; + + before(async () => { + comptroller = await ethers.getContractAt(COMPTROLLER_ABI, COMPTROLLER_CORE); + vToken = await ethers.getContractAt(VTOKEN_ABI, VUSDC_CORE); + + allMarkets = await comptroller.getAllMarkets(); + await pretendExecutingVip(await vip015()); + }); + + it("check price", async () => { + const resilientOracle = await ethers.getContractAt(RESILIENT_ORACLE_ABI, zksyncmainnet.RESILIENT_ORACLE); + expect(await resilientOracle.getPrice(USDC)).to.be.equal(parseUnits("1.00000191", 30)); + expect(await resilientOracle.getUnderlyingPrice(VUSDC_CORE)).to.be.equal(parseUnits("1.00000191", 30)); + }); + + it("should register Core pool vTokens in Core pool Comptroller", async () => { + const poolVTokens = await comptroller.getAllMarkets(); + expect(poolVTokens).to.have.lengthOf(BigNumber.from(allMarkets.length).add(1)); + expect(poolVTokens).to.include(VUSDC_CORE); + }); + + it(`should set PSR`, async () => { + expect(await vToken.protocolShareReserve()).to.equal(PSR); + }); + + it(`should mint initial supply of VUSDC to VTreasury`, async () => { + // Since we're distributing 1:1, decimals should be accounted for in the exchange rate + const expectedSupply = parseUnits("4998.378502", 8); + expect(await vToken.balanceOf(zksyncmainnet.VTREASURY)).to.equal(expectedSupply); + }); + + describe("Risk parameters", () => { + describe(`risk parameters`, () => { + let underlyingDecimals: number; + + before(async () => { + const underlying = await ethers.getContractAt(ERC20_ABI, USDC); + underlyingDecimals = await underlying.decimals(); + }); + + it(`should set VUSDC reserve factor to 10%`, async () => { + expect(await vToken.reserveFactorMantissa()).to.equal(parseUnits("0.1", 18)); + }); + + it(`should set VUSDC collateral factor to 72%`, async () => { + const market = await comptroller.markets(VUSDC_CORE); + expect(market.collateralFactorMantissa).to.equal(parseUnits("0.72", 18)); + }); + + it(`should set VUSDC liquidation threshold to 75%`, async () => { + const market = await comptroller.markets(VUSDC_CORE); + expect(market.liquidationThresholdMantissa).to.equal(parseUnits("0.75", 18)); + }); + + it(`should set VUSDC protocol seize share to 0.05`, async () => { + expect(await vToken.protocolSeizeShareMantissa()).to.equal(parseUnits("0.05", 18)); + }); + + it(`should set VUSDC supply cap to 1250000`, async () => { + expect(await comptroller.supplyCaps(VUSDC_CORE)).to.equal(parseUnits("1250000", underlyingDecimals)); + }); + + it(`should set VUSDC borrow cap to 1000000`, async () => { + expect(await comptroller.borrowCaps(VUSDC_CORE)).to.equal(parseUnits("1000000", underlyingDecimals)); + }); + }); + + it("Interest rates", async () => { + checkInterestRate( + "0x6e0f830e7fc78a296B0EbD5694573C2D9f0994B1", // IRM + "VUSDC_CORE", + { + base: "0", + multiplier: "0.0875", + jump: "0.8", + kink: "0.8", + }, + BLOCKS_PER_YEAR, + ); + }); + it("check vtoken", async () => { + checkVToken(VUSDC_CORE, { + name: "Venus USDC (Core)", + symbol: "vUSDC_Core", + decimals: 8, + underlying: USDC, + exchangeRate: parseUnits("1", 16), + comptroller: COMPTROLLER_CORE, + }); + }); + }); + }); +}); diff --git a/simulations/vip-392/abi/ERC20.json b/simulations/vip-392/abi/ERC20.json new file mode 100644 index 000000000..374b04c75 --- /dev/null +++ b/simulations/vip-392/abi/ERC20.json @@ -0,0 +1,295 @@ +[ + { + "inputs": [ + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "userAddress", "type": "address" }, + { "indexed": false, "internalType": "address payable", "name": "relayerAddress", "type": "address" }, + { "indexed": false, "internalType": "bytes", "name": "functionSignature", "type": "bytes" } + ], + "name": "MetaTransactionExecuted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } + ], + "name": "RoleAdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_ADMIN_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "ERC712_VERSION", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "PREDICATE_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "userAddress", "type": "address" }, + { "internalType": "bytes", "name": "functionSignature", "type": "bytes" }, + { "internalType": "bytes32", "name": "sigR", "type": "bytes32" }, + { "internalType": "bytes32", "name": "sigS", "type": "bytes32" }, + { "internalType": "uint8", "name": "sigV", "type": "uint8" } + ], + "name": "executeMetaTransaction", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [], + "name": "getChainId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [], + "name": "getDomainSeperator", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "getNonce", + "outputs": [{ "internalType": "uint256", "name": "nonce", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleAdmin", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "uint256", "name": "index", "type": "uint256" } + ], + "name": "getRoleMember", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleMemberCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "grantRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "hasRole", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "renounceRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "revokeRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-392/abi/VtreasuryAbi.json b/simulations/vip-392/abi/VtreasuryAbi.json new file mode 100644 index 000000000..df5a655ee --- /dev/null +++ b/simulations/vip-392/abi/VtreasuryAbi.json @@ -0,0 +1,83 @@ +[ + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": false, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryBEP20", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": false, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryBNB", + "type": "event" + }, + { "payable": true, "stateMutability": "payable", "type": "fallback" }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryBEP20", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryBNB", + "outputs": [], + "payable": true, + "stateMutability": "payable", + "type": "function" + } +] diff --git a/simulations/vip-392/bscmainnet.ts b/simulations/vip-392/bscmainnet.ts new file mode 100644 index 000000000..0a46fa2bd --- /dev/null +++ b/simulations/vip-392/bscmainnet.ts @@ -0,0 +1,39 @@ +import { expect } from "chai"; +import { BigNumber, Contract } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; +import { forking, testVip } from "src/vip-framework"; + +import { COMMUNITY_WALLET, USDC, vip392 } from "../../vips/vip-392/bscmainnet"; +import ERC20_ABI from "./abi/ERC20.json"; +import VTREASURY_ABI from "./abi/VtreasuryAbi.json"; + +const { bscmainnet } = NETWORK_ADDRESSES; + +forking(43720400, async () => { + let oldUsdcWalletBalance: BigNumber; + let oldUsdcTreasuryBalance: BigNumber; + let usdc: Contract; + + before(async () => { + usdc = new ethers.Contract(USDC, ERC20_ABI, ethers.provider); + oldUsdcWalletBalance = await usdc.balanceOf(COMMUNITY_WALLET); + oldUsdcTreasuryBalance = await usdc.balanceOf(bscmainnet.VTREASURY); + }); + + testVip("VIP-392 Refund USDC to community wallet", await vip392(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [VTREASURY_ABI], ["WithdrawTreasuryBEP20"], [1]); + }, + }); + describe("Post-VIP behavior", async () => { + it("Verify that the community wallet has received the correct amount of USDC", async () => { + const walletBalance = await usdc.balanceOf(COMMUNITY_WALLET); + const treasuryBalance = await usdc.balanceOf(bscmainnet.VTREASURY); + expect(walletBalance).to.eq(oldUsdcWalletBalance.add(parseUnits("5000", 18))); + expect(treasuryBalance).to.eq(oldUsdcTreasuryBalance.sub(parseUnits("5000", 18))); + }); + }); +}); diff --git a/vips/vip-392/bscmainnet.ts b/vips/vip-392/bscmainnet.ts new file mode 100644 index 000000000..39c9750cb --- /dev/null +++ b/vips/vip-392/bscmainnet.ts @@ -0,0 +1,85 @@ +import { parseUnits } from "ethers/lib/utils"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +const { bscmainnet } = NETWORK_ADDRESSES; +export const COMMUNITY_WALLET = "0xc444949e0054A23c44Fc45789738bdF64aed2391"; +export const USDC = "0x8AC76a51cc950d9822D68b83fE1Ad97B32Cd580d"; + +export const vip392 = () => { + const meta = { + version: "v2", + title: "VIP-392 [zkSync] New native USDC market in the Core pool", + description: `#### Summary + +If passed, following the Community proposal “[Support native USDC on Venus Core Pool of ZKSync Era](https://community.venus.io/t/support-native-usdc-on-venus-core-pool-of-zksync-era/4611)” and [the associated snapshot](https://snapshot.org/#/venus-xvs.eth/proposal/0xcb25dcc1ea932f9bd6d5bdc531c09933f29281b7dd38c79e33560819fbf2b47b), this VIP adds a market for [native USDC](https://explorer.zksync.io/address/0x1d17CBcF0D6D143135aE902365D2E5e2A16538D4) into the Core pool on zkSync Era, and refunds the [Community Wallet](https://bscscan.com/address/0xc444949e0054A23c44Fc45789738bdF64aed2391) the provided bootstrap liquidity. + +#### Description + +#### Risk parameters + +Following [Chaos Labs recommendations](https://community.venus.io/t/support-native-usdc-on-venus-core-pool-of-zksync-era/4611/6), the risk parameters for the new market are: + +Underlying token: [USDC](https://explorer.zksync.io/address/0x1d17CBcF0D6D143135aE902365D2E5e2A16538D4) + +- Borrow cap: 1,000,000 +- Supply cap: 1,250,000 +- Collateral factor: 72% +- Liquidation threshold: 75% +- Reserve factor: 10% + +Bootstrap liquidity: 4,998.38 USDC - provided by the [Venus Treasury](https://bscscan.com/address/0xf322942f644a996a617bd29c16bd7d231d9f35e9). + +Interest rate curve for the new market: + +- kink: 80% +- base (yearly): 0% +- multiplier (yearly): 8.75% +- jump multiplier (yearly): 80% + +#### Oracles configuration + +The [ResilientOracle](https://docs-v4.venus.io/risk/resilient-price-oracle) deployed to [zkSync Era](https://explorer.zksync.io/address/0xDe564a4C887d5ad315a19a96DC81991c98b12182) is used for USDC, with the [Chainlink feed](https://explorer.zksync.io/address/0x1824D297C6d6D311A204495277B63e943C2D376E) for this asset as the main oracle. + +#### Security and additional considerations + +We applied the following security procedures for this upgrade: + +- **VIP execution simulation**: in a simulation environment, validating the new market is properly added to the Core pool on zkSync Era, with the right parameters and the expected bootstrap liquidity +- **Deployment on testnet**: the same market has been deployed to zkSync sepolia, and used in the Venus Protocol testnet deployment + +The Community Wallet [provided the bootstrap liquidity](https://explorer.zksync.io/tx/0x3c025522063877bc90ad418d39c97a2116974e21b5d0c79af5dafedd4e1c370f) (4,998.38 USDC), spending 5,000 USDC, that will be refunded in this VIP with funds from the Venus Treasury on BNB Chain. + +#### Deployed contracts + +- Mainnet vUSDC_Core: [0x84064c058F2EFea4AB648bB6Bd7e40f83fFDe39a](https://explorer.zksync.io/address/0x84064c058F2EFea4AB648bB6Bd7e40f83fFDe39a) +- Testnet vUSDC_Core: [0xA266EfCC7D1a8F1AAd093446E3C0115467ea8b9C](https://sepolia.explorer.zksync.io/address/0xA266EfCC7D1a8F1AAd093446E3C0115467ea8b9C) + +#### References + +- [VIP simulation](https://github.com/VenusProtocol/vips/pull/421) +- [Deployment to zkSync sepolia](https://sepolia.explorer.zksync.io/tx/0x2c6e155d736dd2a8d0a453a697853de95969e35341cb4a91bffb1fdaf85c9233#overview) +- [Documentation](https://docs-v4.venus.io/) + +#### Disclaimer for zkSync Era VIPs + +Privilege commands on zkSync Era will be executed by the [Guardian wallet](https://explorer.zksync.io/address/0x751Aa759cfBB6CE71A43b48e40e1cCcFC66Ba4aa), until the [Multichain Governance](https://docs-v4.venus.io/technical-reference/reference-technical-articles/multichain-governance) contracts are fully enabled. If this VIP passes, [this](https://app.safe.global/transactions/tx?safe=zksync:0x751Aa759cfBB6CE71A43b48e40e1cCcFC66Ba4aa&id=multisig_0x751Aa759cfBB6CE71A43b48e40e1cCcFC66Ba4aa_0xa60ebcb8664eb36fba3bc7211ecc82c2cd36cd9a87ee652a9d5cb46f25586d90) multisig transaction will be executed. Otherwise, it will be rejected. +`, + forDescription: "Process to configure and launch the new market", + againstDescription: "Defer configuration and launch of the new market", + abstainDescription: "No opinion on the matter", + }; + return makeProposal( + [ + { + target: bscmainnet.VTREASURY, + signature: "withdrawTreasuryBEP20(address,uint256,address)", + params: [USDC, parseUnits("5000", 18), COMMUNITY_WALLET], + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip392; From 10e6f06f32de989b0e719bc4a396f1bbdf28ef56 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Wed, 6 Nov 2024 11:05:53 +0530 Subject: [PATCH 105/178] fix: allMarkets type in simulation --- multisig/simulations/zksyncmainnet/vip-015/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/multisig/simulations/zksyncmainnet/vip-015/index.ts b/multisig/simulations/zksyncmainnet/vip-015/index.ts index e47891d01..3d84a31d2 100644 --- a/multisig/simulations/zksyncmainnet/vip-015/index.ts +++ b/multisig/simulations/zksyncmainnet/vip-015/index.ts @@ -22,7 +22,7 @@ const BLOCKS_PER_YEAR = BigNumber.from("31536000"); // equal to seconds in a yea forking(48211836, async () => { describe("Post-Execution state", () => { - let allMarkets: any; + let allMarkets: string[]; let vToken: Contract; let comptroller: Contract; From 6225eefbbbc318701e2006e388582c91e6ff8129 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Wed, 6 Nov 2024 19:38:31 +0530 Subject: [PATCH 106/178] refactor: change file structure --- simulations/{vip-365 => vip-395}/abi/ACMAggregator.json | 0 .../{vip-365 => vip-395}/abi/AccessControlManager_ABI.json | 0 .../{vip-365 => vip-395}/abi/OmnichainExecutorOwner_ABI.json | 0 .../abi/OmnichainGovernanceExecutor_ABI.json | 0 .../{vip-365 => vip-395}/abi/OmnichainProposalSender.json | 0 simulations/{vip-365 => vip-395}/bsctestnet.ts | 2 +- simulations/{vip-365 => vip-395}/zksyncsepolia.ts | 2 +- vips/{vip-365 => vip-395}/bsctestnet.ts | 0 8 files changed, 2 insertions(+), 2 deletions(-) rename simulations/{vip-365 => vip-395}/abi/ACMAggregator.json (100%) rename simulations/{vip-365 => vip-395}/abi/AccessControlManager_ABI.json (100%) rename simulations/{vip-365 => vip-395}/abi/OmnichainExecutorOwner_ABI.json (100%) rename simulations/{vip-365 => vip-395}/abi/OmnichainGovernanceExecutor_ABI.json (100%) rename simulations/{vip-365 => vip-395}/abi/OmnichainProposalSender.json (100%) rename simulations/{vip-365 => vip-395}/bsctestnet.ts (98%) rename simulations/{vip-365 => vip-395}/zksyncsepolia.ts (99%) rename vips/{vip-365 => vip-395}/bsctestnet.ts (100%) diff --git a/simulations/vip-365/abi/ACMAggregator.json b/simulations/vip-395/abi/ACMAggregator.json similarity index 100% rename from simulations/vip-365/abi/ACMAggregator.json rename to simulations/vip-395/abi/ACMAggregator.json diff --git a/simulations/vip-365/abi/AccessControlManager_ABI.json b/simulations/vip-395/abi/AccessControlManager_ABI.json similarity index 100% rename from simulations/vip-365/abi/AccessControlManager_ABI.json rename to simulations/vip-395/abi/AccessControlManager_ABI.json diff --git a/simulations/vip-365/abi/OmnichainExecutorOwner_ABI.json b/simulations/vip-395/abi/OmnichainExecutorOwner_ABI.json similarity index 100% rename from simulations/vip-365/abi/OmnichainExecutorOwner_ABI.json rename to simulations/vip-395/abi/OmnichainExecutorOwner_ABI.json diff --git a/simulations/vip-365/abi/OmnichainGovernanceExecutor_ABI.json b/simulations/vip-395/abi/OmnichainGovernanceExecutor_ABI.json similarity index 100% rename from simulations/vip-365/abi/OmnichainGovernanceExecutor_ABI.json rename to simulations/vip-395/abi/OmnichainGovernanceExecutor_ABI.json diff --git a/simulations/vip-365/abi/OmnichainProposalSender.json b/simulations/vip-395/abi/OmnichainProposalSender.json similarity index 100% rename from simulations/vip-365/abi/OmnichainProposalSender.json rename to simulations/vip-395/abi/OmnichainProposalSender.json diff --git a/simulations/vip-365/bsctestnet.ts b/simulations/vip-395/bsctestnet.ts similarity index 98% rename from simulations/vip-365/bsctestnet.ts rename to simulations/vip-395/bsctestnet.ts index 6f80e4ae9..0cf61ebb2 100644 --- a/simulations/vip-365/bsctestnet.ts +++ b/simulations/vip-395/bsctestnet.ts @@ -5,7 +5,7 @@ import { LzChainId } from "src/types"; import { expectEvents } from "src/utils"; import { forking, testVip } from "src/vip-framework"; -import vip365, { MAX_DAILY_LIMIT, OMNICHAIN_PROPOSAL_SENDER } from "../../vips/vip-365/bsctestnet"; +import vip365, { MAX_DAILY_LIMIT, OMNICHAIN_PROPOSAL_SENDER } from "../../vips/vip-395/bsctestnet"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; diff --git a/simulations/vip-365/zksyncsepolia.ts b/simulations/vip-395/zksyncsepolia.ts similarity index 99% rename from simulations/vip-365/zksyncsepolia.ts rename to simulations/vip-395/zksyncsepolia.ts index 48b354c40..eb0678b01 100644 --- a/simulations/vip-365/zksyncsepolia.ts +++ b/simulations/vip-395/zksyncsepolia.ts @@ -12,7 +12,7 @@ import vip365, { ZKSYNCSEPOLIA_ACM, ZKSYNCSEPOLIA_ACM_AGGREGATOR, ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, -} from "../../vips/vip-365/bsctestnet"; +} from "../../vips/vip-395/bsctestnet"; import ACMAggregator_ABI from "./abi/ACMAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_EXECUTOR_OWNER_ABI from "./abi/OmnichainExecutorOwner_ABI.json"; diff --git a/vips/vip-365/bsctestnet.ts b/vips/vip-395/bsctestnet.ts similarity index 100% rename from vips/vip-365/bsctestnet.ts rename to vips/vip-395/bsctestnet.ts From 63de56a8cc8c30ca8d2d9443ce19abd5451dde17 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Wed, 6 Nov 2024 20:08:53 +0530 Subject: [PATCH 107/178] feat: add multichain vip for zksyncmainnet --- .../proposals/zksyncmainnet/vip-015/index.ts | 16 ++ .../vip-015/abi/AccessControlManagerAbi.json | 157 ++++++++++++++++++ .../zksyncmainnet/vip-015/index.ts | 31 ++++ simulations/vip-395/bscmainnet.ts | 56 +++++++ simulations/vip-395/zksyncmainnet.ts | 151 +++++++++++++++++ src/networkAddresses.ts | 5 +- vips/vip-395/bscmainnet.ts | 64 +++++++ 7 files changed, 479 insertions(+), 1 deletion(-) create mode 100644 multisig/proposals/zksyncmainnet/vip-015/index.ts create mode 100644 multisig/simulations/zksyncmainnet/vip-015/abi/AccessControlManagerAbi.json create mode 100644 multisig/simulations/zksyncmainnet/vip-015/index.ts create mode 100644 simulations/vip-395/bscmainnet.ts create mode 100644 simulations/vip-395/zksyncmainnet.ts create mode 100644 vips/vip-395/bscmainnet.ts diff --git a/multisig/proposals/zksyncmainnet/vip-015/index.ts b/multisig/proposals/zksyncmainnet/vip-015/index.ts new file mode 100644 index 000000000..dabf25128 --- /dev/null +++ b/multisig/proposals/zksyncmainnet/vip-015/index.ts @@ -0,0 +1,16 @@ +import { makeProposal } from "src/utils"; + +export const ZKSYNCMAINNET_ACM = "0x526159A92A82afE5327d37Ef446b68FD9a5cA914"; +export const ZKSYNCMAINNET_NORMAL_TIMELOCK = "0x093565Bc20AA326F4209eBaF3a26089272627613"; +const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + +export const vip015 = () => { + return makeProposal([ + { + target: ZKSYNCMAINNET_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ZKSYNCMAINNET_NORMAL_TIMELOCK], + }, + ]); +}; +export default vip015; diff --git a/multisig/simulations/zksyncmainnet/vip-015/abi/AccessControlManagerAbi.json b/multisig/simulations/zksyncmainnet/vip-015/abi/AccessControlManagerAbi.json new file mode 100644 index 000000000..2ef119947 --- /dev/null +++ b/multisig/simulations/zksyncmainnet/vip-015/abi/AccessControlManagerAbi.json @@ -0,0 +1,157 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } + ], + "name": "RoleAdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleRevoked", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_ADMIN_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleAdmin", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToPermit", "type": "address" } + ], + "name": "giveCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "grantRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "hasPermission", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "hasRole", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "isAllowedToCall", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "renounceRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToRevoke", "type": "address" } + ], + "name": "revokeCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "revokeRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], + "name": "supportsInterface", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/zksyncmainnet/vip-015/index.ts b/multisig/simulations/zksyncmainnet/vip-015/index.ts new file mode 100644 index 000000000..4ff684e5d --- /dev/null +++ b/multisig/simulations/zksyncmainnet/vip-015/index.ts @@ -0,0 +1,31 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip015, { ZKSYNCMAINNET_ACM, ZKSYNCMAINNET_NORMAL_TIMELOCK } from "../../../proposals/zksyncmainnet/vip-015"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManagerAbi.json"; + +forking(48280698, async () => { + let acm: Contract; + let defaultAdminRole: string; + before(async () => { + acm = await ethers.getContractAt(ACCESS_CONTROL_MANAGER_ABI, ZKSYNCMAINNET_ACM); + defaultAdminRole = await acm.DEFAULT_ADMIN_ROLE(); + }); + describe("Pre-VIP behaviour", async () => { + it("Normal Timelock does not has default admin role", async () => { + const hasRole = await acm.hasRole(defaultAdminRole, ZKSYNCMAINNET_NORMAL_TIMELOCK); + expect(hasRole).equals(false); + }); + }); + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip015()); + }); + it("Normal Timelock has default admin role", async () => { + const hasRole = await acm.hasRole(defaultAdminRole, ZKSYNCMAINNET_NORMAL_TIMELOCK); + expect(hasRole).equals(true); + }); + }); +}); diff --git a/simulations/vip-395/bscmainnet.ts b/simulations/vip-395/bscmainnet.ts new file mode 100644 index 000000000..96e1d86e3 --- /dev/null +++ b/simulations/vip-395/bscmainnet.ts @@ -0,0 +1,56 @@ +import { expect } from "chai"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId } from "src/types"; +import { expectEvents } from "src/utils"; +import { forking, testVip } from "src/vip-framework"; + +import vip395, { MAX_DAILY_LIMIT, OMNICHAIN_PROPOSAL_SENDER } from "../../vips/vip-395/bscmainnet"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +const { zksyncmainnet } = NETWORK_ADDRESSES; + +forking(43770901, async () => { + const provider = ethers.provider; + const omnichainProposalSender = new ethers.Contract( + OMNICHAIN_PROPOSAL_SENDER, + OMNICHAIN_PROPOSAL_SENDER_ABI, + provider, + ); + + describe("Pre-VIP behaviour", () => { + it("Daily limit should be 0", async () => { + expect(await omnichainProposalSender.chainIdToMaxDailyLimit(LzChainId.zksyncmainnet)).to.equals(0); + }); + it("Trusted remote should not be set", async () => { + expect(await omnichainProposalSender.trustedRemoteLookup(LzChainId.zksyncmainnet)).to.be.equals("0x"); + }); + }); + + testVip("vip395 give permissions to timelock", await vip395(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [ACCESS_CONTROL_MANAGER_ABI, OMNICHAIN_PROPOSAL_SENDER_ABI], + ["SetMaxDailyLimit", "SetTrustedRemoteAddress", "ExecuteRemoteProposal", "StorePayload"], + [1, 1, 1, 0], + ); + }, + }); + + describe("Post-VIP behavior", () => { + it("Daily limit should be 100 of zksyncmainnet", async () => { + expect(await omnichainProposalSender.chainIdToMaxDailyLimit(LzChainId.zksyncmainnet)).to.equals(MAX_DAILY_LIMIT); + }); + + it("Trusted remote should be set of zksyncmainnet", async () => { + expect(await omnichainProposalSender.trustedRemoteLookup(LzChainId.zksyncmainnet)).to.be.equals( + ethers.utils.solidityPack( + ["address", "address"], + [zksyncmainnet.OMNICHAIN_GOVERNANCE_EXECUTOR, OMNICHAIN_PROPOSAL_SENDER], + ), + ); + }); + }); +}); diff --git a/simulations/vip-395/zksyncmainnet.ts b/simulations/vip-395/zksyncmainnet.ts new file mode 100644 index 000000000..dab534a94 --- /dev/null +++ b/simulations/vip-395/zksyncmainnet.ts @@ -0,0 +1,151 @@ +import { expect } from "chai"; +import { BigNumber, Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId } from "src/types"; +import { expectEvents, getOmnichainProposalSenderAddress } from "src/utils"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip015 from "../../multisig/proposals/zksyncmainnet/vip-015"; +import vip395, { + DEFAULT_ADMIN_ROLE, + ZKSYNCMAINNET_ACM, + ZKSYNCMAINNET_ACM_AGGREGATOR, + ZKSYNCMAINNET_OMNICHAIN_EXECUTOR_OWNER, +} from "../../vips/vip-395/bscmainnet"; +import ACMAggregator_ABI from "./abi/ACMAggregator.json"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; +import OMNICHAIN_EXECUTOR_OWNER_ABI from "./abi/OmnichainExecutorOwner_ABI.json"; +import OMNICHAIN_GOVERNANCE_EXECUTOR_ABI from "./abi/OmnichainGovernanceExecutor_ABI.json"; + +const { zksyncmainnet } = NETWORK_ADDRESSES; +const FAST_TRACK_TIMELOCK = "0x32f71c95BC8F9d996f89c642f1a84d06B2484AE9"; +const CRITICAL_TIMELOCK = "0xbfbc79D4198963e4a66270F3EfB1fdA0F382E49c"; + +forking(48280698, async () => { + const provider = ethers.provider; + let lastProposalReceived: BigNumber; + let executor: Contract; + let executorOwner: Contract; + + before(async () => { + executor = new ethers.Contract( + zksyncmainnet.OMNICHAIN_GOVERNANCE_EXECUTOR, + OMNICHAIN_GOVERNANCE_EXECUTOR_ABI, + provider, + ); + executorOwner = new ethers.Contract(ZKSYNCMAINNET_OMNICHAIN_EXECUTOR_OWNER, OMNICHAIN_EXECUTOR_OWNER_ABI, provider); + lastProposalReceived = await executor.lastProposalReceived(); + await pretendExecutingVip(await vip015()); + }); + + describe("Pre-VIP behaviour", async () => { + it("Normal Timelock has default admin role on ZKsync mainnet", async () => { + const acm = await ethers.getContractAt(ACCESS_CONTROL_MANAGER_ABI, ZKSYNCMAINNET_ACM); + const hasRole = await acm.hasRole(DEFAULT_ADMIN_ROLE, zksyncmainnet.NORMAL_TIMELOCK); + expect(hasRole).equals(true); + }); + }); + + testForkedNetworkVipCommands("vip395 configures bridge", await vip395(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [39]); + await expectEvents(txResponse, [ACMAggregator_ABI], ["GrantPermissionsExecuted"], [1]); + }, + }); + + describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(ZKSYNCMAINNET_ACM, ACCESS_CONTROL_MANAGER_ABI, provider); + + it("Proposal id should be incremented", async () => { + expect(await executor.lastProposalReceived()).to.be.equals(lastProposalReceived.add(1)); + }); + it("proposal should be executed", async () => { + const pId = await executor.lastProposalReceived(); + expect(await executor.state(pId)).to.be.equals(2); + }); + it("check configuration", async () => { + // Check Timelock configurations + expect(await executor.proposalTimelocks(0)).equals(zksyncmainnet.NORMAL_TIMELOCK); + expect(await executor.proposalTimelocks(1)).equals(FAST_TRACK_TIMELOCK); + expect(await executor.proposalTimelocks(2)).equals(CRITICAL_TIMELOCK); + + // Check trusted remote + expect(await executor.trustedRemoteLookup(LzChainId.bsctestnet)).equals( + ethers.utils.solidityPack( + ["address", "address"], + [getOmnichainProposalSenderAddress(), zksyncmainnet.OMNICHAIN_GOVERNANCE_EXECUTOR], + ), + ); + + // Check receiving limit + expect(await executor.maxDailyReceiveLimit()).equals(100); + expect(await executor.last24HourCommandsReceived()).equals(4); + + // Check function registry + const functionSignatures: string[] = [ + "forceResumeReceive(uint16,bytes)", + "pause()", + "unpause()", + "setSendVersion(uint16)", + "setReceiveVersion(uint16)", + "setMaxDailyReceiveLimit(uint256)", + "setTrustedRemoteAddress(uint16,bytes)", + "setPrecrime(address)", + "setMinDstGas(uint16,uint16,uint256)", + "setPayloadSizeLimit(uint16,uint256)", + "setConfig(uint16,uint16,uint256,bytes)", + "addTimelocks(ITimelock[])", + "setTimelockPendingAdmin(address,uint8)", + "retryMessage(uint16,bytes,uint64,bytes)", + "setGuardian(address)", + "setSrcChainId(uint16)", + ]; + const getFunctionSelector = (signature: string): string => { + return ethers.utils.keccak256(ethers.utils.toUtf8Bytes(signature)).substring(0, 10); + }; + + for (const signature of functionSignatures) { + const selector = getFunctionSelector(signature); + expect(await executorOwner.functionRegistry(selector)).equals(signature); + } + }); + it("Default admin role must be revoked from ACMAggregator contract on ZKsync mainnet", async () => { + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, ZKSYNCMAINNET_ACM_AGGREGATOR)).to.be.false; + }); + it("Guardian and all timelocks are allowed to call retryMessage ", async () => { + const role = ethers.utils.solidityPack( + ["address", "string"], + [ZKSYNCMAINNET_OMNICHAIN_EXECUTOR_OWNER, "retryMessage(uint16,bytes,uint64,bytes)"], + ); + const roleHash = ethers.utils.keccak256(role); + expect(await acm.hasRole(roleHash, zksyncmainnet.GUARDIAN)).to.be.true; + expect(await acm.hasRole(roleHash, zksyncmainnet.NORMAL_TIMELOCK)).to.be.true; + expect(await acm.hasRole(roleHash, FAST_TRACK_TIMELOCK)).to.be.true; + expect(await acm.hasRole(roleHash, CRITICAL_TIMELOCK)).to.be.true; + }); + + it("Guardian is allowed to call forceResumeReceive but not timelocks", async () => { + const role = ethers.utils.solidityPack( + ["address", "string"], + [ZKSYNCMAINNET_OMNICHAIN_EXECUTOR_OWNER, "forceResumeReceive(uint16,bytes)"], + ); + const roleHash = ethers.utils.keccak256(role); + expect(await acm.hasRole(roleHash, zksyncmainnet.GUARDIAN)).to.be.true; + expect(await acm.hasRole(roleHash, zksyncmainnet.NORMAL_TIMELOCK)).to.be.false; + expect(await acm.hasRole(roleHash, FAST_TRACK_TIMELOCK)).to.be.false; + expect(await acm.hasRole(roleHash, CRITICAL_TIMELOCK)).to.be.false; + }); + it("Normal Timelock is allowed to call setSendVersion but not other timelocks and guardian", async () => { + const role = ethers.utils.solidityPack( + ["address", "string"], + [ZKSYNCMAINNET_OMNICHAIN_EXECUTOR_OWNER, "setSendVersion(uint16)"], + ); + const roleHash = ethers.utils.keccak256(role); + expect(await acm.hasRole(roleHash, zksyncmainnet.GUARDIAN)).to.be.false; + expect(await acm.hasRole(roleHash, zksyncmainnet.NORMAL_TIMELOCK)).to.be.true; + expect(await acm.hasRole(roleHash, FAST_TRACK_TIMELOCK)).to.be.false; + expect(await acm.hasRole(roleHash, CRITICAL_TIMELOCK)).to.be.false; + }); + }); +}); diff --git a/src/networkAddresses.ts b/src/networkAddresses.ts index d52ab09b3..3c17f05f4 100644 --- a/src/networkAddresses.ts +++ b/src/networkAddresses.ts @@ -180,7 +180,7 @@ export const NETWORK_ADDRESSES = { OMNICHAIN_GOVERNANCE_EXECUTOR: "0x83F79CfbaEee738173c0dfd866796743F4E25C9e", }, zksyncmainnet: { - NORMAL_TIMELOCK: "", // To be deployed + NORMAL_TIMELOCK: "0x093565Bc20AA326F4209eBaF3a26089272627613", GUARDIAN: "0x751Aa759cfBB6CE71A43b48e40e1cCcFC66Ba4aa", VTREASURY: "0xB2e9174e23382f7744CebF7e0Be54cA001D95599", XVS: "0xD78ABD81a3D57712a3af080dc4185b698Fe9ac5A", @@ -189,6 +189,9 @@ export const NETWORK_ADDRESSES = { POOL_REGISTRY: "0xFD96B926298034aed9bBe0Cca4b651E41eB87Bc4", XVS_VAULT_PROXY: "0xbbB3C88192a5B0DB759229BeF49DcD1f168F326F", GENERIC_TEST_USER_ACCOUNT: "0x6f057A858171e187124ddEDF034dAc63De5dE5dB", + ENDPOINT: "0x9b896c0e23220469C7AE69cb4BbAE391eAa4C8da", + LZ_LIBRARY: "0x042b8289c97896529Ec2FE49ba1A8B9C956A86cC", + OMNICHAIN_GOVERNANCE_EXECUTOR: "0xA1b56f19CA5E5b15EF29d38238930Ce9f0235312", }, opsepolia: { NORMAL_TIMELOCK: "", // To be deployed diff --git a/vips/vip-395/bscmainnet.ts b/vips/vip-395/bscmainnet.ts new file mode 100644 index 000000000..e9cf269a9 --- /dev/null +++ b/vips/vip-395/bscmainnet.ts @@ -0,0 +1,64 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +const { zksyncmainnet } = NETWORK_ADDRESSES; +export const OMNICHAIN_PROPOSAL_SENDER = "0x36a69dE601381be7b0DcAc5D5dD058825505F8f6"; + +export const ZKSYNCMAINNET_OMNICHAIN_EXECUTOR_OWNER = "0xdfaed3E5d9707629Ed5c225b4fB980c064286771"; +export const ZKSYNCMAINNET_ACM = "0x526159A92A82afE5327d37Ef446b68FD9a5cA914"; +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; +export const ZKSYNCMAINNET_ACM_AGGREGATOR = "0x88B1452e512c8fcf83889DdCfe54dF37D561Db82"; +export const MAX_DAILY_LIMIT = 100; + +const vip395 = () => { + const meta = { + version: "v2", + title: "VIP-395 Enable Multichain Governance on zksync mainnet", + description: `### Summary`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: OMNICHAIN_PROPOSAL_SENDER, + signature: "setMaxDailyLimit(uint16,uint256)", + params: [LzChainId.zksyncmainnet, MAX_DAILY_LIMIT], + }, + { + target: OMNICHAIN_PROPOSAL_SENDER, + signature: "setTrustedRemoteAddress(uint16,bytes)", + params: [LzChainId.zksyncmainnet, zksyncmainnet.OMNICHAIN_GOVERNANCE_EXECUTOR], + }, + { + target: ZKSYNCMAINNET_OMNICHAIN_EXECUTOR_OWNER, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.zksyncmainnet, + }, + { + target: ZKSYNCMAINNET_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ZKSYNCMAINNET_ACM_AGGREGATOR], + dstChainId: LzChainId.zksyncmainnet, + }, + { + target: ZKSYNCMAINNET_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.zksyncmainnet, + }, + { + target: ZKSYNCMAINNET_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ZKSYNCMAINNET_ACM_AGGREGATOR], + dstChainId: LzChainId.zksyncmainnet, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip395; From b8c89158e2e9cd6d77d8a4e1ffe471f4bd5f3e0c Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Wed, 6 Nov 2024 18:36:15 +0100 Subject: [PATCH 108/178] feat: add refund for the community wallet for the bootstrap liquidity --- simulations/vip-389/bscmainnet.ts | 31 +++++++++++++++++++++++++++++-- vips/vip-389/bscmainnet.ts | 11 +++++++++-- 2 files changed, 38 insertions(+), 4 deletions(-) diff --git a/simulations/vip-389/bscmainnet.ts b/simulations/vip-389/bscmainnet.ts index afa63efa3..29721ac6f 100644 --- a/simulations/vip-389/bscmainnet.ts +++ b/simulations/vip-389/bscmainnet.ts @@ -1,9 +1,27 @@ +import { expect } from "chai"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; + import { expectEvents } from "../../src/utils"; import { forking, testVip } from "../../src/vip-framework"; -import vip389 from "../../vips/vip-389/bscmainnet"; +import vip389, { COMMUNITY_WALLET, USDC } from "../../vips/vip-389/bscmainnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; +import ERC20_ABI from "./abi/erc20.json"; + +const { bscmainnet } = NETWORK_ADDRESSES; + +forking(43777987, async () => { + let oldUsdcWalletBalance: BigNumber; + let oldUsdcTreasuryBalance: BigNumber; + let usdc: Contract; + + before(async () => { + usdc = new ethers.Contract(USDC, ERC20_ABI, ethers.provider); + oldUsdcWalletBalance = await usdc.balanceOf(COMMUNITY_WALLET); + oldUsdcTreasuryBalance = await usdc.balanceOf(bscmainnet.VTREASURY); + }); -forking(45188496, async () => { testVip("vip389", await vip389(), { callbackAfterExecution: async txResponse => { await expectEvents( @@ -14,4 +32,13 @@ forking(45188496, async () => { ); }, }); + + describe("Post-VIP behavior", async () => { + it("Verify that the community wallet has received the correct amount of USDC", async () => { + const walletBalance = await usdc.balanceOf(COMMUNITY_WALLET); + const treasuryBalance = await usdc.balanceOf(bscmainnet.VTREASURY); + expect(walletBalance).to.eq(oldUsdcWalletBalance.add(parseUnits("5000", 18))); + expect(treasuryBalance).to.eq(oldUsdcTreasuryBalance.sub(parseUnits("5000", 18))); + }); + }); }); diff --git a/vips/vip-389/bscmainnet.ts b/vips/vip-389/bscmainnet.ts index 1e524259d..ff21bd4d5 100644 --- a/vips/vip-389/bscmainnet.ts +++ b/vips/vip-389/bscmainnet.ts @@ -4,10 +4,12 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { LzChainId, ProposalType } from "src/types"; import { makeProposal } from "src/utils"; -const { ethereum } = NETWORK_ADDRESSES; +const { bscmainnet, ethereum } = NETWORK_ADDRESSES; +export const COMMUNITY_WALLET = "0xc444949e0054A23c44Fc45789738bdF64aed2391"; +export const USDC = "0x8AC76a51cc950d9822D68b83fE1Ad97B32Cd580d"; export const EIGEN = "0xec53bF9167f50cDEB3Ae105f56099aaaB9061F83"; -const INITIAL_SUPPLY = parseUnits("500", 18); +const INITIAL_SUPPLY = parseUnits("1854.883016", 18); export const SUPPLY_CAP = parseUnits("3000000", 18); export const BORROW_CAP = parseUnits("1500000", 18); const CF = parseUnits("0.5", 18); @@ -42,6 +44,11 @@ const vip389 = () => { }; return makeProposal( [ + { + target: bscmainnet.VTREASURY, + signature: "withdrawTreasuryBEP20(address,uint256,address)", + params: [USDC, parseUnits("5000", 18), COMMUNITY_WALLET], + }, { target: ethereum.CHAINLINK_ORACLE, signature: "setTokenConfig((address,address,uint256))", From b11f1653638fa5cd492af59ddefbe71a5da9a580 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Wed, 6 Nov 2024 18:57:01 +0100 Subject: [PATCH 109/178] feat: set ID and description for VIP 393 --- .../abi/OmnichainProposalSender.json | 0 .../abi/PoolRegistry.json | 0 .../abi/PrimeConverter.json | 0 .../abi/ResilientOracle.json | 0 .../{vip-389 => vip-393}/abi/comptroller.json | 0 .../{vip-389 => vip-393}/abi/erc20.json | 0 .../{vip-389 => vip-393}/abi/vToken.json | 0 .../{vip-389 => vip-393}/bscmainnet.ts | 5 +- .../{vip-389 => vip-393}/bsctestnet.ts | 4 +- simulations/{vip-389 => vip-393}/ethereum.ts | 8 +-- simulations/{vip-389 => vip-393}/sepolia.ts | 6 +- vips/{vip-389 => vip-393}/bscmainnet.ts | 57 +++++++++++++++++-- vips/{vip-389 => vip-393}/bsctestnet.ts | 6 +- 13 files changed, 68 insertions(+), 18 deletions(-) rename simulations/{vip-389 => vip-393}/abi/OmnichainProposalSender.json (100%) rename simulations/{vip-389 => vip-393}/abi/PoolRegistry.json (100%) rename simulations/{vip-389 => vip-393}/abi/PrimeConverter.json (100%) rename simulations/{vip-389 => vip-393}/abi/ResilientOracle.json (100%) rename simulations/{vip-389 => vip-393}/abi/comptroller.json (100%) rename simulations/{vip-389 => vip-393}/abi/erc20.json (100%) rename simulations/{vip-389 => vip-393}/abi/vToken.json (100%) rename simulations/{vip-389 => vip-393}/bscmainnet.ts (90%) rename simulations/{vip-389 => vip-393}/bsctestnet.ts (83%) rename simulations/{vip-389 => vip-393}/ethereum.ts (97%) rename simulations/{vip-389 => vip-393}/sepolia.ts (98%) rename vips/{vip-389 => vip-393}/bscmainnet.ts (63%) rename vips/{vip-389 => vip-393}/bsctestnet.ts (98%) diff --git a/simulations/vip-389/abi/OmnichainProposalSender.json b/simulations/vip-393/abi/OmnichainProposalSender.json similarity index 100% rename from simulations/vip-389/abi/OmnichainProposalSender.json rename to simulations/vip-393/abi/OmnichainProposalSender.json diff --git a/simulations/vip-389/abi/PoolRegistry.json b/simulations/vip-393/abi/PoolRegistry.json similarity index 100% rename from simulations/vip-389/abi/PoolRegistry.json rename to simulations/vip-393/abi/PoolRegistry.json diff --git a/simulations/vip-389/abi/PrimeConverter.json b/simulations/vip-393/abi/PrimeConverter.json similarity index 100% rename from simulations/vip-389/abi/PrimeConverter.json rename to simulations/vip-393/abi/PrimeConverter.json diff --git a/simulations/vip-389/abi/ResilientOracle.json b/simulations/vip-393/abi/ResilientOracle.json similarity index 100% rename from simulations/vip-389/abi/ResilientOracle.json rename to simulations/vip-393/abi/ResilientOracle.json diff --git a/simulations/vip-389/abi/comptroller.json b/simulations/vip-393/abi/comptroller.json similarity index 100% rename from simulations/vip-389/abi/comptroller.json rename to simulations/vip-393/abi/comptroller.json diff --git a/simulations/vip-389/abi/erc20.json b/simulations/vip-393/abi/erc20.json similarity index 100% rename from simulations/vip-389/abi/erc20.json rename to simulations/vip-393/abi/erc20.json diff --git a/simulations/vip-389/abi/vToken.json b/simulations/vip-393/abi/vToken.json similarity index 100% rename from simulations/vip-389/abi/vToken.json rename to simulations/vip-393/abi/vToken.json diff --git a/simulations/vip-389/bscmainnet.ts b/simulations/vip-393/bscmainnet.ts similarity index 90% rename from simulations/vip-389/bscmainnet.ts rename to simulations/vip-393/bscmainnet.ts index 29721ac6f..0871072de 100644 --- a/simulations/vip-389/bscmainnet.ts +++ b/simulations/vip-393/bscmainnet.ts @@ -1,11 +1,12 @@ import { expect } from "chai"; +import { BigNumber, Contract } from "ethers"; import { parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents } from "../../src/utils"; import { forking, testVip } from "../../src/vip-framework"; -import vip389, { COMMUNITY_WALLET, USDC } from "../../vips/vip-389/bscmainnet"; +import vip393, { COMMUNITY_WALLET, USDC } from "../../vips/vip-393/bscmainnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; import ERC20_ABI from "./abi/erc20.json"; @@ -22,7 +23,7 @@ forking(43777987, async () => { oldUsdcTreasuryBalance = await usdc.balanceOf(bscmainnet.VTREASURY); }); - testVip("vip389", await vip389(), { + testVip("vip393", await vip393(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-389/bsctestnet.ts b/simulations/vip-393/bsctestnet.ts similarity index 83% rename from simulations/vip-389/bsctestnet.ts rename to simulations/vip-393/bsctestnet.ts index eb67a2f70..1587e96be 100644 --- a/simulations/vip-389/bsctestnet.ts +++ b/simulations/vip-393/bsctestnet.ts @@ -1,10 +1,10 @@ import { expectEvents } from "../../src/utils"; import { forking, testVip } from "../../src/vip-framework"; -import vip389 from "../../vips/vip-389/bsctestnet"; +import vip393 from "../../vips/vip-393/bsctestnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; forking(45188496, async () => { - testVip("vip389", await vip389(), { + testVip("vip393", await vip393(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-389/ethereum.ts b/simulations/vip-393/ethereum.ts similarity index 97% rename from simulations/vip-389/ethereum.ts rename to simulations/vip-393/ethereum.ts index 50edb32de..3d2184208 100644 --- a/simulations/vip-389/ethereum.ts +++ b/simulations/vip-393/ethereum.ts @@ -9,7 +9,7 @@ import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIs import { checkVToken } from "src/vip-framework/checks/checkVToken"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; -import vip389, { +import vip393, { BORROW_CAP, BaseAssets, CORE_COMPTROLLER, @@ -17,7 +17,7 @@ import vip389, { SUPPLY_CAP, USDT_PRIME_CONVERTER, vEIGEN, -} from "../../vips/vip-389/bscmainnet"; +} from "../../vips/vip-393/bscmainnet"; import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; import PRIME_CONVERTER_ABI from "./abi/PrimeConverter.json"; import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; @@ -30,7 +30,7 @@ const PROTOCOL_SHARE_RESERVE = "0x8c8c8530464f7D95552A11eC31Adbd4dC4AC4d3E"; const USDT_USER = "0xF977814e90dA44bFA03b6295A0616a897441aceC"; const EIGEN_USER = "0x56A59D9cF7bc539ADc29537280023543C5c38A00"; -forking(6969766, async () => { +forking(21130180, async () => { let resilientOracle: Contract; let poolRegistry: Contract; let vEIGENContract: Contract; @@ -58,7 +58,7 @@ forking(6969766, async () => { usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); }); - testForkedNetworkVipCommands("vip389", await vip389()); + testForkedNetworkVipCommands("vip393", await vip393()); describe("Post-VIP behavior", async () => { it("check price", async () => { diff --git a/simulations/vip-389/sepolia.ts b/simulations/vip-393/sepolia.ts similarity index 98% rename from simulations/vip-389/sepolia.ts rename to simulations/vip-393/sepolia.ts index cb1cd52ea..ed820519d 100644 --- a/simulations/vip-389/sepolia.ts +++ b/simulations/vip-393/sepolia.ts @@ -9,7 +9,7 @@ import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIs import { checkVToken } from "src/vip-framework/checks/checkVToken"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; -import vip389, { +import vip393, { BORROW_CAP, BaseAssets, CORE_COMPTROLLER, @@ -18,7 +18,7 @@ import vip389, { SUPPLY_CAP, USDT_PRIME_CONVERTER, vEIGEN, -} from "../../vips/vip-389/bsctestnet"; +} from "../../vips/vip-393/bsctestnet"; import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; import PRIME_CONVERTER_ABI from "./abi/PrimeConverter.json"; import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; @@ -56,7 +56,7 @@ forking(6969766, async () => { usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); }); - testForkedNetworkVipCommands("vip389", await vip389()); + testForkedNetworkVipCommands("vip393", await vip393()); describe("Post-VIP behavior", async () => { it("check price", async () => { diff --git a/vips/vip-389/bscmainnet.ts b/vips/vip-393/bscmainnet.ts similarity index 63% rename from vips/vip-389/bscmainnet.ts rename to vips/vip-393/bscmainnet.ts index ff21bd4d5..5860813fb 100644 --- a/vips/vip-389/bscmainnet.ts +++ b/vips/vip-393/bscmainnet.ts @@ -33,11 +33,60 @@ const CONVERSION_INCENTIVE = parseUnits("0.0001", 18); const CHAINLINK_FEED = "0xf2917e602C2dCa458937fad715bb1E465305A4A1"; const MAX_STALE_PERIOD = 30 * 3600; -const vip389 = () => { +const vip393 = () => { const meta = { version: "v2", - title: "VIP-389", - description: `### Description`, + title: "VIP-393 [Ethereum] New EIGEN market in the Core pool", + description: `####Summary + +If passed, following the Community proposal “[Support EIGEN as collateral on Venus Protocol Ethereum Core Pool](https://community.venus.io/t/support-eigen-as-collateral-on-venus-protocol-ethereum-core-pool/4615)” and [the associated snapshot](https://snapshot.org/#/venus-xvs.eth/proposal/0x171c3ffba6886856609e3db5b2a701a4cdeb73ab91fb7a165387475234729b6b), this VIP adds a market for [EIGEN](https://etherscan.io/address/0xec53bf9167f50cdeb3ae105f56099aaab9061f83) into the Core pool on Ethereum, and refunds the [Community Wallet](https://bscscan.com/address/0xc444949e0054A23c44Fc45789738bdF64aed2391) the provided bootstrap liquidity. + +#### Description + +#### Risk parameters + +Following [Chaos Labs recommendations](https://community.venus.io/t/support-eigen-as-collateral-on-venus-protocol-ethereum-core-pool/4615/8), the risk parameters for the new market are: + +Underlying token: [EIGEN](https://etherscan.io/address/0xec53bf9167f50cdeb3ae105f56099aaab9061f83) + +- Borrow cap: 1,500,000 +- Supply cap: 3,000,000 +- Collateral factor: 50% +- Liquidation threshold: 60% +- Reserve factor: 25% + +Bootstrap liquidity: 1,854.88 EIGEN - provided by the [Venus Treasury](https://bscscan.com/address/0xf322942f644a996a617bd29c16bd7d231d9f35e9). + +Interest rate curve for the new market: + +- kink: 45% +- base (yearly): 2% +- multiplier (yearly): 15% +- jump multiplier (yearly): 300% + +#### Oracles configuration + +The [ResilientOracle](https://docs-v4.venus.io/risk/resilient-price-oracle) deployed to [Ethereum](https://etherscan.io/address/0xd2ce3fb018805ef92b8C5976cb31F84b4E295F94) is used for EIGEN, with the [Chainlink feed](https://etherscan.io/address/0xf2917e602C2dCa458937fad715bb1E465305A4A1) for this asset as the main oracle. + +#### Security and additional considerations + +We applied the following security procedures for this upgrade: + +- **VIP execution simulation**: in a simulation environment, validating the new market is properly added to the Core pool on Ethereum, with the right parameters and the expected bootstrap liquidity +- **Deployment on testnet**: the same market has been deployed to Sepolia, and used in the Venus Protocol testnet deployment + +The Community Wallet [provided the bootstrap liquidity](https://etherscan.io/tx/0x84c524c8f37f3cb30cad66befe760ad46d51dbfdf371a1347c82d3cbe76df50e) (1,854.88 EIGEN), spending 5,000 USDC, that will be refunded in this VIP with funds from the Venus Treasury on BNB Chain. + +#### Deployed contracts + +- Mainnet vEIGEN_Core: [0x256AdDBe0a387c98f487e44b85c29eb983413c5e](https://etherscan.io/address/0x256AdDBe0a387c98f487e44b85c29eb983413c5e) +- Testnet vEIGEN_Core: [0x6DB4aDbA8F144a57a397b57183BF619e957040B1](https://sepolia.etherscan.io/address/0x6DB4aDbA8F144a57a397b57183BF619e957040B1) + +#### References + +- [VIP simulation](https://github.com/VenusProtocol/vips/pull/419) +- [Deployment to Sepolia](https://testnet.bscscan.com/tx/0xde0347163b1259ea955c3e83ffd9de7d856e9adbacc4f1b84cd24a06c05a0aaa) +- [Documentation](https://docs-v4.venus.io/)`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", @@ -142,4 +191,4 @@ const vip389 = () => { ProposalType.REGULAR, ); }; -export default vip389; +export default vip393; diff --git a/vips/vip-389/bsctestnet.ts b/vips/vip-393/bsctestnet.ts similarity index 98% rename from vips/vip-389/bsctestnet.ts rename to vips/vip-393/bsctestnet.ts index 939501f98..d7c1ef95b 100644 --- a/vips/vip-389/bsctestnet.ts +++ b/vips/vip-393/bsctestnet.ts @@ -30,10 +30,10 @@ export const BaseAssets = [ ]; const CONVERSION_INCENTIVE = parseUnits("0.0001", 18); -const vip389 = () => { +const vip393 = () => { const meta = { version: "v2", - title: "VIP-389", + title: "VIP-393", description: `### Description`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", @@ -134,4 +134,4 @@ const vip389 = () => { ProposalType.REGULAR, ); }; -export default vip389; +export default vip393; From d8d9634bc171bb7fa4cabd994cc28f0c6dffd478 Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 6 Nov 2024 22:15:34 +0400 Subject: [PATCH 110/178] fix: wip - fix simulation --- simulations/vip-391/bscmainnet.ts | 2 +- simulations/vip-391/ethereum.ts | 13 +++++++++---- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/simulations/vip-391/bscmainnet.ts b/simulations/vip-391/bscmainnet.ts index c3930af70..b65bd66fb 100644 --- a/simulations/vip-391/bscmainnet.ts +++ b/simulations/vip-391/bscmainnet.ts @@ -3,7 +3,7 @@ import { forking, testVip } from "../../src/vip-framework"; import vip391 from "../../vips/vip-391/bscmainnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; -forking(45194889, async () => { +forking(43778615, async () => { testVip("vip391", await vip391(), { callbackAfterExecution: async txResponse => { await expectEvents( diff --git a/simulations/vip-391/ethereum.ts b/simulations/vip-391/ethereum.ts index b0b017021..be330c142 100644 --- a/simulations/vip-391/ethereum.ts +++ b/simulations/vip-391/ethereum.ts @@ -17,20 +17,21 @@ import vip391, { USDT_PRIME_CONVERTER, eBTC, veBTC, -} from "../../vips/vip-391/bsctestnet"; +} from "../../vips/vip-391/bscmainnet"; import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; import PRIME_CONVERTER_ABI from "./abi/PrimeConverter.json"; import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; import COMPTROLLER_ABI from "./abi/comptroller.json"; import ERC20_ABI from "./abi/erc20.json"; import VTOKEN_ABI from "./abi/vToken.json"; +import { setMaxStalePeriod, setMaxStalePeriodInChainlinkOracle } from "src/utils"; const { ethereum } = NETWORK_ADDRESSES; const PROTOCOL_SHARE_RESERVE = "0x8c8c8530464f7D95552A11eC31Adbd4dC4AC4d3E"; const USDT_USER = "0xF977814e90dA44bFA03b6295A0616a897441aceC"; const eBTC_USER = "0x7aCDF2012aAC69D70B86677FE91eb66e08961880"; -forking(6976822, async () => { +forking(21130278, async () => { let resilientOracle: Contract; let poolRegistry: Contract; let veBTCContract: Contract; @@ -38,6 +39,7 @@ forking(6976822, async () => { let eBTCContract: Contract; let usdtPrimeConverter: Contract; let usdt: Contract; + let wbtc: Contract; before(async () => { await impersonateAccount(ethereum.NORMAL_TIMELOCK); @@ -56,14 +58,17 @@ forking(6976822, async () => { eBTCContract = await ethers.getContractAt(ERC20_ABI, eBTC, await ethers.getSigner(ethereum.NORMAL_TIMELOCK)); usdtPrimeConverter = await ethers.getContractAt(PRIME_CONVERTER_ABI, USDT_PRIME_CONVERTER); usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); + wbtc = await ethers.getContractAt(ERC20_ABI, "0x2260fac5e5542a773aa44fbcfedf7c193bc2c599", await ethers.getSigner(ethereum.NORMAL_TIMELOCK)); + + await setMaxStalePeriod(resilientOracle, wbtc, 10000000000); }); testForkedNetworkVipCommands("vip391", await vip391()); describe("Post-VIP behavior", async () => { it("check price", async () => { - expect(await resilientOracle.getPrice(eBTC)).to.be.equal(parseUnits("71835.7052865100", 28)); - expect(await resilientOracle.getUnderlyingPrice(veBTC)).to.be.equal(parseUnits("71835.7052865100", 28)); + expect(await resilientOracle.getPrice(eBTC)).to.be.equal(parseUnits("74599", 28)); + expect(await resilientOracle.getUnderlyingPrice(veBTC)).to.be.equal(parseUnits("74599", 28)); }); it("should have 10 markets in core pool", async () => { From 1589ef0060f9be31d50140e9b322a405b46ab2f4 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Thu, 7 Nov 2024 00:51:33 +0100 Subject: [PATCH 111/178] feat: get bootstrap liquidity for EIGEN from the Normal timelock --- simulations/vip-393/bscmainnet.ts | 4 ++-- simulations/vip-393/ethereum.ts | 14 ++++++++------ vips/vip-393/bscmainnet.ts | 20 ++++---------------- 3 files changed, 14 insertions(+), 24 deletions(-) diff --git a/simulations/vip-393/bscmainnet.ts b/simulations/vip-393/bscmainnet.ts index 0871072de..c77e8244f 100644 --- a/simulations/vip-393/bscmainnet.ts +++ b/simulations/vip-393/bscmainnet.ts @@ -38,8 +38,8 @@ forking(43777987, async () => { it("Verify that the community wallet has received the correct amount of USDC", async () => { const walletBalance = await usdc.balanceOf(COMMUNITY_WALLET); const treasuryBalance = await usdc.balanceOf(bscmainnet.VTREASURY); - expect(walletBalance).to.eq(oldUsdcWalletBalance.add(parseUnits("5000", 18))); - expect(treasuryBalance).to.eq(oldUsdcTreasuryBalance.sub(parseUnits("5000", 18))); + expect(walletBalance).to.eq(oldUsdcWalletBalance.add(parseUnits("6000", 18))); + expect(treasuryBalance).to.eq(oldUsdcTreasuryBalance.sub(parseUnits("6000", 18))); }); }); }); diff --git a/simulations/vip-393/ethereum.ts b/simulations/vip-393/ethereum.ts index 3d2184208..98727b224 100644 --- a/simulations/vip-393/ethereum.ts +++ b/simulations/vip-393/ethereum.ts @@ -30,7 +30,9 @@ const PROTOCOL_SHARE_RESERVE = "0x8c8c8530464f7D95552A11eC31Adbd4dC4AC4d3E"; const USDT_USER = "0xF977814e90dA44bFA03b6295A0616a897441aceC"; const EIGEN_USER = "0x56A59D9cF7bc539ADc29537280023543C5c38A00"; -forking(21130180, async () => { +const ONE_YEAR = 365 * 24 * 3600; + +forking(21131771, async () => { let resilientOracle: Contract; let poolRegistry: Contract; let vEIGENContract: Contract; @@ -58,12 +60,12 @@ forking(21130180, async () => { usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); }); - testForkedNetworkVipCommands("vip393", await vip393()); + testForkedNetworkVipCommands("vip393", await vip393(ONE_YEAR)); describe("Post-VIP behavior", async () => { it("check price", async () => { - expect(await resilientOracle.getPrice(EIGEN)).to.be.equal(parseUnits("3.0196419", 18)); - expect(await resilientOracle.getUnderlyingPrice(vEIGEN)).to.be.equal(parseUnits("3.0196419", 18)); + expect(await resilientOracle.getPrice(EIGEN)).to.be.equal(parseUnits("2.94577903", 18)); + expect(await resilientOracle.getUnderlyingPrice(vEIGEN)).to.be.equal(parseUnits("2.94577903", 18)); }); it("should have 10 markets in core pool", async () => { @@ -81,7 +83,7 @@ forking(21130180, async () => { }); it("check supply", async () => { - const expectedSupply = parseUnits("500", 8); + const expectedSupply = parseUnits("349.618192", 8); expect(await vEIGENContract.balanceOf(ethereum.VTREASURY)).to.equal(expectedSupply); }); @@ -105,7 +107,7 @@ forking(21130180, async () => { }); it("check protocol seize share", async () => { - expect(await vEIGENContract.protocolSeizeShareMantissa()).equals(parseUnits("0.01", 18)); + expect(await vEIGENContract.protocolSeizeShareMantissa()).equals(parseUnits("0.05", 18)); }); it("check vToken", async () => { diff --git a/vips/vip-393/bscmainnet.ts b/vips/vip-393/bscmainnet.ts index 5860813fb..f952e2a8c 100644 --- a/vips/vip-393/bscmainnet.ts +++ b/vips/vip-393/bscmainnet.ts @@ -9,7 +9,7 @@ export const COMMUNITY_WALLET = "0xc444949e0054A23c44Fc45789738bdF64aed2391"; export const USDC = "0x8AC76a51cc950d9822D68b83fE1Ad97B32Cd580d"; export const EIGEN = "0xec53bF9167f50cDEB3Ae105f56099aaaB9061F83"; -const INITIAL_SUPPLY = parseUnits("1854.883016", 18); +const INITIAL_SUPPLY = parseUnits("349.618192", 18); export const SUPPLY_CAP = parseUnits("3000000", 18); export const BORROW_CAP = parseUnits("1500000", 18); const CF = parseUnits("0.5", 18); @@ -33,7 +33,7 @@ const CONVERSION_INCENTIVE = parseUnits("0.0001", 18); const CHAINLINK_FEED = "0xf2917e602C2dCa458937fad715bb1E465305A4A1"; const MAX_STALE_PERIOD = 30 * 3600; -const vip393 = () => { +const vip393 = (maxStalePeriod?: number) => { const meta = { version: "v2", title: "VIP-393 [Ethereum] New EIGEN market in the Core pool", @@ -96,12 +96,12 @@ The Community Wallet [provided the bootstrap liquidity](https://etherscan.io/tx/ { target: bscmainnet.VTREASURY, signature: "withdrawTreasuryBEP20(address,uint256,address)", - params: [USDC, parseUnits("5000", 18), COMMUNITY_WALLET], + params: [USDC, parseUnits("6000", 18), COMMUNITY_WALLET], }, { target: ethereum.CHAINLINK_ORACLE, signature: "setTokenConfig((address,address,uint256))", - params: [[EIGEN, CHAINLINK_FEED, MAX_STALE_PERIOD]], + params: [[EIGEN, CHAINLINK_FEED, maxStalePeriod || MAX_STALE_PERIOD]], dstChainId: LzChainId.ethereum, }, { @@ -118,12 +118,6 @@ The Community Wallet [provided the bootstrap liquidity](https://etherscan.io/tx/ }, // Add Market - { - target: ethereum.VTREASURY, - signature: "withdrawTreasuryToken(address,uint256,address)", - params: [EIGEN, INITIAL_SUPPLY, ethereum.GUARDIAN], - dstChainId: LzChainId.ethereum, - }, { target: EIGEN, signature: "approve(address,uint256)", @@ -148,12 +142,6 @@ The Community Wallet [provided the bootstrap liquidity](https://etherscan.io/tx/ params: [[vEIGEN, CF, LT, INITIAL_SUPPLY, ethereum.VTREASURY, SUPPLY_CAP, BORROW_CAP]], dstChainId: LzChainId.ethereum, }, - { - target: vEIGEN, - signature: "setProtocolSeizeShare(uint256)", - params: [parseUnits("0.01", 18)], - dstChainId: LzChainId.ethereum, - }, // Conversion config { From 54e8d2433749ee8a456a5ddde5544d323e102e5e Mon Sep 17 00:00:00 2001 From: web3rover Date: Thu, 7 Nov 2024 11:39:35 +0400 Subject: [PATCH 112/178] fix: fixed conversion test --- simulations/vip-393/ethereum.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/simulations/vip-393/ethereum.ts b/simulations/vip-393/ethereum.ts index 98727b224..a3b14822f 100644 --- a/simulations/vip-393/ethereum.ts +++ b/simulations/vip-393/ethereum.ts @@ -4,6 +4,7 @@ import { BigNumber, Contract } from "ethers"; import { parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { setMaxStalePeriod } from "src/utils"; import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIsolatedPoolsComptrollers"; import { checkVToken } from "src/vip-framework/checks/checkVToken"; @@ -58,6 +59,8 @@ forking(21131771, async () => { eigenContract = await ethers.getContractAt(ERC20_ABI, EIGEN, await ethers.getSigner(ethereum.NORMAL_TIMELOCK)); usdtPrimeConverter = await ethers.getContractAt(PRIME_CONVERTER_ABI, USDT_PRIME_CONVERTER); usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); + + await setMaxStalePeriod(resilientOracle, usdt, ONE_YEAR); }); testForkedNetworkVipCommands("vip393", await vip393(ONE_YEAR)); @@ -152,7 +155,7 @@ forking(21131771, async () => { const usdtBalanceAfter = await usdt.balanceOf(USDT_USER); const eigenBalanceAfter = await eigenContract.balanceOf(USDT_USER); - expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("6.999301", 6)); + expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("5.890787", 6)); expect(eigenBalanceAfter.sub(eigenBalanceBefore)).to.be.equal(eigenAmount); }); }); From 6b320e415fc90efe04fa37179987db4afca9bccc Mon Sep 17 00:00:00 2001 From: web3rover Date: Thu, 7 Nov 2024 15:34:55 +0400 Subject: [PATCH 113/178] fix: transfer eigen from treasury to timelock --- multisig/proposals/ethereum/vip-067/index.ts | 21 +++ .../ethereum/vip-067/abi/erc20.json | 134 ++++++++++++++++++ .../simulations/ethereum/vip-067/index.ts | 27 ++++ simulations/vip-393/ethereum.ts | 7 +- vips/vip-393/bscmainnet.ts | 2 +- 5 files changed, 188 insertions(+), 3 deletions(-) create mode 100644 multisig/proposals/ethereum/vip-067/index.ts create mode 100644 multisig/simulations/ethereum/vip-067/abi/erc20.json create mode 100644 multisig/simulations/ethereum/vip-067/index.ts diff --git a/multisig/proposals/ethereum/vip-067/index.ts b/multisig/proposals/ethereum/vip-067/index.ts new file mode 100644 index 000000000..bdc8c3994 --- /dev/null +++ b/multisig/proposals/ethereum/vip-067/index.ts @@ -0,0 +1,21 @@ +import { parseUnits } from "ethers/lib/utils"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; + +import { makeProposal } from "../../../../src/utils"; + +const { ethereum } = NETWORK_ADDRESSES; + +export const EIGEN = "0xec53bF9167f50cDEB3Ae105f56099aaaB9061F83"; +export const INITIAL_SUPPLY = parseUnits("1854.883016", 18); + +export const vip067 = () => { + return makeProposal([ + { + target: ethereum.VTREASURY, + signature: "withdrawTreasuryToken(address,uint256,address)", + params: [EIGEN, INITIAL_SUPPLY, ethereum.NORMAL_TIMELOCK], + }, + ]); +}; + +export default vip067; diff --git a/multisig/simulations/ethereum/vip-067/abi/erc20.json b/multisig/simulations/ethereum/vip-067/abi/erc20.json new file mode 100644 index 000000000..3a509c9c4 --- /dev/null +++ b/multisig/simulations/ethereum/vip-067/abi/erc20.json @@ -0,0 +1,134 @@ +[ + { + "inputs": [ + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "name": "faucet", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "from", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-067/index.ts b/multisig/simulations/ethereum/vip-067/index.ts new file mode 100644 index 000000000..5e44d85f8 --- /dev/null +++ b/multisig/simulations/ethereum/vip-067/index.ts @@ -0,0 +1,27 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; + +import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; +import vip067, { EIGEN } from "../../../proposals/ethereum/vip-067"; +import ERC20_ABI from "./abi/erc20.json"; + +forking(21135461, async () => { + let eigenContract: Contract; + + describe("Post-VIP behavior", async () => { + before(async () => { + eigenContract = new ethers.Contract(EIGEN, ERC20_ABI, ethers.provider); + await pretendExecutingVip(await vip067()); + }); + + it("check balance", async () => { + expect(await eigenContract.balanceOf(NETWORK_ADDRESSES.ethereum.NORMAL_TIMELOCK)).to.equal( + parseUnits("2204.501208", 18), + ); + expect(await eigenContract.balanceOf(NETWORK_ADDRESSES.ethereum.VTREASURY)).to.equal(0); + }); + }); +}); diff --git a/simulations/vip-393/ethereum.ts b/simulations/vip-393/ethereum.ts index a3b14822f..6e9464b61 100644 --- a/simulations/vip-393/ethereum.ts +++ b/simulations/vip-393/ethereum.ts @@ -5,11 +5,12 @@ import { parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { setMaxStalePeriod } from "src/utils"; -import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIsolatedPoolsComptrollers"; import { checkVToken } from "src/vip-framework/checks/checkVToken"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; +import vip067 from "../../multisig/proposals/ethereum/vip-067"; import vip393, { BORROW_CAP, BaseAssets, @@ -43,6 +44,8 @@ forking(21131771, async () => { let usdt: Contract; before(async () => { + await pretendExecutingVip(await vip067()); + await impersonateAccount(ethereum.NORMAL_TIMELOCK); await setBalance(ethereum.NORMAL_TIMELOCK, parseUnits("1000", 18)); await impersonateAccount(USDT_USER); @@ -86,7 +89,7 @@ forking(21131771, async () => { }); it("check supply", async () => { - const expectedSupply = parseUnits("349.618192", 8); + const expectedSupply = parseUnits("2204.50120800", 8); expect(await vEIGENContract.balanceOf(ethereum.VTREASURY)).to.equal(expectedSupply); }); diff --git a/vips/vip-393/bscmainnet.ts b/vips/vip-393/bscmainnet.ts index f952e2a8c..5b834736a 100644 --- a/vips/vip-393/bscmainnet.ts +++ b/vips/vip-393/bscmainnet.ts @@ -9,7 +9,7 @@ export const COMMUNITY_WALLET = "0xc444949e0054A23c44Fc45789738bdF64aed2391"; export const USDC = "0x8AC76a51cc950d9822D68b83fE1Ad97B32Cd580d"; export const EIGEN = "0xec53bF9167f50cDEB3Ae105f56099aaaB9061F83"; -const INITIAL_SUPPLY = parseUnits("349.618192", 18); +const INITIAL_SUPPLY = parseUnits("2204.501208", 18); export const SUPPLY_CAP = parseUnits("3000000", 18); export const BORROW_CAP = parseUnits("1500000", 18); const CF = parseUnits("0.5", 18); From c12d129b7a954074c26494ad30909b8713858c46 Mon Sep 17 00:00:00 2001 From: web3rover Date: Thu, 7 Nov 2024 16:19:36 +0400 Subject: [PATCH 114/178] fix: transfer ebtc from treasury to timelock --- multisig/proposals/ethereum/vip-068/index.ts | 21 +++ .../ethereum/vip-068/abi/erc20.json | 134 ++++++++++++++++++ .../simulations/ethereum/vip-068/index.ts | 24 ++++ simulations/vip-391/ethereum.ts | 21 ++- vips/vip-391/bscmainnet.ts | 6 - 5 files changed, 194 insertions(+), 12 deletions(-) create mode 100644 multisig/proposals/ethereum/vip-068/index.ts create mode 100644 multisig/simulations/ethereum/vip-068/abi/erc20.json create mode 100644 multisig/simulations/ethereum/vip-068/index.ts diff --git a/multisig/proposals/ethereum/vip-068/index.ts b/multisig/proposals/ethereum/vip-068/index.ts new file mode 100644 index 000000000..be126c0d8 --- /dev/null +++ b/multisig/proposals/ethereum/vip-068/index.ts @@ -0,0 +1,21 @@ +import { parseUnits } from "ethers/lib/utils"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; + +import { makeProposal } from "../../../../src/utils"; + +const { ethereum } = NETWORK_ADDRESSES; + +export const eBTC = "0x657e8C867D8B37dCC18fA4Caead9C45EB088C642"; +export const INITIAL_SUPPLY = parseUnits("0.14471345", 8); + +export const vip068 = () => { + return makeProposal([ + { + target: ethereum.VTREASURY, + signature: "withdrawTreasuryToken(address,uint256,address)", + params: [eBTC, INITIAL_SUPPLY, ethereum.NORMAL_TIMELOCK], + }, + ]); +}; + +export default vip068; diff --git a/multisig/simulations/ethereum/vip-068/abi/erc20.json b/multisig/simulations/ethereum/vip-068/abi/erc20.json new file mode 100644 index 000000000..3a509c9c4 --- /dev/null +++ b/multisig/simulations/ethereum/vip-068/abi/erc20.json @@ -0,0 +1,134 @@ +[ + { + "inputs": [ + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], + "name": "faucet", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "from", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-068/index.ts b/multisig/simulations/ethereum/vip-068/index.ts new file mode 100644 index 000000000..ac474cdfc --- /dev/null +++ b/multisig/simulations/ethereum/vip-068/index.ts @@ -0,0 +1,24 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; + +import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; +import vip068, { INITIAL_SUPPLY, eBTC } from "../../../proposals/ethereum/vip-068"; +import ERC20_ABI from "./abi/erc20.json"; + +forking(21135461, async () => { + let eBTCContract: Contract; + + describe("Post-VIP behavior", async () => { + before(async () => { + eBTCContract = new ethers.Contract(eBTC, ERC20_ABI, ethers.provider); + await pretendExecutingVip(await vip068()); + }); + + it("check balance", async () => { + expect(await eBTCContract.balanceOf(NETWORK_ADDRESSES.ethereum.NORMAL_TIMELOCK)).to.equal(INITIAL_SUPPLY); + expect(await eBTCContract.balanceOf(NETWORK_ADDRESSES.ethereum.VTREASURY)).to.equal(0); + }); + }); +}); diff --git a/simulations/vip-391/ethereum.ts b/simulations/vip-391/ethereum.ts index be330c142..1309260a4 100644 --- a/simulations/vip-391/ethereum.ts +++ b/simulations/vip-391/ethereum.ts @@ -4,11 +4,13 @@ import { BigNumber, Contract } from "ethers"; import { parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; +import { setMaxStalePeriod } from "src/utils"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIsolatedPoolsComptrollers"; import { checkVToken } from "src/vip-framework/checks/checkVToken"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; +import vip068 from "../../multisig/proposals/ethereum/vip-068"; import vip391, { BORROW_CAP, BaseAssets, @@ -24,12 +26,12 @@ import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; import COMPTROLLER_ABI from "./abi/comptroller.json"; import ERC20_ABI from "./abi/erc20.json"; import VTOKEN_ABI from "./abi/vToken.json"; -import { setMaxStalePeriod, setMaxStalePeriodInChainlinkOracle } from "src/utils"; const { ethereum } = NETWORK_ADDRESSES; const PROTOCOL_SHARE_RESERVE = "0x8c8c8530464f7D95552A11eC31Adbd4dC4AC4d3E"; const USDT_USER = "0xF977814e90dA44bFA03b6295A0616a897441aceC"; const eBTC_USER = "0x7aCDF2012aAC69D70B86677FE91eb66e08961880"; +const ONE_YEAR = 365 * 24 * 3600; forking(21130278, async () => { let resilientOracle: Contract; @@ -42,6 +44,8 @@ forking(21130278, async () => { let wbtc: Contract; before(async () => { + await pretendExecutingVip(await vip068()); + await impersonateAccount(ethereum.NORMAL_TIMELOCK); await setBalance(ethereum.NORMAL_TIMELOCK, parseUnits("1000", 18)); await impersonateAccount(USDT_USER); @@ -58,9 +62,14 @@ forking(21130278, async () => { eBTCContract = await ethers.getContractAt(ERC20_ABI, eBTC, await ethers.getSigner(ethereum.NORMAL_TIMELOCK)); usdtPrimeConverter = await ethers.getContractAt(PRIME_CONVERTER_ABI, USDT_PRIME_CONVERTER); usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); - wbtc = await ethers.getContractAt(ERC20_ABI, "0x2260fac5e5542a773aa44fbcfedf7c193bc2c599", await ethers.getSigner(ethereum.NORMAL_TIMELOCK)); - - await setMaxStalePeriod(resilientOracle, wbtc, 10000000000); + wbtc = await ethers.getContractAt( + ERC20_ABI, + "0x2260fac5e5542a773aa44fbcfedf7c193bc2c599", + await ethers.getSigner(ethereum.NORMAL_TIMELOCK), + ); + + await setMaxStalePeriod(resilientOracle, wbtc, ONE_YEAR); + await setMaxStalePeriod(resilientOracle, usdt, ONE_YEAR); }); testForkedNetworkVipCommands("vip391", await vip391()); @@ -155,7 +164,7 @@ forking(21130278, async () => { const usdtBalanceAfter = await usdt.balanceOf(USDT_USER); const eigenBalanceAfter = await eBTCContract.balanceOf(USDT_USER); - expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("7186.148530", 6)); + expect(usdtBalanceBefore.sub(usdtBalanceAfter)).to.be.equal(parseUnits("7458.923455", 6)); expect(eigenBalanceAfter.sub(eigenBalanceBefore)).to.be.equal(eBTCAmount); }); }); diff --git a/vips/vip-391/bscmainnet.ts b/vips/vip-391/bscmainnet.ts index 75966cee5..91182ccde 100644 --- a/vips/vip-391/bscmainnet.ts +++ b/vips/vip-391/bscmainnet.ts @@ -55,12 +55,6 @@ const vip391 = () => { }, // Add Market - { - target: ethereum.VTREASURY, - signature: "withdrawTreasuryToken(address,uint256,address)", - params: [eBTC, INITIAL_SUPPLY, ethereum.GUARDIAN], - dstChainId: LzChainId.ethereum, - }, { target: eBTC, signature: "approve(address,uint256)", From bd102cd862c68c033c312ae79e05b38a9378b46d Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Thu, 7 Nov 2024 15:38:50 +0300 Subject: [PATCH 115/178] chore: upgrade hardhat to support new eth opcodes --- package.json | 2 +- yarn.lock | 610 +++++++++------------------------------------------ 2 files changed, 108 insertions(+), 504 deletions(-) diff --git a/package.json b/package.json index ac47f1e33..56052b436 100644 --- a/package.json +++ b/package.json @@ -72,7 +72,7 @@ "eslint-config-prettier": "^8.5.0", "ethers": "^5.7.2", "fs-extra": "^10.1.0", - "hardhat": "2.19.5", + "hardhat": "^2.22.15", "hardhat-gas-reporter": "^1.0.9", "husky": "^8.0.2", "lint-staged": "^13.0.4", diff --git a/yarn.lock b/yarn.lock index 81a7fcb99..21003b148 100644 --- a/yarn.lock +++ b/yarn.lock @@ -219,52 +219,6 @@ __metadata: languageName: node linkType: hard -"@chainsafe/as-sha256@npm:^0.3.1": - version: 0.3.1 - resolution: "@chainsafe/as-sha256@npm:0.3.1" - checksum: 58ea733be1657b0e31dbf48b0dba862da0833df34a81c1460c7352f04ce90874f70003cbf34d0afb9e5e53a33ee2d63a261a8b12462be85b2ba0a6f7f13d6150 - languageName: node - linkType: hard - -"@chainsafe/persistent-merkle-tree@npm:^0.4.2": - version: 0.4.2 - resolution: "@chainsafe/persistent-merkle-tree@npm:0.4.2" - dependencies: - "@chainsafe/as-sha256": ^0.3.1 - checksum: f9cfcb2132a243992709715dbd28186ab48c7c0c696f29d30857693cca5526bf753974a505ef68ffd5623bbdbcaa10f9083f4dd40bf99eb6408e451cc26a1a9e - languageName: node - linkType: hard - -"@chainsafe/persistent-merkle-tree@npm:^0.5.0": - version: 0.5.0 - resolution: "@chainsafe/persistent-merkle-tree@npm:0.5.0" - dependencies: - "@chainsafe/as-sha256": ^0.3.1 - checksum: 2c67203da776c79cd3a6132e2d672fe132393b2e63dc71604e3134acc8c0ec25cc5e431051545939ea0f7c5ff2066fb806b9e5cab974ca085d046226a1671f7d - languageName: node - linkType: hard - -"@chainsafe/ssz@npm:^0.10.0": - version: 0.10.2 - resolution: "@chainsafe/ssz@npm:0.10.2" - dependencies: - "@chainsafe/as-sha256": ^0.3.1 - "@chainsafe/persistent-merkle-tree": ^0.5.0 - checksum: 6bb70cf741d0a19dd0b28b3f6f067b96fa39f556e2eefa6ac745b21db9c3b3a8393dc3cca8ff4a6ce065ed71ddc3fb1b2b390a92004b9d01067c26e2558e5503 - languageName: node - linkType: hard - -"@chainsafe/ssz@npm:^0.9.2": - version: 0.9.4 - resolution: "@chainsafe/ssz@npm:0.9.4" - dependencies: - "@chainsafe/as-sha256": ^0.3.1 - "@chainsafe/persistent-merkle-tree": ^0.4.2 - case: ^1.6.3 - checksum: c6eaedeae9e5618b3c666ff4507a27647f665a8dcf17d5ca86da4ed4788c5a93868f256d0005467d184fdf35ec03f323517ec2e55ec42492d769540a2ec396bc - languageName: node - linkType: hard - "@colors/colors@npm:1.5.0": version: 1.5.0 resolution: "@colors/colors@npm:1.5.0" @@ -904,7 +858,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/providers@npm:5.7.2, @ethersproject/providers@npm:^5.4.4, @ethersproject/providers@npm:^5.7.0, @ethersproject/providers@npm:^5.7.1, @ethersproject/providers@npm:^5.7.2": +"@ethersproject/providers@npm:5.7.2, @ethersproject/providers@npm:^5.4.4, @ethersproject/providers@npm:^5.7.0, @ethersproject/providers@npm:^5.7.2": version: 5.7.2 resolution: "@ethersproject/providers@npm:5.7.2" dependencies: @@ -1467,6 +1421,13 @@ __metadata: languageName: node linkType: hard +"@nomicfoundation/edr-darwin-arm64@npm:0.6.4": + version: 0.6.4 + resolution: "@nomicfoundation/edr-darwin-arm64@npm:0.6.4" + checksum: 66d97c15e2420f2a2149495c31baec36d4f2bbe5285db8677abe0f17e318c01b717d4f14e69fd256df6dfdf57406e2da02c9ab667eb8a01591d8f020a91ddfe8 + languageName: node + linkType: hard + "@nomicfoundation/edr-darwin-x64@npm:0.4.2": version: 0.4.2 resolution: "@nomicfoundation/edr-darwin-x64@npm:0.4.2" @@ -1474,6 +1435,13 @@ __metadata: languageName: node linkType: hard +"@nomicfoundation/edr-darwin-x64@npm:0.6.4": + version: 0.6.4 + resolution: "@nomicfoundation/edr-darwin-x64@npm:0.6.4" + checksum: 3df7bbebc897846372954e47beefd60684da7d67c0a2648e06892c912890338f498cd38ec94d8f1d1bd8f4529a72cb036b4cef83370b373ec7ee70727482c22f + languageName: node + linkType: hard + "@nomicfoundation/edr-linux-arm64-gnu@npm:0.4.2": version: 0.4.2 resolution: "@nomicfoundation/edr-linux-arm64-gnu@npm:0.4.2" @@ -1481,6 +1449,13 @@ __metadata: languageName: node linkType: hard +"@nomicfoundation/edr-linux-arm64-gnu@npm:0.6.4": + version: 0.6.4 + resolution: "@nomicfoundation/edr-linux-arm64-gnu@npm:0.6.4" + checksum: a778099e3dabc0b4b6a43ef6366ce90fd1e5cdd0b6811e68184daed17064ff429c266dbe0c56b0dfaab8e94bd888952659f89c8dbd98c7e4900f4fcadc8a0b38 + languageName: node + linkType: hard + "@nomicfoundation/edr-linux-arm64-musl@npm:0.4.2": version: 0.4.2 resolution: "@nomicfoundation/edr-linux-arm64-musl@npm:0.4.2" @@ -1488,6 +1463,13 @@ __metadata: languageName: node linkType: hard +"@nomicfoundation/edr-linux-arm64-musl@npm:0.6.4": + version: 0.6.4 + resolution: "@nomicfoundation/edr-linux-arm64-musl@npm:0.6.4" + checksum: 4886f9505d0709b0fd8de022ad15a0ae1ad4466a7b275e17ac2df948cbbebbfbe6a8f91ac179cdfceb413cd89c73ec85cc2adb833dc3cfdccd89c97b46fa683c + languageName: node + linkType: hard + "@nomicfoundation/edr-linux-x64-gnu@npm:0.4.2": version: 0.4.2 resolution: "@nomicfoundation/edr-linux-x64-gnu@npm:0.4.2" @@ -1495,6 +1477,13 @@ __metadata: languageName: node linkType: hard +"@nomicfoundation/edr-linux-x64-gnu@npm:0.6.4": + version: 0.6.4 + resolution: "@nomicfoundation/edr-linux-x64-gnu@npm:0.6.4" + checksum: 3304c6a048c42c8116892b162883496819689d31d10213d97e72f100cb083588f1effb07ba2c93ead45135f09b1a48dc5619cb588089c63aac8e1126df1fc716 + languageName: node + linkType: hard + "@nomicfoundation/edr-linux-x64-musl@npm:0.4.2": version: 0.4.2 resolution: "@nomicfoundation/edr-linux-x64-musl@npm:0.4.2" @@ -1502,6 +1491,13 @@ __metadata: languageName: node linkType: hard +"@nomicfoundation/edr-linux-x64-musl@npm:0.6.4": + version: 0.6.4 + resolution: "@nomicfoundation/edr-linux-x64-musl@npm:0.6.4" + checksum: 9a29c7e28edb351ad178c9fb62543a76f504ff03b41f068e2ffa23e6cd9f0de3d543158dfba4d4ac45c3499ab3d5c9a81e45e226ca4b9e5455e05b8378a59917 + languageName: node + linkType: hard + "@nomicfoundation/edr-win32-x64-msvc@npm:0.4.2": version: 0.4.2 resolution: "@nomicfoundation/edr-win32-x64-msvc@npm:0.4.2" @@ -1509,6 +1505,13 @@ __metadata: languageName: node linkType: hard +"@nomicfoundation/edr-win32-x64-msvc@npm:0.6.4": + version: 0.6.4 + resolution: "@nomicfoundation/edr-win32-x64-msvc@npm:0.6.4" + checksum: a14784f674cb409baaa7c19ec86a879dd349015090227135265ad14f65b553020d2f76053b0c27ccfc8baba13f6b59902c7f303083dd1439e5b8af7a400a53b8 + languageName: node + linkType: hard + "@nomicfoundation/edr@npm:^0.4.1": version: 0.4.2 resolution: "@nomicfoundation/edr@npm:0.4.2" @@ -1524,49 +1527,18 @@ __metadata: languageName: node linkType: hard -"@nomicfoundation/ethereumjs-block@npm:5.0.2": - version: 5.0.2 - resolution: "@nomicfoundation/ethereumjs-block@npm:5.0.2" +"@nomicfoundation/edr@npm:^0.6.4": + version: 0.6.4 + resolution: "@nomicfoundation/edr@npm:0.6.4" dependencies: - "@nomicfoundation/ethereumjs-common": 4.0.2 - "@nomicfoundation/ethereumjs-rlp": 5.0.2 - "@nomicfoundation/ethereumjs-trie": 6.0.2 - "@nomicfoundation/ethereumjs-tx": 5.0.2 - "@nomicfoundation/ethereumjs-util": 9.0.2 - ethereum-cryptography: 0.1.3 - ethers: ^5.7.1 - checksum: 7ff744f44a01f1c059ca7812a1cfc8089f87aa506af6cb39c78331dca71b32993cbd6fa05ad03f8c4f4fab73bb998a927af69e0d8ff01ae192ee5931606e09f5 - languageName: node - linkType: hard - -"@nomicfoundation/ethereumjs-blockchain@npm:7.0.2": - version: 7.0.2 - resolution: "@nomicfoundation/ethereumjs-blockchain@npm:7.0.2" - dependencies: - "@nomicfoundation/ethereumjs-block": 5.0.2 - "@nomicfoundation/ethereumjs-common": 4.0.2 - "@nomicfoundation/ethereumjs-ethash": 3.0.2 - "@nomicfoundation/ethereumjs-rlp": 5.0.2 - "@nomicfoundation/ethereumjs-trie": 6.0.2 - "@nomicfoundation/ethereumjs-tx": 5.0.2 - "@nomicfoundation/ethereumjs-util": 9.0.2 - abstract-level: ^1.0.3 - debug: ^4.3.3 - ethereum-cryptography: 0.1.3 - level: ^8.0.0 - lru-cache: ^5.1.1 - memory-level: ^1.0.0 - checksum: b7e440dcd73e32aa72d13bfd28cb472773c9c60ea808a884131bf7eb3f42286ad594a0864215f599332d800f3fe1f772fff4b138d2dcaa8f41e4d8389bff33e7 - languageName: node - linkType: hard - -"@nomicfoundation/ethereumjs-common@npm:4.0.2": - version: 4.0.2 - resolution: "@nomicfoundation/ethereumjs-common@npm:4.0.2" - dependencies: - "@nomicfoundation/ethereumjs-util": 9.0.2 - crc-32: ^1.2.0 - checksum: f0d84704d6254d374299c19884312bd5666974b4b6f342d3f10bc76e549de78d20e45a53d25fbdc146268a52335497127e4f069126da7c60ac933a158e704887 + "@nomicfoundation/edr-darwin-arm64": 0.6.4 + "@nomicfoundation/edr-darwin-x64": 0.6.4 + "@nomicfoundation/edr-linux-arm64-gnu": 0.6.4 + "@nomicfoundation/edr-linux-arm64-musl": 0.6.4 + "@nomicfoundation/edr-linux-x64-gnu": 0.6.4 + "@nomicfoundation/edr-linux-x64-musl": 0.6.4 + "@nomicfoundation/edr-win32-x64-msvc": 0.6.4 + checksum: 8c9feda723f5dae128501b69a7b471645d9cfbf8f5d291dba8a0eb7a4ce1864d16ae3f75240d034940efffa5f2c0f338eaa2e0f33fae45f2b64c8a5332cafb04 languageName: node linkType: hard @@ -1579,45 +1551,6 @@ __metadata: languageName: node linkType: hard -"@nomicfoundation/ethereumjs-ethash@npm:3.0.2": - version: 3.0.2 - resolution: "@nomicfoundation/ethereumjs-ethash@npm:3.0.2" - dependencies: - "@nomicfoundation/ethereumjs-block": 5.0.2 - "@nomicfoundation/ethereumjs-rlp": 5.0.2 - "@nomicfoundation/ethereumjs-util": 9.0.2 - abstract-level: ^1.0.3 - bigint-crypto-utils: ^3.0.23 - ethereum-cryptography: 0.1.3 - checksum: e4011e4019dd9b92f7eeebfc1e6c9a9685c52d8fd0ee4f28f03e50048a23b600c714490827f59fdce497b3afb503b3fd2ebf6815ff307e9949c3efeff1403278 - languageName: node - linkType: hard - -"@nomicfoundation/ethereumjs-evm@npm:2.0.2": - version: 2.0.2 - resolution: "@nomicfoundation/ethereumjs-evm@npm:2.0.2" - dependencies: - "@ethersproject/providers": ^5.7.1 - "@nomicfoundation/ethereumjs-common": 4.0.2 - "@nomicfoundation/ethereumjs-tx": 5.0.2 - "@nomicfoundation/ethereumjs-util": 9.0.2 - debug: ^4.3.3 - ethereum-cryptography: 0.1.3 - mcl-wasm: ^0.7.1 - rustbn.js: ~0.2.0 - checksum: a23cf570836ddc147606b02df568069de946108e640f902358fef67e589f6b371d856056ee44299d9b4e3497f8ae25faa45e6b18fefd90e9b222dc6a761d85f0 - languageName: node - linkType: hard - -"@nomicfoundation/ethereumjs-rlp@npm:5.0.2": - version: 5.0.2 - resolution: "@nomicfoundation/ethereumjs-rlp@npm:5.0.2" - bin: - rlp: bin/rlp - checksum: a74434cadefca9aa8754607cc1ad7bb4bbea4ee61c6214918e60a5bbee83206850346eb64e39fd1fe97f854c7ec0163e01148c0c881dda23881938f0645a0ef2 - languageName: node - linkType: hard - "@nomicfoundation/ethereumjs-rlp@npm:5.0.4": version: 5.0.4 resolution: "@nomicfoundation/ethereumjs-rlp@npm:5.0.4" @@ -1627,47 +1560,6 @@ __metadata: languageName: node linkType: hard -"@nomicfoundation/ethereumjs-statemanager@npm:2.0.2": - version: 2.0.2 - resolution: "@nomicfoundation/ethereumjs-statemanager@npm:2.0.2" - dependencies: - "@nomicfoundation/ethereumjs-common": 4.0.2 - "@nomicfoundation/ethereumjs-rlp": 5.0.2 - debug: ^4.3.3 - ethereum-cryptography: 0.1.3 - ethers: ^5.7.1 - js-sdsl: ^4.1.4 - checksum: 3ab6578e252e53609afd98d8ba42a99f182dcf80252f23ed9a5e0471023ffb2502130f85fc47fa7c94cd149f9be799ed9a0942ca52a143405be9267f4ad94e64 - languageName: node - linkType: hard - -"@nomicfoundation/ethereumjs-trie@npm:6.0.2": - version: 6.0.2 - resolution: "@nomicfoundation/ethereumjs-trie@npm:6.0.2" - dependencies: - "@nomicfoundation/ethereumjs-rlp": 5.0.2 - "@nomicfoundation/ethereumjs-util": 9.0.2 - "@types/readable-stream": ^2.3.13 - ethereum-cryptography: 0.1.3 - readable-stream: ^3.6.0 - checksum: d4da918d333851b9f2cce7dbd25ab5753e0accd43d562d98fd991b168b6a08d1794528f0ade40fe5617c84900378376fe6256cdbe52c8d66bf4c53293bbc7c40 - languageName: node - linkType: hard - -"@nomicfoundation/ethereumjs-tx@npm:5.0.2": - version: 5.0.2 - resolution: "@nomicfoundation/ethereumjs-tx@npm:5.0.2" - dependencies: - "@chainsafe/ssz": ^0.9.2 - "@ethersproject/providers": ^5.7.2 - "@nomicfoundation/ethereumjs-common": 4.0.2 - "@nomicfoundation/ethereumjs-rlp": 5.0.2 - "@nomicfoundation/ethereumjs-util": 9.0.2 - ethereum-cryptography: 0.1.3 - checksum: 0bbcea75786b2ccb559afe2ecc9866fb4566a9f157b6ffba4f50960d14f4b3da2e86e273f6fadda9b860e67cfcabf589970fb951b328cb5f900a585cd21842a2 - languageName: node - linkType: hard - "@nomicfoundation/ethereumjs-tx@npm:5.0.4": version: 5.0.4 resolution: "@nomicfoundation/ethereumjs-tx@npm:5.0.4" @@ -1685,17 +1577,6 @@ __metadata: languageName: node linkType: hard -"@nomicfoundation/ethereumjs-util@npm:9.0.2": - version: 9.0.2 - resolution: "@nomicfoundation/ethereumjs-util@npm:9.0.2" - dependencies: - "@chainsafe/ssz": ^0.10.0 - "@nomicfoundation/ethereumjs-rlp": 5.0.2 - ethereum-cryptography: 0.1.3 - checksum: 3a08f7b88079ef9f53b43da9bdcb8195498fd3d3911c2feee2571f4d1204656053f058b2f650471c86f7d2d0ba2f814768c7cfb0f266eede41c848356afc4900 - languageName: node - linkType: hard - "@nomicfoundation/ethereumjs-util@npm:9.0.4, @nomicfoundation/ethereumjs-util@npm:^9.0.4": version: 9.0.4 resolution: "@nomicfoundation/ethereumjs-util@npm:9.0.4" @@ -1711,27 +1592,6 @@ __metadata: languageName: node linkType: hard -"@nomicfoundation/ethereumjs-vm@npm:7.0.2": - version: 7.0.2 - resolution: "@nomicfoundation/ethereumjs-vm@npm:7.0.2" - dependencies: - "@nomicfoundation/ethereumjs-block": 5.0.2 - "@nomicfoundation/ethereumjs-blockchain": 7.0.2 - "@nomicfoundation/ethereumjs-common": 4.0.2 - "@nomicfoundation/ethereumjs-evm": 2.0.2 - "@nomicfoundation/ethereumjs-rlp": 5.0.2 - "@nomicfoundation/ethereumjs-statemanager": 2.0.2 - "@nomicfoundation/ethereumjs-trie": 6.0.2 - "@nomicfoundation/ethereumjs-tx": 5.0.2 - "@nomicfoundation/ethereumjs-util": 9.0.2 - debug: ^4.3.3 - ethereum-cryptography: 0.1.3 - mcl-wasm: ^0.7.1 - rustbn.js: ~0.2.0 - checksum: 1c25ba4d0644cadb8a2b0241a4bb02e578bfd7f70e3492b855c2ab5c120cb159cb8f7486f84dc1597884bd1697feedbfb5feb66e91352afb51f3694fd8e4a043 - languageName: node - linkType: hard - "@nomicfoundation/hardhat-chai-matchers@npm:^1.0.4": version: 1.0.6 resolution: "@nomicfoundation/hardhat-chai-matchers@npm:1.0.6" @@ -2673,16 +2533,6 @@ __metadata: languageName: node linkType: hard -"@types/readable-stream@npm:^2.3.13": - version: 2.3.15 - resolution: "@types/readable-stream@npm:2.3.15" - dependencies: - "@types/node": "*" - safe-buffer: ~5.1.1 - checksum: ec36f525cad09b6c65a1dafcb5ad99b9e2ed824ec49b7aa23180ac427e5d35b8a0706193ecd79ab4253a283ad485ba03d5917a98daaaa144f0ea34f4823e9d82 - languageName: node - linkType: hard - "@types/readline-sync@npm:^1.4.8": version: 1.4.8 resolution: "@types/readline-sync@npm:1.4.8" @@ -3042,7 +2892,7 @@ __metadata: eslint-config-prettier: ^8.5.0 ethers: ^5.7.2 fs-extra: ^10.1.0 - hardhat: 2.19.5 + hardhat: ^2.22.15 hardhat-gas-reporter: ^1.0.9 husky: ^8.0.2 lint-staged: ^13.0.4 @@ -3098,21 +2948,6 @@ __metadata: languageName: node linkType: hard -"abstract-level@npm:^1.0.0, abstract-level@npm:^1.0.2, abstract-level@npm:^1.0.3, abstract-level@npm:^1.0.4": - version: 1.0.4 - resolution: "abstract-level@npm:1.0.4" - dependencies: - buffer: ^6.0.3 - catering: ^2.1.0 - is-buffer: ^2.0.5 - level-supports: ^4.0.0 - level-transcoder: ^1.0.1 - module-error: ^1.0.1 - queue-microtask: ^1.2.3 - checksum: 5b70d08926f5234c3c23ffca848542af4def780dc96d6ca35a81659af80e6439c46f5106bd14a5ea37465173d7dcc8294317048b0194fdf6480103edc4aa9e63 - languageName: node - linkType: hard - "accepts@npm:~1.3.8": version: 1.3.8 resolution: "accepts@npm:1.3.8" @@ -3580,13 +3415,6 @@ __metadata: languageName: node linkType: hard -"bigint-crypto-utils@npm:^3.0.23": - version: 3.3.0 - resolution: "bigint-crypto-utils@npm:3.3.0" - checksum: 9598ce57b23f776c8936d44114c9f051e62b5fa654915b664784cbcbacc5aa0485f4479571c51ff58008abb1210c0d6a234853742f07cf84bda890f2a1e01000 - languageName: node - linkType: hard - "bignumber.js@npm:^9.0.0, bignumber.js@npm:^9.1.2": version: 9.1.2 resolution: "bignumber.js@npm:9.1.2" @@ -3728,18 +3556,6 @@ __metadata: languageName: node linkType: hard -"browser-level@npm:^1.0.1": - version: 1.0.1 - resolution: "browser-level@npm:1.0.1" - dependencies: - abstract-level: ^1.0.2 - catering: ^2.1.1 - module-error: ^1.0.2 - run-parallel-limit: ^1.1.0 - checksum: 67fbc77ce832940bfa25073eccff279f512ad56f545deb996a5b23b02316f5e76f4a79d381acc27eda983f5c9a2566aaf9c97e4fdd0748288c4407307537a29b - languageName: node - linkType: hard - "browser-stdout@npm:^1.3.1": version: 1.3.1 resolution: "browser-stdout@npm:1.3.1" @@ -3847,16 +3663,6 @@ __metadata: languageName: node linkType: hard -"buffer@npm:^6.0.3": - version: 6.0.3 - resolution: "buffer@npm:6.0.3" - dependencies: - base64-js: ^1.3.1 - ieee754: ^1.2.1 - checksum: 5ad23293d9a731e4318e420025800b42bf0d264004c0286c8cc010af7a270c7a0f6522e84f54b9ad65cbd6db20b8badbfd8d2ebf4f80fa03dab093b89e68c3f9 - languageName: node - linkType: hard - "bufferutil@npm:^4.0.1": version: 4.0.8 resolution: "bufferutil@npm:4.0.8" @@ -3989,13 +3795,6 @@ __metadata: languageName: node linkType: hard -"case@npm:^1.6.3": - version: 1.6.3 - resolution: "case@npm:1.6.3" - checksum: febe73278f910b0d28aab7efd6f51c235f9aa9e296148edb56dfb83fd58faa88308c30ce9a0122b6e53e0362c44f4407105bd5ef89c46860fc2b184e540fd68d - languageName: node - linkType: hard - "caseless@npm:^0.12.0, caseless@npm:~0.12.0": version: 0.12.0 resolution: "caseless@npm:0.12.0" @@ -4003,13 +3802,6 @@ __metadata: languageName: node linkType: hard -"catering@npm:^2.1.0, catering@npm:^2.1.1": - version: 2.1.1 - resolution: "catering@npm:2.1.1" - checksum: 205daefa69c935b0c19f3d8f2e0a520dd69aebe9bda55902958003f7c9cff8f967dfb90071b421bd6eb618576f657a89d2bc0986872c9bc04bbd66655e9d4bd6 - languageName: node - linkType: hard - "cbor@npm:^8.1.0": version: 8.1.0 resolution: "cbor@npm:8.1.0" @@ -4124,6 +3916,15 @@ __metadata: languageName: node linkType: hard +"chokidar@npm:^4.0.0": + version: 4.0.1 + resolution: "chokidar@npm:4.0.1" + dependencies: + readdirp: ^4.0.1 + checksum: 193da9786b0422a895d59c7552195d15c6c636e6a2293ae43d09e34e243e24ccd02d693f007c767846a65abbeae5fea6bfacb8fc2ddec4ea4d397620d552010d + languageName: node + linkType: hard + "chownr@npm:^1.0.1, chownr@npm:^1.1.1, chownr@npm:^1.1.4": version: 1.1.4 resolution: "chownr@npm:1.1.4" @@ -4175,20 +3976,6 @@ __metadata: languageName: node linkType: hard -"classic-level@npm:^1.2.0": - version: 1.4.1 - resolution: "classic-level@npm:1.4.1" - dependencies: - abstract-level: ^1.0.2 - catering: ^2.1.0 - module-error: ^1.0.1 - napi-macros: ^2.2.2 - node-gyp: latest - node-gyp-build: ^4.3.0 - checksum: 62e7e07297fcd656941eb88f92b91df0046ebb2b34987e98ec870cb736f096e212ef109a25541deba2f30866b9d5df550594ed04948614815dd5964933da50a9 - languageName: node - linkType: hard - "clean-stack@npm:^2.0.0": version: 2.2.0 resolution: "clean-stack@npm:2.2.0" @@ -4419,13 +4206,6 @@ __metadata: languageName: node linkType: hard -"commander@npm:3.0.2": - version: 3.0.2 - resolution: "commander@npm:3.0.2" - checksum: 6d14ad030d1904428139487ed31febcb04c1604db2b8d9fae711f60ee6718828dc0e11602249e91c8a97b0e721e9c6d53edbc166bad3cde1596851d59a8f824d - languageName: node - linkType: hard - "commander@npm:^8.1.0": version: 8.3.0 resolution: "commander@npm:8.3.0" @@ -4877,18 +4657,6 @@ __metadata: languageName: node linkType: hard -"debug@npm:^4.3.3": - version: 4.3.6 - resolution: "debug@npm:4.3.6" - dependencies: - ms: 2.1.2 - peerDependenciesMeta: - supports-color: - optional: true - checksum: 1630b748dea3c581295e02137a9f5cbe2c1d85fea35c1e6597a65ca2b16a6fce68cec61b299d480787ef310ba927dc8c92d3061faba0ad06c6a724672f66be7f - languageName: node - linkType: hard - "decamelize-keys@npm:^1.1.0": version: 1.1.1 resolution: "decamelize-keys@npm:1.1.1" @@ -5807,7 +5575,7 @@ __metadata: languageName: node linkType: hard -"ethers@npm:^5.6.8, ethers@npm:^5.7.0, ethers@npm:^5.7.1, ethers@npm:^5.7.2, ethers@npm:~5.7.0, ethers@npm:~5.7.2": +"ethers@npm:^5.6.8, ethers@npm:^5.7.0, ethers@npm:^5.7.2, ethers@npm:~5.7.0, ethers@npm:~5.7.2": version: 5.7.2 resolution: "ethers@npm:5.7.2" dependencies: @@ -6365,19 +6133,6 @@ __metadata: languageName: node linkType: hard -"fs-extra@npm:^0.30.0": - version: 0.30.0 - resolution: "fs-extra@npm:0.30.0" - dependencies: - graceful-fs: ^4.1.2 - jsonfile: ^2.1.0 - klaw: ^1.0.0 - path-is-absolute: ^1.0.0 - rimraf: ^2.2.8 - checksum: 6edfd65fc813baa27f1603778c0f5ec11f8c5006a20b920437813ee2023eba18aeec8bef1c89b2e6c84f9fc90fdc7c916f4a700466c8c69d22a35d018f2570f0 - languageName: node - linkType: hard - "fs-extra@npm:^10.0.0, fs-extra@npm:^10.1.0": version: 10.1.0 resolution: "fs-extra@npm:10.1.0" @@ -6501,13 +6256,6 @@ __metadata: languageName: node linkType: hard -"functional-red-black-tree@npm:^1.0.1": - version: 1.0.1 - resolution: "functional-red-black-tree@npm:1.0.1" - checksum: ca6c170f37640e2d94297da8bb4bf27a1d12bea3e00e6a3e007fd7aa32e37e000f5772acf941b4e4f3cf1c95c3752033d0c509af157ad8f526e7f00723b9eb9f - languageName: node - linkType: hard - "functions-have-names@npm:^1.2.3": version: 1.2.3 resolution: "functions-have-names@npm:1.2.3" @@ -6830,7 +6578,7 @@ __metadata: languageName: node linkType: hard -"graceful-fs@npm:^4.1.2, graceful-fs@npm:^4.1.6, graceful-fs@npm:^4.1.9, graceful-fs@npm:^4.2.0, graceful-fs@npm:^4.2.4, graceful-fs@npm:^4.2.6": +"graceful-fs@npm:^4.1.2, graceful-fs@npm:^4.1.6, graceful-fs@npm:^4.2.0, graceful-fs@npm:^4.2.4, graceful-fs@npm:^4.2.6": version: 4.2.11 resolution: "graceful-fs@npm:4.2.11" checksum: ac85f94da92d8eb6b7f5a8b20ce65e43d66761c55ce85ac96df6865308390da45a8d3f0296dd3a663de65d30ba497bd46c696cc1e248c72b13d6d567138a4fc7 @@ -6987,22 +6735,16 @@ __metadata: languageName: node linkType: hard -"hardhat@npm:2.19.5": - version: 2.19.5 - resolution: "hardhat@npm:2.19.5" +"hardhat@npm:^2.14.0, hardhat@npm:^2.16.1, hardhat@npm:^2.8.0": + version: 2.22.6 + resolution: "hardhat@npm:2.22.6" dependencies: "@ethersproject/abi": ^5.1.2 "@metamask/eth-sig-util": ^4.0.0 - "@nomicfoundation/ethereumjs-block": 5.0.2 - "@nomicfoundation/ethereumjs-blockchain": 7.0.2 - "@nomicfoundation/ethereumjs-common": 4.0.2 - "@nomicfoundation/ethereumjs-evm": 2.0.2 - "@nomicfoundation/ethereumjs-rlp": 5.0.2 - "@nomicfoundation/ethereumjs-statemanager": 2.0.2 - "@nomicfoundation/ethereumjs-trie": 6.0.2 - "@nomicfoundation/ethereumjs-tx": 5.0.2 - "@nomicfoundation/ethereumjs-util": 9.0.2 - "@nomicfoundation/ethereumjs-vm": 7.0.2 + "@nomicfoundation/edr": ^0.4.1 + "@nomicfoundation/ethereumjs-common": 4.0.4 + "@nomicfoundation/ethereumjs-tx": 5.0.4 + "@nomicfoundation/ethereumjs-util": 9.0.4 "@nomicfoundation/solidity-analyzer": ^0.1.0 "@sentry/node": ^5.18.1 "@types/bn.js": ^5.1.0 @@ -7033,7 +6775,7 @@ __metadata: raw-body: ^2.4.1 resolve: 1.17.0 semver: ^6.3.0 - solc: 0.7.3 + solc: 0.8.26 source-map-support: ^0.5.13 stacktrace-parser: ^0.1.10 tsort: 0.0.1 @@ -7050,17 +6792,17 @@ __metadata: optional: true bin: hardhat: internal/cli/bootstrap.js - checksum: 316b03a1d090360e6ed471fe125360ec0c66c5bb62e29492898932b1a9a5227c12d7a18343877c59725f321647a01fde0841649bf7d8a4a746148a0d38b0ee27 + checksum: 5aec1824db3575d63754de18c2629bcd820bc836d836f8a6346bcd9aa2ae4c397e090c43ea482ee765b704e018001015b5c84c5ded301a6a1144129c1a4c509b languageName: node linkType: hard -"hardhat@npm:^2.14.0, hardhat@npm:^2.16.1, hardhat@npm:^2.8.0": - version: 2.22.6 - resolution: "hardhat@npm:2.22.6" +"hardhat@npm:^2.22.15": + version: 2.22.15 + resolution: "hardhat@npm:2.22.15" dependencies: "@ethersproject/abi": ^5.1.2 "@metamask/eth-sig-util": ^4.0.0 - "@nomicfoundation/edr": ^0.4.1 + "@nomicfoundation/edr": ^0.6.4 "@nomicfoundation/ethereumjs-common": 4.0.4 "@nomicfoundation/ethereumjs-tx": 5.0.4 "@nomicfoundation/ethereumjs-util": 9.0.4 @@ -7073,7 +6815,7 @@ __metadata: ansi-escapes: ^4.3.0 boxen: ^5.1.2 chalk: ^2.4.2 - chokidar: ^3.4.0 + chokidar: ^4.0.0 ci-info: ^2.0.0 debug: ^4.1.1 enquirer: ^2.3.0 @@ -7086,6 +6828,7 @@ __metadata: glob: 7.2.0 immutable: ^4.0.0-rc.12 io-ts: 1.10.4 + json-stream-stringify: ^3.1.4 keccak: ^3.0.2 lodash: ^4.17.11 mnemonist: ^0.38.0 @@ -7111,7 +6854,7 @@ __metadata: optional: true bin: hardhat: internal/cli/bootstrap.js - checksum: 5aec1824db3575d63754de18c2629bcd820bc836d836f8a6346bcd9aa2ae4c397e090c43ea482ee765b704e018001015b5c84c5ded301a6a1144129c1a4c509b + checksum: 214f0bf9b8a7cb90d5be906e49adf7da87df0d10db42cc7a48ccc1129cda11da8578fe12bbb30a1e5f2c5d9e96a7733a4750626abd602e0a263a8d1f366a4f9a languageName: node linkType: hard @@ -7402,7 +7145,7 @@ __metadata: languageName: node linkType: hard -"ieee754@npm:^1.1.13, ieee754@npm:^1.1.4, ieee754@npm:^1.2.1": +"ieee754@npm:^1.1.13, ieee754@npm:^1.1.4": version: 1.2.1 resolution: "ieee754@npm:1.2.1" checksum: 5144c0c9815e54ada181d80a0b810221a253562422e7c6c3a60b1901154184f49326ec239d618c416c1c5945a2e197107aee8d986a3dd836b53dffefd99b5e7e @@ -7607,13 +7350,6 @@ __metadata: languageName: node linkType: hard -"is-buffer@npm:^2.0.5": - version: 2.0.5 - resolution: "is-buffer@npm:2.0.5" - checksum: 764c9ad8b523a9f5a32af29bdf772b08eb48c04d2ad0a7240916ac2688c983bf5f8504bf25b35e66240edeb9d9085461f9b5dae1f3d2861c6b06a65fe983de42 - languageName: node - linkType: hard - "is-callable@npm:^1.1.3, is-callable@npm:^1.1.4, is-callable@npm:^1.2.7": version: 1.2.7 resolution: "is-callable@npm:1.2.7" @@ -7974,13 +7710,6 @@ __metadata: languageName: node linkType: hard -"js-sdsl@npm:^4.1.4": - version: 4.4.2 - resolution: "js-sdsl@npm:4.4.2" - checksum: ba705adc1788bf3c6f6c8e5077824f2bb4f0acab5a984420ce5cc492c7fff3daddc26335ad2c9a67d4f5e3241ec790f9e5b72a625adcf20cf321d2fd85e62b8b - languageName: node - linkType: hard - "js-sha3@npm:0.8.0, js-sha3@npm:^0.8.0": version: 0.8.0 resolution: "js-sha3@npm:0.8.0" @@ -8078,6 +7807,13 @@ __metadata: languageName: node linkType: hard +"json-stream-stringify@npm:^3.1.4": + version: 3.1.6 + resolution: "json-stream-stringify@npm:3.1.6" + checksum: ce873e09fe18461960b7536f63e2f913a2cb242819513856ed1af58989d41846976e7177cb1fe3c835220023aa01e534d56b6d5c3290a5b23793a6f4cb93785e + languageName: node + linkType: hard + "json-stringify-safe@npm:~5.0.1": version: 5.0.1 resolution: "json-stringify-safe@npm:5.0.1" @@ -8085,18 +7821,6 @@ __metadata: languageName: node linkType: hard -"jsonfile@npm:^2.1.0": - version: 2.4.0 - resolution: "jsonfile@npm:2.4.0" - dependencies: - graceful-fs: ^4.1.6 - dependenciesMeta: - graceful-fs: - optional: true - checksum: f5064aabbc9e35530dc471d8b203ae1f40dbe949ddde4391c6f6a6d310619a15f0efdae5587df594d1d70c555193aaeee9d2ed4aec9ffd5767bd5e4e62d49c3d - languageName: node - linkType: hard - "jsonfile@npm:^4.0.0": version: 4.0.0 resolution: "jsonfile@npm:4.0.0" @@ -8176,46 +7900,6 @@ __metadata: languageName: node linkType: hard -"klaw@npm:^1.0.0": - version: 1.3.1 - resolution: "klaw@npm:1.3.1" - dependencies: - graceful-fs: ^4.1.9 - dependenciesMeta: - graceful-fs: - optional: true - checksum: 8f69e4797c26e7c3f2426bfa85f38a3da3c2cb1b4c6bd850d2377aed440d41ce9d806f2885c2e2e224372c56af4b1d43b8a499adecf9a05e7373dc6b8b7c52e4 - languageName: node - linkType: hard - -"level-supports@npm:^4.0.0": - version: 4.0.1 - resolution: "level-supports@npm:4.0.1" - checksum: d4552b42bb8cdeada07b0f6356c7a90fefe76279147331f291aceae26e3e56d5f927b09ce921647c0230bfe03ddfbdcef332be921e5c2194421ae2bfa3cf6368 - languageName: node - linkType: hard - -"level-transcoder@npm:^1.0.1": - version: 1.0.1 - resolution: "level-transcoder@npm:1.0.1" - dependencies: - buffer: ^6.0.3 - module-error: ^1.0.1 - checksum: 304f08d802faf3491a533b6d87ad8be3cabfd27f2713bbe9d4c633bf50fcb9460eab5a6776bf015e101ead7ba1c1853e05e7f341112f17a9d0cb37ee5a421a25 - languageName: node - linkType: hard - -"level@npm:^8.0.0": - version: 8.0.1 - resolution: "level@npm:8.0.1" - dependencies: - abstract-level: ^1.0.4 - browser-level: ^1.0.1 - classic-level: ^1.2.0 - checksum: c5641cbba666ef9eb0292aad01d86a4f1af18e637d1fc097c65bf0109ab8d7e6fba8c8faf6c74ae4e48edac4310f7dd87def26ffeebfe395c7afd9bd2461ab97 - languageName: node - linkType: hard - "levn@npm:^0.4.1": version: 0.4.1 resolution: "levn@npm:0.4.1" @@ -8486,15 +8170,6 @@ __metadata: languageName: node linkType: hard -"lru-cache@npm:^5.1.1": - version: 5.1.1 - resolution: "lru-cache@npm:5.1.1" - dependencies: - yallist: ^3.0.2 - checksum: c154ae1cbb0c2206d1501a0e94df349653c92c8cbb25236d7e85190bcaf4567a03ac6eb43166fabfa36fd35623694da7233e88d9601fbf411a9a481d85dbd2cb - languageName: node - linkType: hard - "lru-cache@npm:^6.0.0": version: 6.0.0 resolution: "lru-cache@npm:6.0.0" @@ -8566,13 +8241,6 @@ __metadata: languageName: node linkType: hard -"mcl-wasm@npm:^0.7.1": - version: 0.7.9 - resolution: "mcl-wasm@npm:0.7.9" - checksum: 6b6ed5084156b98b2db70b223e1ba2c01953970b48a2e0c4ea3eeb9296610e6b3bfb2a2cce9e92e2d7ad61778b5f5a630e705e663835e915ba188c174a0a37fa - languageName: node - linkType: hard - "md5.js@npm:^1.3.4": version: 1.3.5 resolution: "md5.js@npm:1.3.5" @@ -8591,17 +8259,6 @@ __metadata: languageName: node linkType: hard -"memory-level@npm:^1.0.0": - version: 1.0.0 - resolution: "memory-level@npm:1.0.0" - dependencies: - abstract-level: ^1.0.0 - functional-red-black-tree: ^1.0.1 - module-error: ^1.0.1 - checksum: 80b1b7aedaf936e754adbcd7b9303018c3684fb32f9992fd967c448f145d177f16c724fbba9ed3c3590a9475fd563151eae664d69b83d2ad48714852e9fc5c72 - languageName: node - linkType: hard - "memorystream@npm:^0.3.1": version: 0.3.1 resolution: "memorystream@npm:0.3.1" @@ -9034,13 +8691,6 @@ __metadata: languageName: node linkType: hard -"module-error@npm:^1.0.1, module-error@npm:^1.0.2": - version: 1.0.2 - resolution: "module-error@npm:1.0.2" - checksum: 5d653e35bd55b3e95f8aee2cdac108082ea892e71b8f651be92cde43e4ee86abee4fa8bd7fc3fe5e68b63926d42f63c54cd17b87a560c31f18739295575a3962 - languageName: node - linkType: hard - "module-not-found-error@npm:^1.0.1": version: 1.0.1 resolution: "module-not-found-error@npm:1.0.1" @@ -9153,13 +8803,6 @@ __metadata: languageName: node linkType: hard -"napi-macros@npm:^2.2.2": - version: 2.2.2 - resolution: "napi-macros@npm:2.2.2" - checksum: c6f9bd71cdbbc37ddc3535aa5be481238641d89585b8a3f4d301cb89abf459e2d294810432bb7d12056d1f9350b1a0899a5afcf460237a3da6c398cf0fec7629 - languageName: node - linkType: hard - "natural-compare-lite@npm:^1.4.0": version: 1.4.0 resolution: "natural-compare-lite@npm:1.4.0" @@ -9961,7 +9604,7 @@ __metadata: languageName: node linkType: hard -"queue-microtask@npm:^1.2.2, queue-microtask@npm:^1.2.3": +"queue-microtask@npm:^1.2.2": version: 1.2.3 resolution: "queue-microtask@npm:1.2.3" checksum: b676f8c040cdc5b12723ad2f91414d267605b26419d5c821ff03befa817ddd10e238d22b25d604920340fd73efd8ba795465a0377c4adf45a4a41e4234e42dc4 @@ -10071,6 +9714,13 @@ __metadata: languageName: node linkType: hard +"readdirp@npm:^4.0.1": + version: 4.0.2 + resolution: "readdirp@npm:4.0.2" + checksum: 309376e717f94fb7eb61bec21e2603243a9e2420cd2e9bf94ddf026aefea0d7377ed1a62f016d33265682e44908049a55c3cfc2307450a1421654ea008489b39 + languageName: node + linkType: hard + "readdirp@npm:~3.6.0": version: 3.6.0 resolution: "readdirp@npm:3.6.0" @@ -10169,7 +9819,7 @@ __metadata: languageName: node linkType: hard -"require-from-string@npm:^2.0.0, require-from-string@npm:^2.0.2": +"require-from-string@npm:^2.0.2": version: 2.0.2 resolution: "require-from-string@npm:2.0.2" checksum: a03ef6895445f33a4015300c426699bc66b2b044ba7b670aa238610381b56d3f07c686251740d575e22f4c87531ba662d06937508f0f3c0f1ddc04db3130560b @@ -10324,17 +9974,6 @@ __metadata: languageName: node linkType: hard -"rimraf@npm:^2.2.8": - version: 2.7.1 - resolution: "rimraf@npm:2.7.1" - dependencies: - glob: ^7.1.3 - bin: - rimraf: ./bin.js - checksum: cdc7f6eacb17927f2a075117a823e1c5951792c6498ebcce81ca8203454a811d4cf8900314154d3259bb8f0b42ab17f67396a8694a54cae3283326e57ad250cd - languageName: node - linkType: hard - "rimraf@npm:^3.0.2": version: 3.0.2 resolution: "rimraf@npm:3.0.2" @@ -10374,15 +10013,6 @@ __metadata: languageName: node linkType: hard -"run-parallel-limit@npm:^1.1.0": - version: 1.1.0 - resolution: "run-parallel-limit@npm:1.1.0" - dependencies: - queue-microtask: ^1.2.2 - checksum: 672c3b87e7f939c684b9965222b361421db0930223ed1e43ebf0e7e48ccc1a022ea4de080bef4d5468434e2577c33b7681e3f03b7593fdc49ad250a55381123c - languageName: node - linkType: hard - "run-parallel@npm:^1.1.9": version: 1.2.0 resolution: "run-parallel@npm:1.2.0" @@ -10392,13 +10022,6 @@ __metadata: languageName: node linkType: hard -"rustbn.js@npm:~0.2.0": - version: 0.2.0 - resolution: "rustbn.js@npm:0.2.0" - checksum: 2148e7ba34e70682907ee29df4784639e6eb025481b2c91249403b7ec57181980161868d9aa24822a5075dd1bb5a180dfedc77309e5f0d27b6301f9b563af99a - languageName: node - linkType: hard - "rxjs@npm:^7.2.0, rxjs@npm:^7.5.5": version: 7.8.1 resolution: "rxjs@npm:7.8.1" @@ -10780,25 +10403,6 @@ __metadata: languageName: node linkType: hard -"solc@npm:0.7.3": - version: 0.7.3 - resolution: "solc@npm:0.7.3" - dependencies: - command-exists: ^1.2.8 - commander: 3.0.2 - follow-redirects: ^1.12.1 - fs-extra: ^0.30.0 - js-sha3: 0.8.0 - memorystream: ^0.3.1 - require-from-string: ^2.0.0 - semver: ^5.5.0 - tmp: 0.0.33 - bin: - solcjs: solcjs - checksum: 2d8eb16c6d8f648213c94dc8d977cffe5099cba7d41c82d92d769ef71ae8320a985065ce3d6c306440a85f8e8d2b27fb30bdd3ac38f69e5c1fa0ab8a3fb2f217 - languageName: node - linkType: hard - "solc@npm:0.8.26": version: 0.8.26 resolution: "solc@npm:0.8.26" @@ -12613,7 +12217,7 @@ __metadata: languageName: node linkType: hard -"yallist@npm:^3.0.0, yallist@npm:^3.0.2, yallist@npm:^3.1.1": +"yallist@npm:^3.0.0, yallist@npm:^3.1.1": version: 3.1.1 resolution: "yallist@npm:3.1.1" checksum: 48f7bb00dc19fc635a13a39fe547f527b10c9290e7b3e836b9a8f1ca04d4d342e85714416b3c2ab74949c9c66f9cebb0473e6bc353b79035356103b47641285d From 27ef7c55f70b0e87c6f607a54d927a1d7b84f945 Mon Sep 17 00:00:00 2001 From: web3rover Date: Thu, 7 Nov 2024 16:59:50 +0400 Subject: [PATCH 116/178] fix: converted to multichain commands --- .../proposals/arbitrumone/vip-018/index.ts | 22 - multisig/proposals/ethereum/vip-068/index.ts | 22 - .../proposals/opbnbmainnet/vip-024/index.ts | 16 - .../ethereum/vip-068/abi/vToken.json | 861 ------------------ .../opbnbmainnet/vip-024/abi/vToken.json | 861 ------------------ .../vip-392/abi/OmnichainProposalSender.json | 314 +++++++ .../vip-392}/abi/vToken.json | 0 .../vip-392/arbitrumone.ts | 25 +- simulations/vip-392/bscmainnet.ts | 32 +- .../vip-392/ethereum.ts | 25 +- .../vip-392/opbnbmainnet.ts | 23 +- vips/vip-392/bscmainnet.ts | 61 +- 12 files changed, 421 insertions(+), 1841 deletions(-) delete mode 100644 multisig/proposals/arbitrumone/vip-018/index.ts delete mode 100644 multisig/proposals/ethereum/vip-068/index.ts delete mode 100644 multisig/proposals/opbnbmainnet/vip-024/index.ts delete mode 100644 multisig/simulations/ethereum/vip-068/abi/vToken.json delete mode 100644 multisig/simulations/opbnbmainnet/vip-024/abi/vToken.json create mode 100644 simulations/vip-392/abi/OmnichainProposalSender.json rename {multisig/simulations/arbitrumone/vip-018 => simulations/vip-392}/abi/vToken.json (100%) rename multisig/simulations/arbitrumone/vip-018/index.ts => simulations/vip-392/arbitrumone.ts (58%) rename multisig/simulations/ethereum/vip-068/index.ts => simulations/vip-392/ethereum.ts (56%) rename multisig/simulations/opbnbmainnet/vip-024/index.ts => simulations/vip-392/opbnbmainnet.ts (53%) diff --git a/multisig/proposals/arbitrumone/vip-018/index.ts b/multisig/proposals/arbitrumone/vip-018/index.ts deleted file mode 100644 index fd1ed0334..000000000 --- a/multisig/proposals/arbitrumone/vip-018/index.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { makeProposal } from "../../../../src/utils"; - -export const vETH_CORE = "0x68a34332983f4Bf866768DD6D6E638b02eF5e1f0"; -export const vETH_LST = "0x39D6d13Ea59548637104E40e729E4aABE27FE106"; -export const IRM = "0x425dde630be832195619a06175ba45C827Dd3DCa"; - -export const vip018 = () => { - return makeProposal([ - { - target: vETH_CORE, - signature: "setInterestRateModel(address)", - params: [IRM], - }, - { - target: vETH_LST, - signature: "setInterestRateModel(address)", - params: [IRM], - }, - ]); -}; - -export default vip018; diff --git a/multisig/proposals/ethereum/vip-068/index.ts b/multisig/proposals/ethereum/vip-068/index.ts deleted file mode 100644 index af2e51ad0..000000000 --- a/multisig/proposals/ethereum/vip-068/index.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { makeProposal } from "../../../../src/utils"; - -export const vETH_CORE = "0x7c8ff7d2A1372433726f879BD945fFb250B94c65"; -export const vETH_LST = "0xc82780Db1257C788F262FBbDA960B3706Dfdcaf2"; -export const IRM = "0x2F81dAA9de0fD60fb9B105Cfc5b67A31Fda547b6"; - -export const vip068 = () => { - return makeProposal([ - { - target: vETH_CORE, - signature: "setInterestRateModel(address)", - params: [IRM], - }, - { - target: vETH_LST, - signature: "setInterestRateModel(address)", - params: [IRM], - }, - ]); -}; - -export default vip068; diff --git a/multisig/proposals/opbnbmainnet/vip-024/index.ts b/multisig/proposals/opbnbmainnet/vip-024/index.ts deleted file mode 100644 index d251815b1..000000000 --- a/multisig/proposals/opbnbmainnet/vip-024/index.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { makeProposal } from "../../../../src/utils"; - -export const vETH_CORE = "0x509e81eF638D489936FA85BC58F52Df01190d26C"; -export const IRM = "0x0d75544019e3015eEbF61F26595D08d60f3aC841"; - -export const vip024 = () => { - return makeProposal([ - { - target: vETH_CORE, - signature: "setInterestRateModel(address)", - params: [IRM], - }, - ]); -}; - -export default vip024; diff --git a/multisig/simulations/ethereum/vip-068/abi/vToken.json b/multisig/simulations/ethereum/vip-068/abi/vToken.json deleted file mode 100644 index d8cc1aae4..000000000 --- a/multisig/simulations/ethereum/vip-068/abi/vToken.json +++ /dev/null @@ -1,861 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], - "name": "AddReservesFactorFreshCheck", - "type": "error" - }, - { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, - { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, - { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], - "name": "LiquidateAccrueCollateralInterestFailed", - "type": "error" - }, - { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, - { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, - { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, - { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, - { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, - { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, - { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "AccrueInterest", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtRecovered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "Borrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "HealBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "LiquidateBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } - ], - "name": "NewComptroller", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "oldInterestRateModel", - "type": "address" - }, - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "newInterestRateModel", - "type": "address" - } - ], - "name": "NewMarketInterestRateModel", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } - ], - "name": "NewProtocolSeizeShare", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } - ], - "name": "NewProtocolShareReserve", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } - ], - "name": "NewReduceReservesBlockDelta", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } - ], - "name": "NewReserveFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } - ], - "name": "NewShortfallContract", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ProtocolSeize", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Redeem", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "RepayBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "ReservesAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "SpreadReservesReduced", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Transfer", - "type": "event" - }, - { - "inputs": [], - "name": "NO_ERROR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrualBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrueInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], - "name": "addReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "owner", "type": "address" }, - { "internalType": "address", "name": "spender", "type": "address" } - ], - "name": "allowance", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "approve", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "badDebt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], - "name": "badDebtRecovered", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOfUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], - "name": "borrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "borrowIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "borrowRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } - ], - "name": "decreaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "forceLiquidateBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountSnapshot", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCash", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "healBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "addedValue", "type": "uint256" } - ], - "name": "increaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "underlying_", "type": "address" }, - { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, - { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, - { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, - { "internalType": "string", "name": "name_", "type": "string" }, - { "internalType": "string", "name": "symbol_", "type": "string" }, - { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, - { "internalType": "address", "name": "admin_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { - "components": [ - { "internalType": "address", "name": "shortfall", "type": "address" }, - { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } - ], - "internalType": "struct VTokenInterface.RiskManagementInit", - "name": "riskManagement", - "type": "tuple" - }, - { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "interestRateModel", - "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isVToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } - ], - "name": "liquidateBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], - "name": "mint", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "mintBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolSeizeShareMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolShareReserve", - "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], - "name": "redeem", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], - "name": "redeemUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } - ], - "name": "redeemUnderlyingBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], - "name": "reduceReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockDelta", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], - "name": "repayBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "repayBorrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reserveFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], - "name": "setInterestRateModel", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], - "name": "setProtocolSeizeShare", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], - "name": "setProtocolShareReserve", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], - "name": "setReduceReservesBlockDelta", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], - "name": "setReserveFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], - "name": "setShortfallContract", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "shortfall", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "supplyRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrows", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrowsCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "totalReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transfer", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transferFrom", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "underlying", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/opbnbmainnet/vip-024/abi/vToken.json b/multisig/simulations/opbnbmainnet/vip-024/abi/vToken.json deleted file mode 100644 index d8cc1aae4..000000000 --- a/multisig/simulations/opbnbmainnet/vip-024/abi/vToken.json +++ /dev/null @@ -1,861 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], - "name": "AddReservesFactorFreshCheck", - "type": "error" - }, - { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, - { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, - { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, - { - "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], - "name": "LiquidateAccrueCollateralInterestFailed", - "type": "error" - }, - { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, - { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, - { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, - { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, - { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, - { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, - { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, - { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, - { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, - { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, - { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "AccrueInterest", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } - ], - "name": "BadDebtRecovered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "Borrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "HealBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "LiquidateBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Mint", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, - { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } - ], - "name": "NewComptroller", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "oldInterestRateModel", - "type": "address" - }, - { - "indexed": true, - "internalType": "contract InterestRateModel", - "name": "newInterestRateModel", - "type": "address" - } - ], - "name": "NewMarketInterestRateModel", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } - ], - "name": "NewProtocolSeizeShare", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } - ], - "name": "NewProtocolShareReserve", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } - ], - "name": "NewReduceReservesBlockDelta", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } - ], - "name": "NewReserveFactor", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } - ], - "name": "NewShortfallContract", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "ProtocolSeize", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } - ], - "name": "Redeem", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } - ], - "name": "RepayBorrow", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "ReservesAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } - ], - "name": "SpreadReservesReduced", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], - "name": "SweepToken", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "Transfer", - "type": "event" - }, - { - "inputs": [], - "name": "NO_ERROR", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrualBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accrueInterest", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], - "name": "addReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "owner", "type": "address" }, - { "internalType": "address", "name": "spender", "type": "address" } - ], - "name": "allowance", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "approve", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "badDebt", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], - "name": "badDebtRecovered", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], - "name": "balanceOfUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], - "name": "borrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "borrowBalanceStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } - ], - "name": "borrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "borrowIndex", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "borrowRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "comptroller", - "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "decimals", - "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } - ], - "name": "decreaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "exchangeRateStored", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, - { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } - ], - "name": "forceLiquidateBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], - "name": "getAccountSnapshot", - "outputs": [ - { "internalType": "uint256", "name": "error", "type": "uint256" }, - { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, - { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCash", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "payer", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "healBorrow", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "spender", "type": "address" }, - { "internalType": "uint256", "name": "addedValue", "type": "uint256" } - ], - "name": "increaseAllowance", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "underlying_", "type": "address" }, - { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, - { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, - { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, - { "internalType": "string", "name": "name_", "type": "string" }, - { "internalType": "string", "name": "symbol_", "type": "string" }, - { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, - { "internalType": "address", "name": "admin_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" }, - { - "components": [ - { "internalType": "address", "name": "shortfall", "type": "address" }, - { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } - ], - "internalType": "struct VTokenInterface.RiskManagementInit", - "name": "riskManagement", - "type": "tuple" - }, - { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } - ], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "interestRateModel", - "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "isVToken", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, - { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } - ], - "name": "liquidateBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], - "name": "mint", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "minter", "type": "address" }, - { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } - ], - "name": "mintBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolSeizeShareMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "protocolShareReserve", - "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], - "name": "redeem", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } - ], - "name": "redeemBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], - "name": "redeemUnderlying", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "redeemer", "type": "address" }, - { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } - ], - "name": "redeemUnderlyingBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], - "name": "reduceReserves", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockDelta", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "reduceReservesBlockNumber", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], - "name": "repayBorrow", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } - ], - "name": "repayBorrowBehalf", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "reserveFactorMantissa", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "liquidator", "type": "address" }, - { "internalType": "address", "name": "borrower", "type": "address" }, - { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } - ], - "name": "seize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], - "name": "setInterestRateModel", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], - "name": "setProtocolSeizeShare", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], - "name": "setProtocolShareReserve", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], - "name": "setReduceReservesBlockDelta", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], - "name": "setReserveFactor", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], - "name": "setShortfallContract", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "shortfall", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "supplyRatePerBlock", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], - "name": "sweepToken", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrows", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalBorrowsCurrent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "totalReserves", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "totalSupply", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transfer", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "src", "type": "address" }, - { "internalType": "address", "name": "dst", "type": "address" }, - { "internalType": "uint256", "name": "amount", "type": "uint256" } - ], - "name": "transferFrom", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "underlying", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-392/abi/OmnichainProposalSender.json b/simulations/vip-392/abi/OmnichainProposalSender.json new file mode 100644 index 000000000..66fd4df02 --- /dev/null +++ b/simulations/vip-392/abi/OmnichainProposalSender.json @@ -0,0 +1,314 @@ +[ + { + "inputs": [ + { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } + ], + "name": "ClearPayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } + ], + "name": "ExecuteRemoteProposal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "FallbackWithdraw", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } + ], + "name": "StorePayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], + "name": "TrustedRemoteRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "LZ_ENDPOINT", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourCommandsSent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLastProposalSentTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bool", "name": "useZro_", "type": "bool" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } + ], + "name": "estimateFees", + "outputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } + ], + "name": "execute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "fallbackWithdraw", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "proposalCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], + "name": "removeTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "retryExecute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" }, + { "internalType": "bytes", "name": "config_", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "storedExecutionHashes", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } +] diff --git a/multisig/simulations/arbitrumone/vip-018/abi/vToken.json b/simulations/vip-392/abi/vToken.json similarity index 100% rename from multisig/simulations/arbitrumone/vip-018/abi/vToken.json rename to simulations/vip-392/abi/vToken.json diff --git a/multisig/simulations/arbitrumone/vip-018/index.ts b/simulations/vip-392/arbitrumone.ts similarity index 58% rename from multisig/simulations/arbitrumone/vip-018/index.ts rename to simulations/vip-392/arbitrumone.ts index 0fbbae7b2..8b6f9f335 100644 --- a/multisig/simulations/arbitrumone/vip-018/index.ts +++ b/simulations/vip-392/arbitrumone.ts @@ -1,37 +1,34 @@ import { expect } from "chai"; -import { BigNumber } from "ethers"; -import { Contract } from "ethers"; +import { BigNumber, Contract } from "ethers"; import { ethers } from "hardhat"; +import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; -import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; -import { IRM, vETH_CORE, vETH_LST, vip018 } from "../../../proposals/arbitrumone/vip-018"; +import vip392, { ARBITRUM_IRM, ARBITRUM_vETH_CORE, ARBITRUM_vETH_LST } from "../../vips/vip-392/bscmainnet"; import VTOKEN_ABI from "./abi/vToken.json"; -forking(271293785, async () => { +forking(271980750, async () => { let vETHCore: Contract; let vETHLST: Contract; before(async () => { - vETHCore = await ethers.getContractAt(VTOKEN_ABI, vETH_CORE); - vETHLST = await ethers.getContractAt(VTOKEN_ABI, vETH_LST); + vETHCore = await ethers.getContractAt(VTOKEN_ABI, ARBITRUM_vETH_CORE); + vETHLST = await ethers.getContractAt(VTOKEN_ABI, ARBITRUM_vETH_LST); }); - describe("Post-VIP behavior", async () => { - before(async () => { - await pretendExecutingVip(await vip018()); - }); + testForkedNetworkVipCommands("vip392", await vip392()); + describe("Post-VIP behavior", async () => { it("check it correctly sets new interest rate model", async () => { const BLOCKS_PER_YEAR = BigNumber.from("31536000"); // equal to seconds in a year as it is timebased deployment let interestRateModel = await vETHCore.interestRateModel(); - expect(interestRateModel).to.equal(IRM); + expect(interestRateModel).to.equal(ARBITRUM_IRM); interestRateModel = await vETHLST.interestRateModel(); - expect(interestRateModel).to.equal(IRM); + expect(interestRateModel).to.equal(ARBITRUM_IRM); checkInterestRate( - IRM, + ARBITRUM_IRM, "vETH", { base: "0", diff --git a/simulations/vip-392/bscmainnet.ts b/simulations/vip-392/bscmainnet.ts index ff94da606..69d249792 100644 --- a/simulations/vip-392/bscmainnet.ts +++ b/simulations/vip-392/bscmainnet.ts @@ -1,34 +1,50 @@ import { expect } from "chai"; import { ethers } from "hardhat"; +import { expectEvents } from "src/utils"; import { forking, testVip } from "src/vip-framework"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; -import vip392, { VETH_LST_IRM, vETH_CORE, vETH_CORE_IRM, vETH_LST } from "../../vips/vip-392/bscmainnet"; +import vip392, { + BSC_VETH_LST_IRM, + BSC_vETH_CORE, + BSC_vETH_CORE_IRM, + BSC_vETH_LST, +} from "../../vips/vip-392/bscmainnet"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; import VTOKEN_CORE_POOL_ABI from "./abi/VTokenCorePool.json"; forking(43743361, async () => { const provider = ethers.provider; - const vETHCore = new ethers.Contract(vETH_CORE, VTOKEN_CORE_POOL_ABI, provider); - const vETHLST = new ethers.Contract(vETH_LST, VTOKEN_CORE_POOL_ABI, provider); + const vETHCore = new ethers.Contract(BSC_vETH_CORE, VTOKEN_CORE_POOL_ABI, provider); + const vETHLST = new ethers.Contract(BSC_vETH_LST, VTOKEN_CORE_POOL_ABI, provider); - testVip("VIP-392", await vip392()); + testVip("VIP-392", await vip392(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [3, 0], + ); + }, + }); describe("Post-VIP behavior", async () => { it("has the new interest rate model addresses", async () => { - expect(await vETHCore.interestRateModel()).to.equal(vETH_CORE_IRM); - expect(await vETHLST.interestRateModel()).to.equal(VETH_LST_IRM); + expect(await vETHCore.interestRateModel()).to.equal(BSC_vETH_CORE_IRM); + expect(await vETHLST.interestRateModel()).to.equal(BSC_VETH_LST_IRM); }); describe("new interest rate model parameters", async () => { - checkInterestRate(vETH_CORE_IRM, "vETH (Core)", { + checkInterestRate(BSC_vETH_CORE_IRM, "vETH (Core)", { base: "0", multiplier: "0.03", jump: "4.5", kink: "0.9", }); - checkInterestRate(VETH_LST_IRM, "vETH (LST)", { + checkInterestRate(BSC_VETH_LST_IRM, "vETH (LST)", { base: "0", multiplier: "0.03", jump: "4.5", diff --git a/multisig/simulations/ethereum/vip-068/index.ts b/simulations/vip-392/ethereum.ts similarity index 56% rename from multisig/simulations/ethereum/vip-068/index.ts rename to simulations/vip-392/ethereum.ts index fcfcaca98..83995da6f 100644 --- a/multisig/simulations/ethereum/vip-068/index.ts +++ b/simulations/vip-392/ethereum.ts @@ -1,37 +1,34 @@ import { expect } from "chai"; -import { BigNumber } from "ethers"; -import { Contract } from "ethers"; +import { BigNumber, Contract } from "ethers"; import { ethers } from "hardhat"; +import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; -import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; -import { IRM, vETH_CORE, vETH_LST, vip068 } from "../../../proposals/ethereum/vip-068"; +import vip392, { ETHEREUM_IRM, ETHEREUM_vETH_CORE, ETHEREUM_vETH_LST } from "../../vips/vip-392/bscmainnet"; import VTOKEN_ABI from "./abi/vToken.json"; -forking(21121545, async () => { +forking(21131771, async () => { let vETHCore: Contract; let vETHLST: Contract; before(async () => { - vETHCore = await ethers.getContractAt(VTOKEN_ABI, vETH_CORE); - vETHLST = await ethers.getContractAt(VTOKEN_ABI, vETH_LST); + vETHCore = await ethers.getContractAt(VTOKEN_ABI, ETHEREUM_vETH_CORE); + vETHLST = await ethers.getContractAt(VTOKEN_ABI, ETHEREUM_vETH_LST); }); - describe("Post-VIP behavior", async () => { - before(async () => { - await pretendExecutingVip(await vip068()); - }); + testForkedNetworkVipCommands("vip392", await vip392()); + describe("Post-VIP behavior", async () => { it("check it correctly sets new interest rate model", async () => { const BLOCKS_PER_YEAR = BigNumber.from(2628000); let interestRateModel = await vETHCore.interestRateModel(); - expect(interestRateModel).to.equal(IRM); + expect(interestRateModel).to.equal(ETHEREUM_IRM); interestRateModel = await vETHLST.interestRateModel(); - expect(interestRateModel).to.equal(IRM); + expect(interestRateModel).to.equal(ETHEREUM_IRM); checkInterestRate( - IRM, + ETHEREUM_IRM, "vETH", { base: "0", diff --git a/multisig/simulations/opbnbmainnet/vip-024/index.ts b/simulations/vip-392/opbnbmainnet.ts similarity index 53% rename from multisig/simulations/opbnbmainnet/vip-024/index.ts rename to simulations/vip-392/opbnbmainnet.ts index 86ded067d..ed34a458d 100644 --- a/multisig/simulations/opbnbmainnet/vip-024/index.ts +++ b/simulations/vip-392/opbnbmainnet.ts @@ -1,33 +1,30 @@ import { expect } from "chai"; -import { BigNumber } from "ethers"; -import { Contract } from "ethers"; +import { BigNumber, Contract } from "ethers"; import { ethers } from "hardhat"; +import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; -import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; -import { IRM, vETH_CORE, vip024 } from "../../../proposals/opbnbmainnet/vip-024"; +import vip392, { OPBNB_IRM, OPBNB_vETH_CORE } from "../../vips/vip-392/bscmainnet"; import VTOKEN_ABI from "./abi/vToken.json"; -forking(39057882, async () => { +forking(39230450, async () => { let vETHCore: Contract; before(async () => { - vETHCore = await ethers.getContractAt(VTOKEN_ABI, vETH_CORE); + vETHCore = await ethers.getContractAt(VTOKEN_ABI, OPBNB_vETH_CORE); }); - describe("Post-VIP behavior", async () => { - before(async () => { - await pretendExecutingVip(await vip024()); - }); + testForkedNetworkVipCommands("vip392", await vip392()); + describe("Post-VIP behavior", async () => { it("check it correctly sets new interest rate model", async () => { - const BLOCKS_PER_YEAR = BigNumber.from("31536000"); + const BLOCKS_PER_YEAR = BigNumber.from("31536000"); // equal to seconds in a year as it is timebased deployment const interestRateModel = await vETHCore.interestRateModel(); - expect(interestRateModel).to.equal(IRM); + expect(interestRateModel).to.equal(OPBNB_IRM); checkInterestRate( - IRM, + OPBNB_IRM, "vETH", { base: "0", diff --git a/vips/vip-392/bscmainnet.ts b/vips/vip-392/bscmainnet.ts index cd62439af..60909c0ca 100644 --- a/vips/vip-392/bscmainnet.ts +++ b/vips/vip-392/bscmainnet.ts @@ -1,10 +1,21 @@ -import { ProposalType } from "src/types"; +import { LzChainId, ProposalType } from "src/types"; import { makeProposal } from "src/utils"; -export const VETH_LST_IRM = "0x49a06B82b3c907AB140879F73f1d8dE262962c30"; -export const vETH_CORE_IRM = "0x3aa125788FC6b9F801772baEa887aA40328015e9"; -export const vETH_CORE = "0xf508fCD89b8bd15579dc79A6827cB4686A3592c8"; -export const vETH_LST = "0xeCCACF760FEA7943C5b0285BD09F601505A29c05"; +export const BSC_VETH_LST_IRM = "0x49a06B82b3c907AB140879F73f1d8dE262962c30"; +export const BSC_vETH_CORE_IRM = "0x3aa125788FC6b9F801772baEa887aA40328015e9"; +export const BSC_vETH_CORE = "0xf508fCD89b8bd15579dc79A6827cB4686A3592c8"; +export const BSC_vETH_LST = "0xeCCACF760FEA7943C5b0285BD09F601505A29c05"; + +export const ARBITRUM_vETH_CORE = "0x68a34332983f4Bf866768DD6D6E638b02eF5e1f0"; +export const ARBITRUM_vETH_LST = "0x39D6d13Ea59548637104E40e729E4aABE27FE106"; +export const ARBITRUM_IRM = "0x425dde630be832195619a06175ba45C827Dd3DCa"; + +export const ETHEREUM_vETH_CORE = "0x7c8ff7d2A1372433726f879BD945fFb250B94c65"; +export const ETHEREUM_vETH_LST = "0xc82780Db1257C788F262FBbDA960B3706Dfdcaf2"; +export const ETHEREUM_IRM = "0x2F81dAA9de0fD60fb9B105Cfc5b67A31Fda547b6"; + +export const OPBNB_vETH_CORE = "0x509e81eF638D489936FA85BC58F52Df01190d26C"; +export const OPBNB_IRM = "0x0d75544019e3015eEbF61F26595D08d60f3aC841"; const vip392 = () => { const meta = { @@ -19,18 +30,48 @@ const vip392 = () => { return makeProposal( [ { - target: vETH_CORE, + target: BSC_vETH_CORE, signature: "_setInterestRateModel(address)", - params: [vETH_CORE_IRM], + params: [BSC_vETH_CORE_IRM], + }, + { + target: BSC_vETH_LST, + signature: "setInterestRateModel(address)", + params: [BSC_VETH_LST_IRM], + }, + { + target: ARBITRUM_vETH_CORE, + signature: "setInterestRateModel(address)", + params: [ARBITRUM_IRM], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ARBITRUM_vETH_LST, + signature: "setInterestRateModel(address)", + params: [ARBITRUM_IRM], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ETHEREUM_vETH_CORE, + signature: "setInterestRateModel(address)", + params: [ETHEREUM_IRM], + dstChainId: LzChainId.ethereum, + }, + { + target: ETHEREUM_vETH_LST, + signature: "setInterestRateModel(address)", + params: [ETHEREUM_IRM], + dstChainId: LzChainId.ethereum, }, { - target: vETH_LST, + target: OPBNB_vETH_CORE, signature: "setInterestRateModel(address)", - params: [VETH_LST_IRM], + params: [OPBNB_IRM], + dstChainId: LzChainId.opbnbmainnet, }, ], meta, - ProposalType.FAST_TRACK, + ProposalType.REGULAR, ); }; From 07947bcbd76e47a721c5ac8bd1cc023cd0677941 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Thu, 7 Nov 2024 19:28:43 +0530 Subject: [PATCH 117/178] fix: simulation --- simulations/vip-395/zksyncmainnet.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/simulations/vip-395/zksyncmainnet.ts b/simulations/vip-395/zksyncmainnet.ts index dab534a94..5138a5d13 100644 --- a/simulations/vip-395/zksyncmainnet.ts +++ b/simulations/vip-395/zksyncmainnet.ts @@ -71,7 +71,7 @@ forking(48280698, async () => { expect(await executor.proposalTimelocks(2)).equals(CRITICAL_TIMELOCK); // Check trusted remote - expect(await executor.trustedRemoteLookup(LzChainId.bsctestnet)).equals( + expect(await executor.trustedRemoteLookup(LzChainId.bscmainnet)).equals( ethers.utils.solidityPack( ["address", "address"], [getOmnichainProposalSenderAddress(), zksyncmainnet.OMNICHAIN_GOVERNANCE_EXECUTOR], From 04d05f6264982fdad03ed358461623d6a88c0518 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Thu, 7 Nov 2024 16:11:00 +0100 Subject: [PATCH 118/178] fix: set the right expected protocol seize share for eBTC --- simulations/vip-391/ethereum.ts | 2 +- simulations/vip-391/sepolia.ts | 2 +- vips/vip-391/bsctestnet.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/simulations/vip-391/ethereum.ts b/simulations/vip-391/ethereum.ts index 1309260a4..c4765b488 100644 --- a/simulations/vip-391/ethereum.ts +++ b/simulations/vip-391/ethereum.ts @@ -119,7 +119,7 @@ forking(21130278, async () => { }); it("check protocol seize share", async () => { - expect(await veBTCContract.protocolSeizeShareMantissa()).equals(parseUnits("0.01", 18)); + expect(await veBTCContract.protocolSeizeShareMantissa()).equals(parseUnits("0.05", 18)); }); it("check vToken", async () => { diff --git a/simulations/vip-391/sepolia.ts b/simulations/vip-391/sepolia.ts index 1b26315df..33c8d90ed 100644 --- a/simulations/vip-391/sepolia.ts +++ b/simulations/vip-391/sepolia.ts @@ -102,7 +102,7 @@ forking(6976822, async () => { }); it("check protocol seize share", async () => { - expect(await veBTCContract.protocolSeizeShareMantissa()).equals(parseUnits("0.01", 18)); + expect(await veBTCContract.protocolSeizeShareMantissa()).equals(parseUnits("0.05", 18)); }); it("check vToken", async () => { diff --git a/vips/vip-391/bsctestnet.ts b/vips/vip-391/bsctestnet.ts index 0512b5262..d78ee262c 100644 --- a/vips/vip-391/bsctestnet.ts +++ b/vips/vip-391/bsctestnet.ts @@ -35,7 +35,7 @@ const CONVERSION_INCENTIVE = parseUnits("0.0001", 18); const vip391 = () => { const meta = { version: "v2", - title: "VIP-391", + title: "VIP-391 [Ethereum] New eBTC market in the Core pool", description: `### Description`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", From 8efd1cae819519f8c5538e5e93eb3275bc186507 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Thu, 7 Nov 2024 16:24:10 +0100 Subject: [PATCH 119/178] fix: remove command overwriting the protocol seize share for eBTC --- vips/vip-391/bscmainnet.ts | 6 ------ 1 file changed, 6 deletions(-) diff --git a/vips/vip-391/bscmainnet.ts b/vips/vip-391/bscmainnet.ts index 91182ccde..49b835dd2 100644 --- a/vips/vip-391/bscmainnet.ts +++ b/vips/vip-391/bscmainnet.ts @@ -79,12 +79,6 @@ const vip391 = () => { params: [[veBTC, CF, LT, INITIAL_SUPPLY, ethereum.VTREASURY, SUPPLY_CAP, BORROW_CAP]], dstChainId: LzChainId.ethereum, }, - { - target: veBTC, - signature: "setProtocolSeizeShare(uint256)", - params: [parseUnits("0.01", 18)], - dstChainId: LzChainId.ethereum, - }, // Conversion config { From bd3f68bfe8eaff4e8a0c918a4bd6eb2867bfab4c Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Thu, 7 Nov 2024 13:53:39 +0100 Subject: [PATCH 120/178] refactor: set the right id for the TX to be used in the VIP 393 --- multisig/proposals/ethereum/{vip-067 => vip-068}/index.ts | 4 ++-- .../ethereum/{vip-067 => vip-068}/abi/erc20.json | 0 multisig/simulations/ethereum/{vip-067 => vip-068}/index.ts | 4 ++-- vips/vip-393/bscmainnet.ts | 6 +++--- 4 files changed, 7 insertions(+), 7 deletions(-) rename multisig/proposals/ethereum/{vip-067 => vip-068}/index.ts (91%) rename multisig/simulations/ethereum/{vip-067 => vip-068}/abi/erc20.json (100%) rename multisig/simulations/ethereum/{vip-067 => vip-068}/index.ts (87%) diff --git a/multisig/proposals/ethereum/vip-067/index.ts b/multisig/proposals/ethereum/vip-068/index.ts similarity index 91% rename from multisig/proposals/ethereum/vip-067/index.ts rename to multisig/proposals/ethereum/vip-068/index.ts index bdc8c3994..e25613058 100644 --- a/multisig/proposals/ethereum/vip-067/index.ts +++ b/multisig/proposals/ethereum/vip-068/index.ts @@ -8,7 +8,7 @@ const { ethereum } = NETWORK_ADDRESSES; export const EIGEN = "0xec53bF9167f50cDEB3Ae105f56099aaaB9061F83"; export const INITIAL_SUPPLY = parseUnits("1854.883016", 18); -export const vip067 = () => { +export const vip068 = () => { return makeProposal([ { target: ethereum.VTREASURY, @@ -18,4 +18,4 @@ export const vip067 = () => { ]); }; -export default vip067; +export default vip068; diff --git a/multisig/simulations/ethereum/vip-067/abi/erc20.json b/multisig/simulations/ethereum/vip-068/abi/erc20.json similarity index 100% rename from multisig/simulations/ethereum/vip-067/abi/erc20.json rename to multisig/simulations/ethereum/vip-068/abi/erc20.json diff --git a/multisig/simulations/ethereum/vip-067/index.ts b/multisig/simulations/ethereum/vip-068/index.ts similarity index 87% rename from multisig/simulations/ethereum/vip-067/index.ts rename to multisig/simulations/ethereum/vip-068/index.ts index 5e44d85f8..6304c06b7 100644 --- a/multisig/simulations/ethereum/vip-067/index.ts +++ b/multisig/simulations/ethereum/vip-068/index.ts @@ -5,7 +5,7 @@ import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; -import vip067, { EIGEN } from "../../../proposals/ethereum/vip-067"; +import vip068, { EIGEN } from "../../../proposals/ethereum/vip-068"; import ERC20_ABI from "./abi/erc20.json"; forking(21135461, async () => { @@ -14,7 +14,7 @@ forking(21135461, async () => { describe("Post-VIP behavior", async () => { before(async () => { eigenContract = new ethers.Contract(EIGEN, ERC20_ABI, ethers.provider); - await pretendExecutingVip(await vip067()); + await pretendExecutingVip(await vip068()); }); it("check balance", async () => { diff --git a/vips/vip-393/bscmainnet.ts b/vips/vip-393/bscmainnet.ts index 5b834736a..933639375 100644 --- a/vips/vip-393/bscmainnet.ts +++ b/vips/vip-393/bscmainnet.ts @@ -37,7 +37,7 @@ const vip393 = (maxStalePeriod?: number) => { const meta = { version: "v2", title: "VIP-393 [Ethereum] New EIGEN market in the Core pool", - description: `####Summary + description: `#### Summary If passed, following the Community proposal “[Support EIGEN as collateral on Venus Protocol Ethereum Core Pool](https://community.venus.io/t/support-eigen-as-collateral-on-venus-protocol-ethereum-core-pool/4615)” and [the associated snapshot](https://snapshot.org/#/venus-xvs.eth/proposal/0x171c3ffba6886856609e3db5b2a701a4cdeb73ab91fb7a165387475234729b6b), this VIP adds a market for [EIGEN](https://etherscan.io/address/0xec53bf9167f50cdeb3ae105f56099aaab9061f83) into the Core pool on Ethereum, and refunds the [Community Wallet](https://bscscan.com/address/0xc444949e0054A23c44Fc45789738bdF64aed2391) the provided bootstrap liquidity. @@ -55,7 +55,7 @@ Underlying token: [EIGEN](https://etherscan.io/address/0xec53bf9167f50cdeb3ae105 - Liquidation threshold: 60% - Reserve factor: 25% -Bootstrap liquidity: 1,854.88 EIGEN - provided by the [Venus Treasury](https://bscscan.com/address/0xf322942f644a996a617bd29c16bd7d231d9f35e9). +Bootstrap liquidity: 2,204.50 EIGEN - provided by the [Venus Treasury](https://bscscan.com/address/0xf322942f644a996a617bd29c16bd7d231d9f35e9). Interest rate curve for the new market: @@ -75,7 +75,7 @@ We applied the following security procedures for this upgrade: - **VIP execution simulation**: in a simulation environment, validating the new market is properly added to the Core pool on Ethereum, with the right parameters and the expected bootstrap liquidity - **Deployment on testnet**: the same market has been deployed to Sepolia, and used in the Venus Protocol testnet deployment -The Community Wallet [provided the bootstrap liquidity](https://etherscan.io/tx/0x84c524c8f37f3cb30cad66befe760ad46d51dbfdf371a1347c82d3cbe76df50e) (1,854.88 EIGEN), spending 5,000 USDC, that will be refunded in this VIP with funds from the Venus Treasury on BNB Chain. +The Community Wallet provided the bootstrap liquidity ([here](https://etherscan.io/tx/0x84c524c8f37f3cb30cad66befe760ad46d51dbfdf371a1347c82d3cbe76df50e) and [here](https://etherscan.io/tx/0x0e06e43adf7d02decff5dc38c2678d3b1366880000ef2f6605a08cd17c2159fa)), spending 6,000 USDC, that will be refunded in this VIP with funds from the [Venus Treasury on BNB Chain](https://bscscan.com/address/0xf322942f644a996a617bd29c16bd7d231d9f35e9). Part of the bootstrap liquidity is available on the [Venus Treasury on Ethereum](https://etherscan.io/address/0xFD9B071168bC27DBE16406eC3Aba050Ce8Eb22FA). If this VIP passes, [this](https://app.safe.global/transactions/tx?safe=eth:0x285960C5B22fD66A736C7136967A3eB15e93CC67&id=multisig_0x285960C5B22fD66A736C7136967A3eB15e93CC67_0xd0d5a8d8203443471dff3f7330dc3b62bb6e43aac2bd5003b08f84da15673f5b) multisig transaction will be executed to withdraw those funds, allowing Governance to supply them to the new EIGEN market. #### Deployed contracts From e38f48a1e3b48925a825825bc52c94301498d9da Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Fri, 8 Nov 2024 09:54:54 +0530 Subject: [PATCH 121/178] refactor: prime configuration on arbitrum sepolia --- .../arbitrumsepolia/vip-015/index.ts | 113 -- .../arbitrumsepolia/vip-015/index.ts | 18 +- simulations/vip-395/abi/ILComptroller.json | 929 +++++++++ simulations/vip-395/abi/Prime.json | 1787 +++++++++++++++++ .../vip-395/abi/PrimeLiquidityProvider.json | 385 ++++ simulations/vip-395/arbitrumsepolia.ts | 97 + simulations/vip-395/bsctestnet.ts | 7 + vips/vip-395/bsctestnet.ts | 107 + 8 files changed, 3313 insertions(+), 130 deletions(-) create mode 100644 simulations/vip-395/abi/ILComptroller.json create mode 100644 simulations/vip-395/abi/Prime.json create mode 100644 simulations/vip-395/abi/PrimeLiquidityProvider.json create mode 100644 simulations/vip-395/arbitrumsepolia.ts create mode 100644 simulations/vip-395/bsctestnet.ts create mode 100644 vips/vip-395/bsctestnet.ts diff --git a/multisig/proposals/arbitrumsepolia/vip-015/index.ts b/multisig/proposals/arbitrumsepolia/vip-015/index.ts index d7eeff842..57d26ab4b 100644 --- a/multisig/proposals/arbitrumsepolia/vip-015/index.ts +++ b/multisig/proposals/arbitrumsepolia/vip-015/index.ts @@ -1,4 +1,3 @@ -import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { makeProposal } from "src/utils"; @@ -17,12 +16,6 @@ export const PRIME_NEW_IMPLEMENTATION = "0x507866eCb585275E006D9098867a0e9B08C11 export const PRIME_OLD_IMPLEMENTATION = "0x255EFC81Ba715FA7C2C27bdd983A3CeF9BB07fEf"; export const PROXY_ADMIN = "0xA78A1Df376c3CEeBC5Fab574fe6EdDbbF76fd03e"; -export const VUSDT_CORE = "0xdEFbf0F9Ab6CdDd0a1FdDC894b358D0c0a39B052"; -export const VUSDC_CORE = "0xd9d1e754464eFc7493B177d2c7be04816E089b4C"; -export const VWBTC_CORE = "0x49FB90A5815904649C44B87001a160C1301D6a2C"; -export const VWETH_LST = "0xd7057250b439c0849377bB6C3263eb8f9cf49d98"; -const ACM = "0xa36AD96441cB931D8dFEAAaC97D3FaB4B39E590F"; - const vip015 = () => { return makeProposal([ { @@ -40,76 +33,6 @@ const vip015 = () => { signature: "upgrade(address,address)", params: [PRIME, PRIME_OLD_IMPLEMENTATION], }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [PLP, "setTokensDistributionSpeed(address[],uint256[])", arbitrumsepolia.GUARDIAN], - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [PLP, "setMaxTokensDistributionSpeed(address[],uint256[])", arbitrumsepolia.GUARDIAN], - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [PLP, "setMaxLoopsLimit(uint256)", arbitrumsepolia.GUARDIAN], - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [PLP, "pauseFundsTransfer()", arbitrumsepolia.GUARDIAN], - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [PLP, "resumeFundsTransfer()", arbitrumsepolia.GUARDIAN], - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [PRIME, "updateAlpha(uint128,uint128)", arbitrumsepolia.GUARDIAN], - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [PRIME, "updateMultipliers(address,uint256,uint256)", arbitrumsepolia.GUARDIAN], - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [PRIME, "setStakedAt(address[],uint256[])", arbitrumsepolia.GUARDIAN], - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [PRIME, "addMarket(address,address,uint256,uint256)", arbitrumsepolia.GUARDIAN], - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [PRIME, "setLimit(uint256,uint256)", arbitrumsepolia.GUARDIAN], - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [PRIME, "setMaxLoopsLimit(uint256)", arbitrumsepolia.GUARDIAN], - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [PRIME, "issue(bool,address[])", arbitrumsepolia.GUARDIAN], - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [PRIME, "burn(address)", arbitrumsepolia.GUARDIAN], - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [PRIME, "togglePause()", arbitrumsepolia.GUARDIAN], - }, { target: COMPTROLLER_CORE, signature: "setPrimeToken(address)", @@ -125,42 +48,6 @@ const vip015 = () => { signature: "initializeTokens(address[])", params: [[WETH, WBTC, USDC, USDT]], }, - { - target: PLP, - signature: "setTokensDistributionSpeed(address[],uint256[])", - params: [ - [WETH, WBTC, USDC, USDT], - [0, 0, 0, 0], - ], - }, - { - target: PRIME, - signature: "addMarket(address,address,uint256,uint256)", - params: [COMPTROLLER_CORE, VWBTC_CORE, ethers.utils.parseEther("2"), ethers.utils.parseEther("4")], - }, - { - target: PRIME, - signature: "addMarket(address,address,uint256,uint256)", - params: [COMPTROLLER_CORE, VUSDC_CORE, ethers.utils.parseEther("2"), ethers.utils.parseEther("4")], - }, - { - target: PRIME, - signature: "addMarket(address,address,uint256,uint256)", - params: [COMPTROLLER_CORE, VUSDT_CORE, ethers.utils.parseEther("2"), ethers.utils.parseEther("4")], - }, - { - target: PRIME, - signature: "addMarket(address,address,uint256,uint256)", - params: [COMPTROLLER_LST, VWETH_LST, ethers.utils.parseEther("2"), ethers.utils.parseEther("4")], - }, - { - target: PRIME, - signature: "setLimit(uint256,uint256)", - params: [ - 0, // irrevocable - 500, // revocable - ], - }, ]); }; diff --git a/multisig/simulations/arbitrumsepolia/vip-015/index.ts b/multisig/simulations/arbitrumsepolia/vip-015/index.ts index 8a227910d..4a3edb40f 100644 --- a/multisig/simulations/arbitrumsepolia/vip-015/index.ts +++ b/multisig/simulations/arbitrumsepolia/vip-015/index.ts @@ -11,10 +11,6 @@ import vip015, { PRIME, USDC, USDT, - VUSDC_CORE, - VUSDT_CORE, - VWBTC_CORE, - VWETH_LST, WBTC, WETH, } from "../../../proposals/arbitrumsepolia/vip-015"; @@ -24,7 +20,7 @@ import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; const { arbitrumsepolia } = NETWORK_ADDRESSES; -forking(94278700, async () => { +forking(95153347, async () => { const provider = ethers.provider; let prime: Contract; let plp: Contract; @@ -73,18 +69,6 @@ forking(94278700, async () => { expect(await comptrollerLst.prime()).to.be.equal(PRIME); }); - it("Prime should contain correct markets", async () => { - expect((await prime.markets(VUSDC_CORE))[4]).to.be.equal(true); - expect((await prime.markets(VUSDT_CORE))[4]).to.be.equal(true); - expect((await prime.markets(VWBTC_CORE))[4]).to.be.equal(true); - expect((await prime.markets(VWETH_LST))[4]).to.be.equal(true); - }); - - it("Prime should have correct number of revocable and irrevocable tokens", async () => { - expect(await prime.irrevocableLimit()).to.equal(0); - expect(await prime.revocableLimit()).to.equal(500); - }); - it("Plp should have correct tokens", async () => { expect(await plp.lastAccruedBlockOrSecond(USDT)).to.be.gt(0); expect(await plp.lastAccruedBlockOrSecond(USDC)).to.be.gt(0); diff --git a/simulations/vip-395/abi/ILComptroller.json b/simulations/vip-395/abi/ILComptroller.json new file mode 100644 index 000000000..56890d9b3 --- /dev/null +++ b/simulations/vip-395/abi/ILComptroller.json @@ -0,0 +1,929 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum ComptrollerStorage.Action", "name": "action", "type": "uint8" } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, + { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, + { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, + { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, + { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, + { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "TooMuchRepay", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "expectedSender", "type": "address" }, + { "internalType": "address", "name": "actualSender", "type": "address" } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "enum ComptrollerStorage.Action", "name": "action", "type": "uint8" }, + { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "accountAssets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum ComptrollerStorage.Action", "name": "action", "type": "uint8" } + ], + "name": "actionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allMarkets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "approvedDelegates", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "borrowCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "contract VToken", "name": "vToken", "type": "address" } + ], + "name": "checkMembership", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], + "name": "enterMarkets", + "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], + "name": "exitMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAssetsIn", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getBorrowingPower", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "vTokenModify", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isForcedLiquidationEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "isMarketListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [ + { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "bool", "name": "isListed", "type": "bool" }, + { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "seizerContract", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, + { "internalType": "enum ComptrollerStorage.Action[]", "name": "actionsList", "type": "uint8[]" }, + { "internalType": "bool", "name": "paused", "type": "bool" } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "supplyCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "delegate", "type": "address" }, + { "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-395/abi/Prime.json b/simulations/vip-395/abi/Prime.json new file mode 100644 index 000000000..0895c7575 --- /dev/null +++ b/simulations/vip-395/abi/Prime.json @@ -0,0 +1,1787 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "_wrappedNativeToken", + "type": "address" + }, + { + "internalType": "address", + "name": "_nativeMarket", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_blocksPerYear", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_stakingPeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_minimumStakedXVS", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_maximumXVSCap", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "_timeBased", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [], + "name": "AssetAlreadyExists", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "int256", + "name": "x", + "type": "int256" + } + ], + "name": "ExpTooLarge", + "type": "error" + }, + { + "inputs": [], + "name": "IneligibleToClaim", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidAddress", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidAlphaArguments", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidBlocksPerYear", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidComptroller", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidFixedPoint", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "n", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "d", + "type": "uint256" + } + ], + "name": "InvalidFraction", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidLength", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidLimit", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidTimeBasedConfiguration", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidTimestamp", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidVToken", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "int256", + "name": "x", + "type": "int256" + } + ], + "name": "LnNonRealResult", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "int256", + "name": "x", + "type": "int256" + } + ], + "name": "LnTooLarge", + "type": "error" + }, + { + "inputs": [], + "name": "MarketAlreadyExists", + "type": "error" + }, + { + "inputs": [], + "name": "MarketNotSupported", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "loopsLimit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "requiredLoops", + "type": "uint256" + } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [], + "name": "NoScoreUpdatesRequired", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "UserHasNoPrimeToken", + "type": "error" + }, + { + "inputs": [], + "name": "WaitMoreTime", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint128", + "name": "oldNumerator", + "type": "uint128" + }, + { + "indexed": true, + "internalType": "uint128", + "name": "oldDenominator", + "type": "uint128" + }, + { + "indexed": true, + "internalType": "uint128", + "name": "newNumerator", + "type": "uint128" + }, + { + "indexed": false, + "internalType": "uint128", + "name": "newDenominator", + "type": "uint128" + } + ], + "name": "AlphaUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "Burn", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "InterestClaimed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "supplyMultiplier", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "borrowMultiplier", + "type": "uint256" + } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMaxLoopsLimit", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newmaxLoopsLimit", + "type": "uint256" + } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "isIrrevocable", + "type": "bool" + } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "oldIrrevocableLimit", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "oldRevocableLimit", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "newIrrevocableLimit", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newRevocableLimit", + "type": "uint256" + } + ], + "name": "MintLimitsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "oldSupplyMultiplier", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "oldBorrowMultiplier", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSupplyMultiplier", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newBorrowMultiplier", + "type": "uint256" + } + ], + "name": "MultiplierUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "timestamp", + "type": "uint256" + } + ], + "name": "StakedAtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "TokenUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "UserScoreUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "MAXIMUM_XVS_CAP", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MINIMUM_STAKED_XVS", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_MARKET", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "STAKING_PERIOD", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WRAPPED_NATIVE_TOKEN", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "accrueInterest", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "accrueInterestAndUpdateScore", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "supplyMultiplier", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowMultiplier", + "type": "uint256" + } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "alphaDenominator", + "outputs": [ + { + "internalType": "uint128", + "name": "", + "type": "uint128" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "alphaNumerator", + "outputs": [ + { + "internalType": "uint128", + "name": "", + "type": "uint128" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "calculateAPR", + "outputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "supplyAPR", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAPR", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "totalScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "userScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "xvsBalanceForScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "capital", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "cappedSupply", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "cappedBorrow", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supplyCapUSD", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowCapUSD", + "type": "uint256" + } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "claim", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "claimInterest", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "claimInterest", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "claimTimeRemaining", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrow", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supply", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "xvsStaked", + "type": "uint256" + } + ], + "name": "estimateAPR", + "outputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "supplyAPR", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAPR", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "totalScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "userScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "xvsBalanceForScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "capital", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "cappedSupply", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "cappedBorrow", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supplyCapUSD", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowCapUSD", + "type": "uint256" + } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [ + { + "internalType": "address[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "getInterestAccrued", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "getPendingRewards", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "rewardToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "internalType": "struct PrimeStorageV1.PendingReward[]", + "name": "pendingRewards", + "type": "tuple[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "incomeDistributionYearly", + "outputs": [ + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "xvsVault_", + "type": "address" + }, + { + "internalType": "address", + "name": "xvsVaultRewardToken_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "xvsVaultPoolId_", + "type": "uint256" + }, + { + "internalType": "uint128", + "name": "alphaNumerator_", + "type": "uint128" + }, + { + "internalType": "uint128", + "name": "alphaDenominator_", + "type": "uint128" + }, + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + }, + { + "internalType": "address", + "name": "primeLiquidityProvider_", + "type": "address" + }, + { + "internalType": "address", + "name": "comptroller_", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "loopsLimit_", + "type": "uint256" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "poolRegistry_", + "type": "address" + } + ], + "name": "initializeV2", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "interests", + "outputs": [ + { + "internalType": "uint256", + "name": "accrued", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "score", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "rewardIndex", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "irrevocableLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "isScoreUpdated", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "isUserPrimeHolder", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bool", + "name": "isIrrevocable", + "type": "bool" + }, + { + "internalType": "address[]", + "name": "users", + "type": "address[]" + } + ], + "name": "issue", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "markets", + "outputs": [ + { + "internalType": "uint256", + "name": "supplyMultiplier", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowMultiplier", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "rewardIndex", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sumOfMembersScore", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "exists", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "nextScoreUpdateRoundId", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [ + { + "internalType": "contract ResilientOracleInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingScoreUpdates", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "primeLiquidityProvider", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "revocableLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_irrevocableLimit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_revocableLimit", + "type": "uint256" + } + ], + "name": "setLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "loopsLimit", + "type": "uint256" + } + ], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "users", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "timestamps", + "type": "uint256[]" + } + ], + "name": "setStakedAt", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "stakedAt", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "togglePause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "tokens", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "internalType": "bool", + "name": "isIrrevocable", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalIrrevocable", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalRevocable", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalScoreUpdatesRequired", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "unreleasedPLPIncome", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint128", + "name": "_alphaNumerator", + "type": "uint128" + }, + { + "internalType": "uint128", + "name": "_alphaDenominator", + "type": "uint128" + } + ], + "name": "updateAlpha", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "supplyMultiplier", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowMultiplier", + "type": "uint256" + } + ], + "name": "updateMultipliers", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "users", + "type": "address[]" + } + ], + "name": "updateScores", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "vTokenForAsset", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "xvsUpdated", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVault", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultPoolId", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultRewardToken", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-395/abi/PrimeLiquidityProvider.json b/simulations/vip-395/abi/PrimeLiquidityProvider.json new file mode 100644 index 000000000..02ca8e0bf --- /dev/null +++ b/simulations/vip-395/abi/PrimeLiquidityProvider.json @@ -0,0 +1,385 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "_timeBased", "type": "bool" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, + { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "balance", "type": "uint256" } + ], + "name": "InsufficientBalance", + "type": "error" + }, + { "inputs": [], "name": "InvalidArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidCaller", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "speed", "type": "uint256" }, + { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } + ], + "name": "InvalidDistributionSpeed", + "type": "error" + }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenAlreadyInitialized", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "TokenNotInitialized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "MaxTokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } + ], + "name": "PrimeTokenUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenDistributionInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "TokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokenTransferredToPrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokensAccrued", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "accrueTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "getEffectiveDistributionSpeed", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], + "name": "initializeTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "lastAccruedBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastAccruedBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "maxTokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } + ], + "name": "setMaxTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } + ], + "name": "setTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "tokenAmountAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-395/arbitrumsepolia.ts b/simulations/vip-395/arbitrumsepolia.ts new file mode 100644 index 000000000..bbefc23f9 --- /dev/null +++ b/simulations/vip-395/arbitrumsepolia.ts @@ -0,0 +1,97 @@ +import { mine } from "@nomicfoundation/hardhat-network-helpers"; +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents } from "src/utils"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip015 from "../../multisig/proposals/arbitrumsepolia/vip-015"; +import vip395, { + ARBITRUM_SEPOLIA_COMPTROLLER_CORE, + ARBITRUM_SEPOLIA_COMPTROLLER_LST, + ARBITRUM_SEPOLIA_PLP, + ARBITRUM_SEPOLIA_PRIME, + ARBITRUM_SEPOLIA_USDC, + ARBITRUM_SEPOLIA_USDT, + ARBITRUM_SEPOLIA_VUSDC_CORE, + ARBITRUM_SEPOLIA_VUSDT_CORE, + ARBITRUM_SEPOLIA_VWBTC_CORE, + ARBITRUM_SEPOLIA_VWETH_LST, + ARBITRUM_SEPOLIA_WBTC, + ARBITRUM_SEPOLIA_WETH, +} from "../../vips/vip-395/bsctestnet"; +import COMPTROLLER_ABI from "./abi/ILComptroller.json"; +import PRIME_ABI from "./abi/Prime.json"; +import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; + +const { arbitrumsepolia } = NETWORK_ADDRESSES; + +forking(95399250, async () => { + const provider = ethers.provider; + let prime: Contract; + + before(async () => { + await pretendExecutingVip(await vip015()); + await mine(100); + }); + + describe("Pre-VIP behaviour", () => { + before(async () => { + prime = new ethers.Contract(ARBITRUM_SEPOLIA_PRIME, PRIME_ABI, provider); + }); + + it("Prime should have not contain number of revocable and irrevocable tokens", async () => { + expect(await prime.irrevocableLimit()).to.equal(0); + expect(await prime.revocableLimit()).to.equal(0); + }); + }); + + testForkedNetworkVipCommands("VIP 395", await vip395(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [PRIME_ABI], ["MarketAdded"], [4]); + await expectEvents(txResponse, [PRIME_ABI], ["MintLimitsUpdated"], [1]); + }, + }); + + describe("Post-VIP behavior", () => { + let prime: Contract; + let plp: Contract; + + before(async () => { + prime = new ethers.Contract(ARBITRUM_SEPOLIA_PRIME, PRIME_ABI, provider); + plp = new ethers.Contract(ARBITRUM_SEPOLIA_PLP, PLP_ABI, provider); + }); + + it("prime should have correct pool registry address", async () => { + expect(await prime.poolRegistry()).to.be.equal(arbitrumsepolia.POOL_REGISTRY); + }); + + it("Comptroller lst and core should have correct Prime token address", async () => { + const comptrollerCore = new ethers.Contract(ARBITRUM_SEPOLIA_COMPTROLLER_CORE, COMPTROLLER_ABI, provider); + expect(await comptrollerCore.prime()).to.be.equal(ARBITRUM_SEPOLIA_PRIME); + + const comptrollerLst = new ethers.Contract(ARBITRUM_SEPOLIA_COMPTROLLER_LST, COMPTROLLER_ABI, provider); + expect(await comptrollerLst.prime()).to.be.equal(ARBITRUM_SEPOLIA_PRIME); + }); + + it("Prime should contain correct markets", async () => { + expect((await prime.markets(ARBITRUM_SEPOLIA_VUSDC_CORE))[4]).to.be.equal(true); + expect((await prime.markets(ARBITRUM_SEPOLIA_VUSDT_CORE))[4]).to.be.equal(true); + expect((await prime.markets(ARBITRUM_SEPOLIA_VWBTC_CORE))[4]).to.be.equal(true); + expect((await prime.markets(ARBITRUM_SEPOLIA_VWETH_LST))[4]).to.be.equal(true); + }); + + it("Prime should have correct number of revocable and irrevocable tokens", async () => { + expect(await prime.irrevocableLimit()).to.equal(0); + expect(await prime.revocableLimit()).to.equal(500); + }); + + it("Plp should have correct tokens", async () => { + expect(await plp.lastAccruedBlockOrSecond(ARBITRUM_SEPOLIA_USDT)).to.be.gt(0); + expect(await plp.lastAccruedBlockOrSecond(ARBITRUM_SEPOLIA_USDC)).to.be.gt(0); + expect(await plp.lastAccruedBlockOrSecond(ARBITRUM_SEPOLIA_WETH)).to.be.gt(0); + expect(await plp.lastAccruedBlockOrSecond(ARBITRUM_SEPOLIA_WBTC)).to.be.gt(0); + }); + }); +}); diff --git a/simulations/vip-395/bsctestnet.ts b/simulations/vip-395/bsctestnet.ts new file mode 100644 index 000000000..d412ccd28 --- /dev/null +++ b/simulations/vip-395/bsctestnet.ts @@ -0,0 +1,7 @@ +import { forking, testVip } from "src/vip-framework"; + +import vip395 from "../../vips/vip-395/bsctestnet"; + +forking(45439039, async () => { + testVip("vip395 arbitrum sepolia Prime configuration", await vip395()); +}); diff --git a/vips/vip-395/bsctestnet.ts b/vips/vip-395/bsctestnet.ts new file mode 100644 index 000000000..521d200a9 --- /dev/null +++ b/vips/vip-395/bsctestnet.ts @@ -0,0 +1,107 @@ +import { ethers } from "hardhat"; +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const OMNICHAIN_PROPOSAL_SENDER = "0xCfD34AEB46b1CB4779c945854d405E91D27A1899"; + +export const ARBITRUM_SEPOLIA_COMPTROLLER_CORE = "0x006D44b6f5927b3eD83bD0c1C36Fb1A3BaCaC208"; +export const ARBITRUM_SEPOLIA_COMPTROLLER_LST = "0x3D04F926b2a165BBa17FBfccCCB61513634fa5e4"; +export const ARBITRUM_SEPOLIA_PRIME = "0xAdB04AC4942683bc41E27d18234C8DC884786E89"; +export const ARBITRUM_SEPOLIA_PLP = "0xE82c2c10F55D3268126C29ec813dC6F086904694"; + +export const ARBITRUM_SEPOLIA_USDT = "0xf3118a17863996B9F2A073c9A66Faaa664355cf8"; +export const ARBITRUM_SEPOLIA_USDC = "0x86f096B1D970990091319835faF3Ee011708eAe8"; +export const ARBITRUM_SEPOLIA_WBTC = "0xFb8d93FD3Cf18386a5564bb5619cD1FdB130dF7D"; +export const ARBITRUM_SEPOLIA_WETH = "0x980B62Da83eFf3D4576C647993b0c1D7faf17c73"; +export const ARBITRUM_SEPOLIA_PRIME_NEW_IMPLEMENTATION = "0x507866eCb585275E006D9098867a0e9B08C11CCe"; // contains the setter for the pool registry address +export const ARBITRUM_SEPOLIA_PRIME_OLD_IMPLEMENTATION = "0x255EFC81Ba715FA7C2C27bdd983A3CeF9BB07fEf"; +export const ARBITRUM_SEPOLIA_PROXY_ADMIN = "0xA78A1Df376c3CEeBC5Fab574fe6EdDbbF76fd03e"; + +export const ARBITRUM_SEPOLIA_VUSDT_CORE = "0xdEFbf0F9Ab6CdDd0a1FdDC894b358D0c0a39B052"; +export const ARBITRUM_SEPOLIA_VUSDC_CORE = "0xd9d1e754464eFc7493B177d2c7be04816E089b4C"; +export const ARBITRUM_SEPOLIA_VWBTC_CORE = "0x49FB90A5815904649C44B87001a160C1301D6a2C"; +export const ARBITRUM_SEPOLIA_VWETH_LST = "0xd7057250b439c0849377bB6C3263eb8f9cf49d98"; + +export const MAX_DAILY_LIMIT = 100; + +const vip395 = () => { + const meta = { + version: "v2", + title: "vip395", + description: `#### Description + This VIP will grant permission to timelocks and performs the necessary configuration of OmnichainProposalSender on BNB chain and OmnichainProposalExecutor on SEPOLIA & OPBNBTESTNET chains`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: ARBITRUM_SEPOLIA_PLP, + signature: "setTokensDistributionSpeed(address[],uint256[])", + params: [ + [ARBITRUM_SEPOLIA_WETH, ARBITRUM_SEPOLIA_WBTC, ARBITRUM_SEPOLIA_USDC, ARBITRUM_SEPOLIA_USDT], + [0, 0, 0, 0], + ], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ARBITRUM_SEPOLIA_PRIME, + signature: "addMarket(address,address,uint256,uint256)", + params: [ + ARBITRUM_SEPOLIA_COMPTROLLER_CORE, + ARBITRUM_SEPOLIA_VWBTC_CORE, + ethers.utils.parseEther("2"), + ethers.utils.parseEther("4"), + ], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ARBITRUM_SEPOLIA_PRIME, + signature: "addMarket(address,address,uint256,uint256)", + params: [ + ARBITRUM_SEPOLIA_COMPTROLLER_CORE, + ARBITRUM_SEPOLIA_VUSDC_CORE, + ethers.utils.parseEther("2"), + ethers.utils.parseEther("4"), + ], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ARBITRUM_SEPOLIA_PRIME, + signature: "addMarket(address,address,uint256,uint256)", + params: [ + ARBITRUM_SEPOLIA_COMPTROLLER_CORE, + ARBITRUM_SEPOLIA_VUSDT_CORE, + ethers.utils.parseEther("2"), + ethers.utils.parseEther("4"), + ], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ARBITRUM_SEPOLIA_PRIME, + signature: "addMarket(address,address,uint256,uint256)", + params: [ + ARBITRUM_SEPOLIA_COMPTROLLER_LST, + ARBITRUM_SEPOLIA_VWETH_LST, + ethers.utils.parseEther("2"), + ethers.utils.parseEther("4"), + ], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ARBITRUM_SEPOLIA_PRIME, + signature: "setLimit(uint256,uint256)", + params: [ + 0, // irrevocable + 500, // revocable + ], + dstChainId: LzChainId.arbitrumsepolia, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; + +export default vip395; From da621dbe5a1b6744e90423ed9bdf71c5d50c678f Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Thu, 7 Nov 2024 15:39:16 +0300 Subject: [PATCH 122/178] feat(framework): format protocol seize share in risk checks --- src/vip-framework/checks/checkRiskParameters.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/vip-framework/checks/checkRiskParameters.ts b/src/vip-framework/checks/checkRiskParameters.ts index 2000d6ede..17f8f8c9f 100644 --- a/src/vip-framework/checks/checkRiskParameters.ts +++ b/src/vip-framework/checks/checkRiskParameters.ts @@ -103,7 +103,10 @@ const checkILRiskParameters = ( expect(market.liquidationThresholdMantissa).to.equal(parseIfNeeded(riskParameters.liquidationThreshold, 18)); }); - it(`should set ${spec.symbol} protocol seize share to ${riskParameters.protocolSeizeShare}`, async () => { + it(`should set ${spec.symbol} protocol seize share to ${formatIfNeeded( + riskParameters.protocolSeizeShare, + 18, + )}`, async () => { expect(await vToken.protocolSeizeShareMantissa()).to.equal(parseIfNeeded(riskParameters.protocolSeizeShare, 18)); }); }; From 6ab5c625b1077a5dc6405d0cda999b6d66189792 Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Thu, 7 Nov 2024 15:40:14 +0300 Subject: [PATCH 123/178] feat: add mainnet VIP for pufETH --- multisig/proposals/ethereum/vip-100/index.ts | 21 + .../vip-400/abi/OmnichainProposalSender.json | 314 ++++ simulations/vip-400/abi/PoolRegistry.json | 310 ++++ simulations/vip-400/abi/ResilientOracle.json | 301 ++++ .../vip-400/abi/SingleTokenConverter.json | 1267 ++++++++++++++ simulations/vip-400/abi/comptroller.json | 1496 +++++++++++++++++ simulations/vip-400/abi/vToken.json | 861 ++++++++++ simulations/vip-400/abi/weth.json | 125 ++ simulations/vip-400/bscmainnet.ts | 17 + simulations/vip-400/ethereum.ts | 130 ++ vips/vip-400/bscmainnet.ts | 173 ++ 11 files changed, 5015 insertions(+) create mode 100644 multisig/proposals/ethereum/vip-100/index.ts create mode 100644 simulations/vip-400/abi/OmnichainProposalSender.json create mode 100644 simulations/vip-400/abi/PoolRegistry.json create mode 100644 simulations/vip-400/abi/ResilientOracle.json create mode 100644 simulations/vip-400/abi/SingleTokenConverter.json create mode 100644 simulations/vip-400/abi/comptroller.json create mode 100644 simulations/vip-400/abi/vToken.json create mode 100644 simulations/vip-400/abi/weth.json create mode 100644 simulations/vip-400/bscmainnet.ts create mode 100644 simulations/vip-400/ethereum.ts create mode 100644 vips/vip-400/bscmainnet.ts diff --git a/multisig/proposals/ethereum/vip-100/index.ts b/multisig/proposals/ethereum/vip-100/index.ts new file mode 100644 index 000000000..9e61fedc3 --- /dev/null +++ b/multisig/proposals/ethereum/vip-100/index.ts @@ -0,0 +1,21 @@ +import { parseUnits } from "ethers/lib/utils"; + +import { NETWORK_ADDRESSES } from "../../../../src/networkAddresses"; +import { makeProposal } from "../../../../src/utils"; + +const { VTREASURY, NORMAL_TIMELOCK } = NETWORK_ADDRESSES.ethereum; + +const PUFETH = "0xD9A442856C234a39a81a089C06451EBAa4306a72"; +const INITIAL_SUPPLY = parseUnits("5", 18); + +export const vip100 = () => { + return makeProposal([ + { + target: VTREASURY, + signature: "withdrawTreasuryToken(address,uint256,address)", + params: [PUFETH, INITIAL_SUPPLY, NORMAL_TIMELOCK], + }, + ]); +}; + +export default vip100; diff --git a/simulations/vip-400/abi/OmnichainProposalSender.json b/simulations/vip-400/abi/OmnichainProposalSender.json new file mode 100644 index 000000000..66fd4df02 --- /dev/null +++ b/simulations/vip-400/abi/OmnichainProposalSender.json @@ -0,0 +1,314 @@ +[ + { + "inputs": [ + { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } + ], + "name": "ClearPayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } + ], + "name": "ExecuteRemoteProposal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "FallbackWithdraw", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } + ], + "name": "StorePayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], + "name": "TrustedRemoteRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "LZ_ENDPOINT", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourCommandsSent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLastProposalSentTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bool", "name": "useZro_", "type": "bool" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } + ], + "name": "estimateFees", + "outputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } + ], + "name": "execute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "fallbackWithdraw", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "proposalCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], + "name": "removeTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "retryExecute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" }, + { "internalType": "bytes", "name": "config_", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "storedExecutionHashes", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } +] diff --git a/simulations/vip-400/abi/PoolRegistry.json b/simulations/vip-400/abi/PoolRegistry.json new file mode 100644 index 000000000..8f15277d2 --- /dev/null +++ b/simulations/vip-400/abi/PoolRegistry.json @@ -0,0 +1,310 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "vTokenAddress", "type": "address" } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "oldMetadata", + "type": "tuple" + }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "newMetadata", + "type": "tuple" + } + ], + "name": "PoolMetadataUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "oldName", "type": "string" }, + { "indexed": false, "internalType": "string", "name": "newName", "type": "string" } + ], + "name": "PoolNameSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "indexed": false, + "internalType": "struct PoolRegistryInterface.VenusPool", + "name": "pool", + "type": "tuple" + } + ], + "name": "PoolRegistered", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "collateralFactor", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThreshold", "type": "uint256" }, + { "internalType": "uint256", "name": "initialSupply", "type": "uint256" }, + { "internalType": "address", "name": "vTokenReceiver", "type": "address" }, + { "internalType": "uint256", "name": "supplyCap", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowCap", "type": "uint256" } + ], + "internalType": "struct PoolRegistry.AddMarketInput", + "name": "input", + "type": "tuple" + } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "contract Comptroller", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "closeFactor", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationIncentive", "type": "uint256" }, + { "internalType": "uint256", "name": "minLiquidatableCollateral", "type": "uint256" } + ], + "name": "addPool", + "outputs": [{ "internalType": "uint256", "name": "index", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getAllPools", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool[]", + "name": "", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "comptroller", "type": "address" }], + "name": "getPoolByComptroller", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "name", "type": "string" }, + { "internalType": "address", "name": "creator", "type": "address" }, + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "uint256", "name": "blockPosted", "type": "uint256" }, + { "internalType": "uint256", "name": "timestampPosted", "type": "uint256" } + ], + "internalType": "struct PoolRegistryInterface.VenusPool", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPoolsSupportedByAsset", + "outputs": [{ "internalType": "address[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "address", "name": "asset", "type": "address" } + ], + "name": "getVTokenForAsset", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "comptroller", "type": "address" }], + "name": "getVenusPoolMetadata", + "outputs": [ + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "metadata", + "outputs": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { "internalType": "string", "name": "name", "type": "string" } + ], + "name": "setPoolName", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "comptroller", "type": "address" }, + { + "components": [ + { "internalType": "string", "name": "category", "type": "string" }, + { "internalType": "string", "name": "logoURL", "type": "string" }, + { "internalType": "string", "name": "description", "type": "string" } + ], + "internalType": "struct PoolRegistryInterface.VenusPoolMetaData", + "name": "metadata_", + "type": "tuple" + } + ], + "name": "updatePoolMetadata", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-400/abi/ResilientOracle.json b/simulations/vip-400/abi/ResilientOracle.json new file mode 100644 index 000000000..e2f944a9d --- /dev/null +++ b/simulations/vip-400/abi/ResilientOracle.json @@ -0,0 +1,301 @@ +[ + { + "inputs": [ + { "internalType": "address", "name": "nativeMarketAddress", "type": "address" }, + { "internalType": "address", "name": "vaiAddress", "type": "address" }, + { "internalType": "contract BoundValidatorInterface", "name": "_boundValidator", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "role", "type": "uint256" }, + { "indexed": true, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "oracle", "type": "address" }, + { "indexed": true, "internalType": "uint256", "name": "role", "type": "uint256" } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "asset", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "mainOracle", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "pivotOracle", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "fallbackOracle", "type": "address" } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [{ "internalType": "contract BoundValidatorInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" } + ], + "name": "getOracle", + "outputs": [ + { "internalType": "address", "name": "oracle", "type": "address" }, + { "internalType": "bool", "name": "enabled", "type": "bool" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getUnderlyingPrice", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address", "name": "oracle", "type": "address" }, + { "internalType": "enum ResilientOracle.OracleRole", "name": "role", "type": "uint8" } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { "internalType": "address", "name": "asset", "type": "address" }, + { "internalType": "address[3]", "name": "oracles", "type": "address[3]" }, + { "internalType": "bool[3]", "name": "enableFlagsForOracles", "type": "bool[3]" } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "asset", "type": "address" }], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-400/abi/SingleTokenConverter.json b/simulations/vip-400/abi/SingleTokenConverter.json new file mode 100644 index 000000000..1c8e0f8ec --- /dev/null +++ b/simulations/vip-400/abi/SingleTokenConverter.json @@ -0,0 +1,1267 @@ +[ + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { + "inputs": [], + "name": "AmountInMismatched", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { + "inputs": [], + "name": "AmountOutMismatched", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionConfigNotEnabled", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionEnabledOnlyForPrivateConversions", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionTokensActive", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionTokensPaused", + "type": "error" + }, + { + "inputs": [], + "name": "DeflationaryTokenNotSupported", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxIncentive", + "type": "uint256" + } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { + "inputs": [], + "name": "InputLengthMisMatch", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientInputAmount", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientOutputAmount", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientPoolLiquidity", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidConverterNetwork", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidMinimumAmountToConvert", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidToAddress", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidTokenConfigAddresses", + "type": "error" + }, + { + "inputs": [], + "name": "NonZeroIncentiveForPrivateConversion", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroValueNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldIncentive", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newIncentive", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + } + ], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + } + ], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldConverterNetwork", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "converterNetwork", + "type": "address" + } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldDestinationAddress", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "destinationAddress", + "type": "address" + } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMinAmountToConvert", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMinAmountToConvert", + "type": "uint256" + } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract ResilientOracle", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract ResilientOracle", + "name": "priceOracle", + "type": "address" + } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "token", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "token", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "tokenBalance", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "conversionConfigurations", + "outputs": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertExactTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertForExactTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [ + { + "internalType": "contract IConverterNetwork", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getAmountIn", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getAmountOut", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pauseConversion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [ + { + "internalType": "contract ResilientOracle", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "resumeConversion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address[]", + "name": "tokenAddressesOut", + "type": "address[]" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract IConverterNetwork", + "name": "converterNetwork_", + "type": "address" + } + ], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "destinationAddress_", + "type": "address" + } + ], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "minAmountToConvert_", + "type": "uint256" + } + ], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract ResilientOracle", + "name": "priceOracle_", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-400/abi/comptroller.json b/simulations/vip-400/abi/comptroller.json new file mode 100644 index 000000000..fafe7b35e --- /dev/null +++ b/simulations/vip-400/abi/comptroller.json @@ -0,0 +1,1496 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "poolRegistry_", + "type": "address" + }, + { + "internalType": "address", + "name": "accessControl_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedLessThanOrEqualTo", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { + "inputs": [], + "name": "ComptrollerMismatch", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "collateralToSeize", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "availableCollateral", + "type": "uint256" + } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientLiquidity", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientShortfall", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidCollateralFactor", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidLiquidationThreshold", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expectedGreaterThan", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actual", + "type": "uint256" + } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { + "inputs": [], + "name": "NonzeroBorrowBalance", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "cap", + "type": "uint256" + } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { + "inputs": [], + "name": "TooMuchRepay", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "expectedSender", + "type": "address" + }, + { + "internalType": "address", + "name": "actualSender", + "type": "address" + } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "bool", + "name": "pauseState", + "type": "bool" + } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newBorrowCap", + "type": "uint256" + } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldCloseFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldCollateralFactorMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationIncentiveMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldLiquidationThresholdMantissa", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMinLiquidatableCollateral", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract PriceOracle", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "rewardsDistributor", + "type": "address" + } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSupplyCap", + "type": "uint256" + } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControl", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "accountAssets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "enum ComptrollerStorage.Action", + "name": "action", + "type": "uint8" + } + ], + "name": "actionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract RewardsDistributor", + "name": "_rewardsDistributor", + "type": "address" + } + ], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "allMarkets", + "outputs": [ + { + "internalType": "contract VToken", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "borrowCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "checkMembership", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "vTokens", + "type": "address[]" + } + ], + "name": "enterMarkets", + "outputs": [ + { + "internalType": "uint256[]", + "name": "", + "type": "uint256[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenAddress", + "type": "address" + } + ], + "name": "exitMarket", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getAssetsIn", + "outputs": [ + { + "internalType": "contract VToken[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenModify", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidity", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "shortfall", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [ + { + "internalType": "contract RewardsDistributor[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "rewardToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "supplySpeed", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowSpeed", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isDeprecated", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "isMarketListed", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "components": [ + { + "internalType": "contract VToken", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "contract VToken", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "uint256", + "name": "actualRepayAmount", + "type": "uint256" + } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "error", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokensToSeize", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "markets", + "outputs": [ + { + "internalType": "bool", + "name": "isListed", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "collateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "liquidationThresholdMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [ + { + "internalType": "contract PriceOracle", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrowAmount", + "type": "uint256" + } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenBorrowed", + "type": "address" + }, + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + }, + { + "internalType": "uint256", + "name": "repayAmount", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "skipLiquidityCheck", + "type": "bool" + } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "minter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "mintAmount", + "type": "uint256" + } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "redeemer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "redeemTokens", + "type": "uint256" + } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vTokenCollateral", + "type": "address" + }, + { + "internalType": "address", + "name": "seizerContract", + "type": "address" + }, + { + "internalType": "address", + "name": "liquidator", + "type": "address" + }, + { + "internalType": "address", + "name": "borrower", + "type": "address" + } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "transferTokens", + "type": "uint256" + } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "marketsList", + "type": "address[]" + }, + { + "internalType": "enum ComptrollerStorage.Action[]", + "name": "actionsList", + "type": "uint8[]" + }, + { + "internalType": "bool", + "name": "paused", + "type": "bool" + } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newCloseFactorMantissa", + "type": "uint256" + } + ], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "newCollateralFactorMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "newLiquidationThresholdMantissa", + "type": "uint256" + } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newLiquidationIncentiveMantissa", + "type": "uint256" + } + ], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newBorrowCaps", + "type": "uint256[]" + } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken[]", + "name": "vTokens", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "newSupplyCaps", + "type": "uint256[]" + } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newMinLiquidatableCollateral", + "type": "uint256" + } + ], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract PriceOracle", + "name": "newOracle", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "supplyCaps", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract VToken", + "name": "vToken", + "type": "address" + } + ], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-400/abi/vToken.json b/simulations/vip-400/abi/vToken.json new file mode 100644 index 000000000..d8cc1aae4 --- /dev/null +++ b/simulations/vip-400/abi/vToken.json @@ -0,0 +1,861 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "inputs": [{ "internalType": "uint256", "name": "actualAddAmount", "type": "uint256" }], + "name": "AddReservesFactorFreshCheck", + "type": "error" + }, + { "inputs": [], "name": "BorrowCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "BorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "DelegateNotApproved", "type": "error" }, + { "inputs": [], "name": "ForceLiquidateBorrowUnauthorized", "type": "error" }, + { "inputs": [], "name": "HealBorrowUnauthorized", "type": "error" }, + { + "inputs": [{ "internalType": "uint256", "name": "errorCode", "type": "uint256" }], + "name": "LiquidateAccrueCollateralInterestFailed", + "type": "error" + }, + { "inputs": [], "name": "LiquidateCloseAmountIsUintMax", "type": "error" }, + { "inputs": [], "name": "LiquidateCloseAmountIsZero", "type": "error" }, + { "inputs": [], "name": "LiquidateCollateralFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "LiquidateLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "LiquidateSeizeLiquidatorIsBorrower", "type": "error" }, + { "inputs": [], "name": "MintFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "ProtocolSeizeShareTooBig", "type": "error" }, + { "inputs": [], "name": "RedeemFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "RedeemTransferOutNotPossible", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashNotAvailable", "type": "error" }, + { "inputs": [], "name": "ReduceReservesCashValidation", "type": "error" }, + { "inputs": [], "name": "ReduceReservesFreshCheck", "type": "error" }, + { "inputs": [], "name": "RepayBorrowFreshnessCheck", "type": "error" }, + { "inputs": [], "name": "SetInterestRateModelFreshCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorBoundsCheck", "type": "error" }, + { "inputs": [], "name": "SetReserveFactorFreshCheck", "type": "error" }, + { "inputs": [], "name": "TransferNotAllowed", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "cashPrior", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "interestAccumulated", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "borrowIndex", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "AccrueInterest", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "badDebtOld", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "badDebtNew", "type": "uint256" } + ], + "name": "BadDebtRecovered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "HealBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "liquidator", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": true, "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "LiquidateBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "mintAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "mintTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "oldComptroller", "type": "address" }, + { "indexed": true, "internalType": "contract ComptrollerInterface", "name": "newComptroller", "type": "address" } + ], + "name": "NewComptroller", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "oldInterestRateModel", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract InterestRateModel", + "name": "newInterestRateModel", + "type": "address" + } + ], + "name": "NewMarketInterestRateModel", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldProtocolSeizeShareMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newProtocolSeizeShareMantissa", "type": "uint256" } + ], + "name": "NewProtocolSeizeShare", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldProtocolShareReserve", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newProtocolShareReserve", "type": "address" } + ], + "name": "NewProtocolShareReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReduceReservesBlockDelta", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReduceReservesBlockDelta", "type": "uint256" } + ], + "name": "NewReduceReservesBlockDelta", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldReserveFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" } + ], + "name": "NewReserveFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldShortfall", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newShortfall", "type": "address" } + ], + "name": "NewShortfallContract", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "ProtocolSeize", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "redeemer", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBalance", "type": "uint256" } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "borrower", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "accountBorrows", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "totalBorrows", "type": "uint256" } + ], + "name": "RepayBorrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "benefactor", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "addAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "ReservesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "protocolShareReserve", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newTotalReserves", "type": "uint256" } + ], + "name": "SpreadReservesReduced", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "NO_ERROR", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrualBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accrueInterest", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "addAmount", "type": "uint256" }], + "name": "addReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "badDebt", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "recoveredAmount_", "type": "uint256" }], + "name": "badDebtRecovered", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], + "name": "balanceOfUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "borrowAmount", "type": "uint256" }], + "name": "borrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "borrowBalanceStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "borrowIndex", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "borrowRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [{ "internalType": "contract ComptrollerInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "exchangeRateStored", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "forceLiquidateBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountSnapshot", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "vTokenBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowBalance", "type": "uint256" }, + { "internalType": "uint256", "name": "exchangeRate", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getCash", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "healBorrow", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "underlying_", "type": "address" }, + { "internalType": "contract ComptrollerInterface", "name": "comptroller_", "type": "address" }, + { "internalType": "contract InterestRateModel", "name": "interestRateModel_", "type": "address" }, + { "internalType": "uint256", "name": "initialExchangeRateMantissa_", "type": "uint256" }, + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" }, + { "internalType": "uint8", "name": "decimals_", "type": "uint8" }, + { "internalType": "address", "name": "admin_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { + "components": [ + { "internalType": "address", "name": "shortfall", "type": "address" }, + { "internalType": "address payable", "name": "protocolShareReserve", "type": "address" } + ], + "internalType": "struct VTokenInterface.RiskManagementInit", + "name": "riskManagement", + "type": "tuple" + }, + { "internalType": "uint256", "name": "reserveFactorMantissa_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "interestRateModel", + "outputs": [{ "internalType": "contract InterestRateModel", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isVToken", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "contract VTokenInterface", "name": "vTokenCollateral", "type": "address" } + ], + "name": "liquidateBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "mintAmount", "type": "uint256" }], + "name": "mint", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "mintBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolSeizeShareMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "protocolShareReserve", + "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }], + "name": "redeem", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }], + "name": "redeemUnderlying", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" } + ], + "name": "redeemUnderlyingBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "reduceAmount", "type": "uint256" }], + "name": "reduceReserves", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockDelta", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "reduceReservesBlockNumber", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "uint256", "name": "repayAmount", "type": "uint256" }], + "name": "repayBorrow", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "name": "repayBorrowBehalf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "reserveFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract InterestRateModel", "name": "newInterestRateModel", "type": "address" }], + "name": "setInterestRateModel", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newProtocolSeizeShareMantissa_", "type": "uint256" }], + "name": "setProtocolSeizeShare", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address payable", "name": "protocolShareReserve_", "type": "address" }], + "name": "setProtocolShareReserve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "_newReduceReservesBlockDelta", "type": "uint256" }], + "name": "setReduceReservesBlockDelta", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newReserveFactorMantissa", "type": "uint256" }], + "name": "setReserveFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "shortfall_", "type": "address" }], + "name": "setShortfallContract", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "shortfall", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "supplyRatePerBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IERC20Upgradeable", "name": "token", "type": "address" }], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrows", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalBorrowsCurrent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "totalReserves", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "underlying", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-400/abi/weth.json b/simulations/vip-400/abi/weth.json new file mode 100644 index 000000000..cf8da14a9 --- /dev/null +++ b/simulations/vip-400/abi/weth.json @@ -0,0 +1,125 @@ +[ + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "src", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "guy", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "wad", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "dst", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "wad", "type": "uint256" } + ], + "name": "Deposit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "src", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "dst", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "wad", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "src", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "wad", "type": "uint256" } + ], + "name": "Withdrawal", + "type": "event" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "guy", "type": "address" }, + { "internalType": "uint256", "name": "wad", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "deposit", "outputs": [], "stateMutability": "payable", "type": "function" }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "wad", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "wad", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "wad", "type": "uint256" }], + "name": "withdraw", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "stateMutability": "payable", "type": "receive" } +] diff --git a/simulations/vip-400/bscmainnet.ts b/simulations/vip-400/bscmainnet.ts new file mode 100644 index 000000000..de744bcf9 --- /dev/null +++ b/simulations/vip-400/bscmainnet.ts @@ -0,0 +1,17 @@ +import { expectEvents } from "../../src/utils"; +import { forking, testVip } from "../../src/vip-framework"; +import vip400 from "../../vips/vip-400/bscmainnet"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +forking(43771100, async () => { + testVip("vip400", await vip400(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [1, 0], + ); + }, + }); +}); diff --git a/simulations/vip-400/ethereum.ts b/simulations/vip-400/ethereum.ts new file mode 100644 index 000000000..ef52d8bcc --- /dev/null +++ b/simulations/vip-400/ethereum.ts @@ -0,0 +1,130 @@ +import { expect } from "chai"; +import { BigNumber } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { setMaxStalePeriodInChainlinkOracle, setRedstonePrice } from "src/utils"; +import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIsolatedPoolsComptrollers"; +import { checkRiskParameters } from "src/vip-framework/checks/checkRiskParameters"; +import { checkVToken } from "src/vip-framework/checks/checkVToken"; +import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework/index"; + +import vip100 from "../../multisig/proposals/ethereum/vip-100"; +import vip400, { + CONVERSION_INCENTIVE, + PUFETH_REDSTONE_FEED, + converterBaseAssets, + marketSpec, +} from "../../vips/vip-400/bscmainnet"; +import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; +import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; +import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; +import COMPTROLLER_ABI from "./abi/comptroller.json"; +import VTOKEN_ABI from "./abi/vToken.json"; + +const { ethereum } = NETWORK_ADDRESSES; +const PROTOCOL_SHARE_RESERVE = "0x8c8c8530464f7D95552A11eC31Adbd4dC4AC4d3E"; +const BLOCKS_PER_YEAR = BigNumber.from(2628000); +const WETH = "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2"; +const WETH_CHAINLINK_FEED = "0x5f4eC3Df9cbd43714FE2740f5E3616155c5b8419"; +const PUFETH_HOLDER = "0xDdA0483184E75a5579ef9635ED14BacCf9d50283"; + +const { POOL_REGISTRY, RESILIENT_ORACLE, REDSTONE_ORACLE, GUARDIAN, VTREASURY, CHAINLINK_ORACLE } = ethereum; + +forking(21130180, async () => { + const resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, ethers.provider); + const poolRegistry = new ethers.Contract(POOL_REGISTRY, POOL_REGISTRY_ABI, ethers.provider); + const vToken = new ethers.Contract(marketSpec.vToken.address, VTOKEN_ABI, ethers.provider); + const comptroller = new ethers.Contract(marketSpec.vToken.comptroller, COMPTROLLER_ABI, ethers.provider); + + before(async () => { + const FTT = "0x8764F50616B62a99A997876C2DEAaa04554C5B2E"; + await setRedstonePrice(REDSTONE_ORACLE, marketSpec.vToken.underlying.address, PUFETH_REDSTONE_FEED, FTT); + await setMaxStalePeriodInChainlinkOracle(CHAINLINK_ORACLE, WETH, WETH_CHAINLINK_FEED, GUARDIAN); + + await pretendExecutingVip(await vip100()); + }); + + describe("Pre-VIP behavior", () => { + it("check price", async () => { + await expect(resilientOracle.getPrice(marketSpec.vToken.underlying.address)).to.be.reverted; + }); + + it("should have 8 markets in liquid staked pool", async () => { + const poolVTokens = await comptroller.getAllMarkets(); + expect(poolVTokens).to.have.lengthOf(8); + }); + }); + + testForkedNetworkVipCommands("vip400", await vip400()); + + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip400()); + }); + + it("check price", async () => { + expect(await resilientOracle.getPrice(marketSpec.vToken.underlying.address)).to.be.closeTo( + parseUnits("2716.519108022670820400", 18), + parseUnits("1", 18), + ); + expect(await resilientOracle.getUnderlyingPrice(marketSpec.vToken.address)).to.be.closeTo( + parseUnits("2716.519108022670820400", 18), + parseUnits("1", 18), + ); + }); + + it("should have 9 markets in liquid staked pool", async () => { + const poolVTokens = await comptroller.getAllMarkets(); + expect(poolVTokens).to.have.lengthOf(9); + }); + + it(`should add ${marketSpec.vToken.symbol} to the pool`, async () => { + const registeredVToken = await poolRegistry.getVTokenForAsset( + comptroller.address, + marketSpec.vToken.underlying.address, + ); + expect(registeredVToken).to.equal(marketSpec.vToken.address); + }); + + it("check ownership", async () => { + expect(await vToken.owner()).to.equal(GUARDIAN); + }); + + it("check supply", async () => { + const expectedSupply = parseUnits("5", 8); + expect(await vToken.balanceOf(VTREASURY)).to.equal(expectedSupply); + }); + + it("has correct protocol share reserve", async () => { + expect(await vToken.protocolShareReserve()).equals(PROTOCOL_SHARE_RESERVE); + }); + + checkRiskParameters(marketSpec.vToken.address, marketSpec.vToken, marketSpec.riskParameters); + checkVToken(marketSpec.vToken.address, marketSpec.vToken); + checkInterestRate( + marketSpec.interestRateModel.address, + marketSpec.vToken.symbol, + marketSpec.interestRateModel, + BLOCKS_PER_YEAR, + ); + + it("check Pool", async () => { + checkIsolatedPoolsComptrollers({ + [marketSpec.vToken.comptroller]: PUFETH_HOLDER, + }); + }); + + describe("Converters", () => { + for (const [converterAddress, baseAsset] of Object.entries(converterBaseAssets)) { + const converterContract = new ethers.Contract(converterAddress, SINGLE_TOKEN_CONVERTER_ABI, ethers.provider); + const asset = marketSpec.vToken.underlying.address; + it(`should set ${CONVERSION_INCENTIVE} as incentive in converter ${converterAddress}, for asset ${asset}`, async () => { + const result = await converterContract.conversionConfigurations(baseAsset, asset); + expect(result.incentive).to.equal(CONVERSION_INCENTIVE); + }); + } + }); + }); +}); diff --git a/vips/vip-400/bscmainnet.ts b/vips/vip-400/bscmainnet.ts new file mode 100644 index 000000000..88ea9927a --- /dev/null +++ b/vips/vip-400/bscmainnet.ts @@ -0,0 +1,173 @@ +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +const { ethereum } = NETWORK_ADDRESSES; + +const PUFETH = "0xD9A442856C234a39a81a089C06451EBAa4306a72"; +const PUFETH_VTOKEN = "0xE0ee5dDeBFe0abe0a4Af50299D68b74Cec31668e"; +const LST_ETH_COMPTROLLER = "0xF522cd0360EF8c2FF48B648d53EA1717Ec0F3Ac3"; +const REDUCE_RESERVES_BLOCK_DELTA = "7200"; + +const { POOL_REGISTRY, VTREASURY, REDSTONE_ORACLE, RESILIENT_ORACLE } = ethereum; + +export const marketSpec = { + vToken: { + address: PUFETH_VTOKEN, + name: "Venus pufETH (Liquid Staked ETH)", + symbol: "vpufETH_LiquidStakedETH", + underlying: { + address: PUFETH, + decimals: 18, + symbol: "pufETH", + }, + decimals: 8, + exchangeRate: parseUnits("1", 28), + comptroller: LST_ETH_COMPTROLLER, + }, + interestRateModel: { + address: "0xDaFA3B350288cEb448e0E03077D932f8EF561391", + base: "0", + multiplier: "0.045", + jump: "2", + kink: "0.45", + }, + initialSupply: { + amount: parseUnits("5", 18), + vTokenReceiver: VTREASURY, + }, + riskParameters: { + supplyCap: parseUnits("3000", 18), + borrowCap: parseUnits("300", 18), + collateralFactor: parseUnits("0.8", 18), + liquidationThreshold: parseUnits("0.85", 18), + reserveFactor: parseUnits("0.2", 18), + protocolSeizeShare: parseUnits("0.01", 18), + }, +}; + +const PUFETH_ONE_JUMP_REDSTONE_ORACLE = "0xAaE18CEBDF55bbbbf5C70c334Ee81D918be728Bc"; +export const PUFETH_REDSTONE_FEED = "0x76A495b0bFfb53ef3F0E94ef0763e03cE410835C"; +const MAX_STALE_PERIOD = 26 * 3600; // heartbeat of 24 hours + 2 hours margin + +export const CONVERSION_INCENTIVE = 1e14; + +export const USDT_PRIME_CONVERTER = "0x4f55cb0a24D5542a3478B0E284259A6B850B06BD"; +export const USDC_PRIME_CONVERTER = "0xcEB9503f10B781E30213c0b320bCf3b3cE54216E"; +export const WBTC_PRIME_CONVERTER = "0xDcCDE673Cd8988745dA384A7083B0bd22085dEA0"; +export const WETH_PRIME_CONVERTER = "0xb8fD67f215117FADeF06447Af31590309750529D"; +export const XVS_VAULT_CONVERTER = "0x1FD30e761C3296fE36D9067b1e398FD97B4C0407"; +const USDT = "0xdAC17F958D2ee523a2206206994597C13D831ec7"; +const USDC = "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"; +const WBTC = "0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599"; +const WETH = "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2"; +const XVS = "0xd3CC9d8f3689B83c91b7B59cAB4946B063EB894A"; +export const converterBaseAssets = { + [USDT_PRIME_CONVERTER]: USDT, + [USDC_PRIME_CONVERTER]: USDC, + [WBTC_PRIME_CONVERTER]: WBTC, + [WETH_PRIME_CONVERTER]: WETH, + [XVS_VAULT_CONVERTER]: XVS, +}; + +enum ConversionAccessibility { + NONE = 0, + ALL = 1, + ONLY_FOR_CONVERTERS = 2, + ONLY_FOR_USERS = 3, +} + +export const vip400 = () => { + const meta = { + version: "v2", + title: "VIP-400", + description: `### Description`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + + return makeProposal( + [ + // Configure Oracle + { + target: REDSTONE_ORACLE, + signature: "setTokenConfig((address,address,uint256))", + params: [[marketSpec.vToken.underlying.address, PUFETH_REDSTONE_FEED, MAX_STALE_PERIOD]], + dstChainId: LzChainId.ethereum, + }, + { + target: RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [ + marketSpec.vToken.underlying.address, + [PUFETH_ONE_JUMP_REDSTONE_ORACLE, ethers.constants.AddressZero, ethers.constants.AddressZero], + [true, false, false], + ], + ], + dstChainId: LzChainId.ethereum, + }, + + // Add Market + { + target: marketSpec.vToken.underlying.address, + signature: "approve(address,uint256)", + params: [POOL_REGISTRY, marketSpec.initialSupply.amount], + dstChainId: LzChainId.ethereum, + }, + { + target: marketSpec.vToken.address, + signature: "setReduceReservesBlockDelta(uint256)", + params: [REDUCE_RESERVES_BLOCK_DELTA], + dstChainId: LzChainId.ethereum, + }, + { + target: POOL_REGISTRY, + signature: "addMarket((address,uint256,uint256,uint256,address,uint256,uint256))", + params: [ + [ + marketSpec.vToken.address, + marketSpec.riskParameters.collateralFactor, + marketSpec.riskParameters.liquidationThreshold, + marketSpec.initialSupply.amount, + marketSpec.initialSupply.vTokenReceiver, + marketSpec.riskParameters.supplyCap, + marketSpec.riskParameters.borrowCap, + ], + ], + dstChainId: LzChainId.ethereum, + }, + { + target: marketSpec.vToken.underlying.address, + signature: "approve(address,uint256)", + params: [POOL_REGISTRY, 0], + dstChainId: LzChainId.ethereum, + }, + { + target: marketSpec.vToken.address, + signature: "setProtocolSeizeShare(uint256)", + params: [marketSpec.riskParameters.protocolSeizeShare], + dstChainId: LzChainId.ethereum, + }, + + // Configure converters + ...Object.entries(converterBaseAssets).map(([converter, baseAsset]: [string, string]) => ({ + target: converter, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [ + baseAsset, + [marketSpec.vToken.underlying.address], + [[CONVERSION_INCENTIVE, ConversionAccessibility.ALL]], + ], + dstChainId: LzChainId.ethereum, + })), + ], + meta, + ProposalType.REGULAR, + ); +}; + +export default vip400; From 4c8ee2a3c66e517e8f6bf63157c6cddac3f75930 Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Fri, 8 Nov 2024 10:39:02 +0300 Subject: [PATCH 124/178] fixup! feat: add mainnet VIP for pufETH --- vips/vip-400/bscmainnet.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vips/vip-400/bscmainnet.ts b/vips/vip-400/bscmainnet.ts index 88ea9927a..42783fc04 100644 --- a/vips/vip-400/bscmainnet.ts +++ b/vips/vip-400/bscmainnet.ts @@ -11,7 +11,7 @@ const PUFETH_VTOKEN = "0xE0ee5dDeBFe0abe0a4Af50299D68b74Cec31668e"; const LST_ETH_COMPTROLLER = "0xF522cd0360EF8c2FF48B648d53EA1717Ec0F3Ac3"; const REDUCE_RESERVES_BLOCK_DELTA = "7200"; -const { POOL_REGISTRY, VTREASURY, REDSTONE_ORACLE, RESILIENT_ORACLE } = ethereum; +const { POOL_REGISTRY, REDSTONE_ORACLE, RESILIENT_ORACLE } = ethereum; export const marketSpec = { vToken: { @@ -36,7 +36,7 @@ export const marketSpec = { }, initialSupply: { amount: parseUnits("5", 18), - vTokenReceiver: VTREASURY, + vTokenReceiver: "0x495aeBf595D4C641af21A2a021C983C6565CA1A2", }, riskParameters: { supplyCap: parseUnits("3000", 18), From dbb456d280f242ab433dca6fb4f413c9d715d2b6 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Fri, 8 Nov 2024 13:14:29 +0530 Subject: [PATCH 125/178] feat: configure multichain governance on opmainnet --- multisig/proposals/opmainnet/vip-006/index.ts | 16 ++ .../vip-006/abi/AccessControlManagerAbi.json | 157 ++++++++++++++++++ .../simulations/opmainnet/vip-006/index.ts | 31 ++++ simulations/vip-395/bscmainnet.ts | 15 +- simulations/vip-395/opmainnet.ts | 151 +++++++++++++++++ src/networkAddresses.ts | 5 +- vips/vip-395/bscmainnet.ts | 52 +++++- 7 files changed, 420 insertions(+), 7 deletions(-) create mode 100644 multisig/proposals/opmainnet/vip-006/index.ts create mode 100644 multisig/simulations/opmainnet/vip-006/abi/AccessControlManagerAbi.json create mode 100644 multisig/simulations/opmainnet/vip-006/index.ts create mode 100644 simulations/vip-395/opmainnet.ts diff --git a/multisig/proposals/opmainnet/vip-006/index.ts b/multisig/proposals/opmainnet/vip-006/index.ts new file mode 100644 index 000000000..960f8d34b --- /dev/null +++ b/multisig/proposals/opmainnet/vip-006/index.ts @@ -0,0 +1,16 @@ +import { makeProposal } from "src/utils"; + +export const OPMAINNET_ACM = "0xD71b1F33f6B0259683f11174EE4Ddc2bb9cE4eD6"; +export const OPMAINNET_NORMAL_TIMELOCK = "0x0C6f1E6B4fDa846f63A0d5a8a73EB811E0e0C04b"; +const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + +export const vip006 = () => { + return makeProposal([ + { + target: OPMAINNET_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OPMAINNET_NORMAL_TIMELOCK], + }, + ]); +}; +export default vip006; diff --git a/multisig/simulations/opmainnet/vip-006/abi/AccessControlManagerAbi.json b/multisig/simulations/opmainnet/vip-006/abi/AccessControlManagerAbi.json new file mode 100644 index 000000000..2ef119947 --- /dev/null +++ b/multisig/simulations/opmainnet/vip-006/abi/AccessControlManagerAbi.json @@ -0,0 +1,157 @@ +[ + { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, + { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "PermissionRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } + ], + "name": "RoleAdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleRevoked", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_ADMIN_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleAdmin", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToPermit", "type": "address" } + ], + "name": "giveCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "grantRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "hasPermission", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "hasRole", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" } + ], + "name": "isAllowedToCall", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "renounceRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "contractAddress", "type": "address" }, + { "internalType": "string", "name": "functionSig", "type": "string" }, + { "internalType": "address", "name": "accountToRevoke", "type": "address" } + ], + "name": "revokeCallPermission", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "revokeRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], + "name": "supportsInterface", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/opmainnet/vip-006/index.ts b/multisig/simulations/opmainnet/vip-006/index.ts new file mode 100644 index 000000000..c5f564349 --- /dev/null +++ b/multisig/simulations/opmainnet/vip-006/index.ts @@ -0,0 +1,31 @@ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip006, { OPMAINNET_ACM, OPMAINNET_NORMAL_TIMELOCK } from "../../../proposals/opmainnet/vip-006"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManagerAbi.json"; + +forking(127725800, async () => { + let acm: Contract; + let defaultAdminRole: string; + before(async () => { + acm = await ethers.getContractAt(ACCESS_CONTROL_MANAGER_ABI, OPMAINNET_ACM); + defaultAdminRole = await acm.DEFAULT_ADMIN_ROLE(); + }); + describe("Pre-VIP behaviour", async () => { + it("Normal Timelock does not has default admin role", async () => { + const hasRole = await acm.hasRole(defaultAdminRole, OPMAINNET_NORMAL_TIMELOCK); + expect(hasRole).equals(false); + }); + }); + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip006()); + }); + it("Normal Timelock has default admin role", async () => { + const hasRole = await acm.hasRole(defaultAdminRole, OPMAINNET_NORMAL_TIMELOCK); + expect(hasRole).equals(true); + }); + }); +}); diff --git a/simulations/vip-395/bscmainnet.ts b/simulations/vip-395/bscmainnet.ts index 96e1d86e3..a6de6586b 100644 --- a/simulations/vip-395/bscmainnet.ts +++ b/simulations/vip-395/bscmainnet.ts @@ -9,7 +9,7 @@ import vip395, { MAX_DAILY_LIMIT, OMNICHAIN_PROPOSAL_SENDER } from "../../vips/v import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; -const { zksyncmainnet } = NETWORK_ADDRESSES; +const { zksyncmainnet, opmainnet } = NETWORK_ADDRESSES; forking(43770901, async () => { const provider = ethers.provider; @@ -34,23 +34,30 @@ forking(43770901, async () => { txResponse, [ACCESS_CONTROL_MANAGER_ABI, OMNICHAIN_PROPOSAL_SENDER_ABI], ["SetMaxDailyLimit", "SetTrustedRemoteAddress", "ExecuteRemoteProposal", "StorePayload"], - [1, 1, 1, 0], + [2, 2, 2, 0], ); }, }); describe("Post-VIP behavior", () => { - it("Daily limit should be 100 of zksyncmainnet", async () => { + it("Daily limit should be 100 of zksyncmainnet and opmainnet", async () => { expect(await omnichainProposalSender.chainIdToMaxDailyLimit(LzChainId.zksyncmainnet)).to.equals(MAX_DAILY_LIMIT); + expect(await omnichainProposalSender.chainIdToMaxDailyLimit(LzChainId.opmainnet)).to.equals(MAX_DAILY_LIMIT); }); - it("Trusted remote should be set of zksyncmainnet", async () => { + it("Trusted remote should be set of zksyncmainnet and opmainnet", async () => { expect(await omnichainProposalSender.trustedRemoteLookup(LzChainId.zksyncmainnet)).to.be.equals( ethers.utils.solidityPack( ["address", "address"], [zksyncmainnet.OMNICHAIN_GOVERNANCE_EXECUTOR, OMNICHAIN_PROPOSAL_SENDER], ), ); + expect(await omnichainProposalSender.trustedRemoteLookup(LzChainId.opmainnet)).to.be.equals( + ethers.utils.solidityPack( + ["address", "address"], + [opmainnet.OMNICHAIN_GOVERNANCE_EXECUTOR, OMNICHAIN_PROPOSAL_SENDER], + ), + ); }); }); }); diff --git a/simulations/vip-395/opmainnet.ts b/simulations/vip-395/opmainnet.ts new file mode 100644 index 000000000..f54177941 --- /dev/null +++ b/simulations/vip-395/opmainnet.ts @@ -0,0 +1,151 @@ +import { expect } from "chai"; +import { BigNumber, Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId } from "src/types"; +import { expectEvents, getOmnichainProposalSenderAddress } from "src/utils"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip006 from "../../multisig/proposals/opmainnet/vip-006"; +import vip395, { + DEFAULT_ADMIN_ROLE, + OP_MAINNET_ACM, + OP_MAINNET_ACM_AGGREGATOR, + OP_MAINNET_OMNICHAIN_EXECUTOR_OWNER, +} from "../../vips/vip-395/bscmainnet"; +import ACMAggregator_ABI from "./abi/ACMAggregator.json"; +import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; +import OMNICHAIN_EXECUTOR_OWNER_ABI from "./abi/OmnichainExecutorOwner_ABI.json"; +import OMNICHAIN_GOVERNANCE_EXECUTOR_ABI from "./abi/OmnichainGovernanceExecutor_ABI.json"; + +const { opmainnet } = NETWORK_ADDRESSES; +const FAST_TRACK_TIMELOCK = "0x508bD9C31E8d6760De04c70fe6c2b24B3cDea7E7"; +const CRITICAL_TIMELOCK = "0xB82479bc345CAA7326D7d21306972033226fC185"; + +forking(127726072, async () => { + const provider = ethers.provider; + let lastProposalReceived: BigNumber; + let executor: Contract; + let executorOwner: Contract; + + before(async () => { + executor = new ethers.Contract( + opmainnet.OMNICHAIN_GOVERNANCE_EXECUTOR, + OMNICHAIN_GOVERNANCE_EXECUTOR_ABI, + provider, + ); + executorOwner = new ethers.Contract(OP_MAINNET_OMNICHAIN_EXECUTOR_OWNER, OMNICHAIN_EXECUTOR_OWNER_ABI, provider); + lastProposalReceived = await executor.lastProposalReceived(); + await pretendExecutingVip(await vip006()); + }); + + describe("Pre-VIP behaviour", async () => { + it("Normal Timelock has default admin role on ZKsync mainnet", async () => { + const acm = await ethers.getContractAt(ACCESS_CONTROL_MANAGER_ABI, OP_MAINNET_ACM); + const hasRole = await acm.hasRole(DEFAULT_ADMIN_ROLE, opmainnet.NORMAL_TIMELOCK); + expect(hasRole).equals(true); + }); + }); + + testForkedNetworkVipCommands("vip395 configures bridge", await vip395(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [39]); + await expectEvents(txResponse, [ACMAggregator_ABI], ["GrantPermissionsExecuted"], [1]); + }, + }); + + describe("Post-VIP behaviour", async () => { + const acm = new ethers.Contract(OP_MAINNET_ACM, ACCESS_CONTROL_MANAGER_ABI, provider); + + it("Proposal id should be incremented", async () => { + expect(await executor.lastProposalReceived()).to.be.equals(lastProposalReceived.add(1)); + }); + it("proposal should be executed", async () => { + const pId = await executor.lastProposalReceived(); + expect(await executor.state(pId)).to.be.equals(2); + }); + it("check configuration", async () => { + // Check Timelock configurations + expect(await executor.proposalTimelocks(0)).equals(opmainnet.NORMAL_TIMELOCK); + expect(await executor.proposalTimelocks(1)).equals(FAST_TRACK_TIMELOCK); + expect(await executor.proposalTimelocks(2)).equals(CRITICAL_TIMELOCK); + + // Check trusted remote + expect(await executor.trustedRemoteLookup(LzChainId.bscmainnet)).equals( + ethers.utils.solidityPack( + ["address", "address"], + [getOmnichainProposalSenderAddress(), opmainnet.OMNICHAIN_GOVERNANCE_EXECUTOR], + ), + ); + + // Check receiving limit + expect(await executor.maxDailyReceiveLimit()).equals(100); + expect(await executor.last24HourCommandsReceived()).equals(4); + + // Check function registry + const functionSignatures: string[] = [ + "forceResumeReceive(uint16,bytes)", + "pause()", + "unpause()", + "setSendVersion(uint16)", + "setReceiveVersion(uint16)", + "setMaxDailyReceiveLimit(uint256)", + "setTrustedRemoteAddress(uint16,bytes)", + "setPrecrime(address)", + "setMinDstGas(uint16,uint16,uint256)", + "setPayloadSizeLimit(uint16,uint256)", + "setConfig(uint16,uint16,uint256,bytes)", + "addTimelocks(ITimelock[])", + "setTimelockPendingAdmin(address,uint8)", + "retryMessage(uint16,bytes,uint64,bytes)", + "setGuardian(address)", + "setSrcChainId(uint16)", + ]; + const getFunctionSelector = (signature: string): string => { + return ethers.utils.keccak256(ethers.utils.toUtf8Bytes(signature)).substring(0, 10); + }; + + for (const signature of functionSignatures) { + const selector = getFunctionSelector(signature); + expect(await executorOwner.functionRegistry(selector)).equals(signature); + } + }); + it("Default admin role must be revoked from ACMAggregator contract on ZKsync mainnet", async () => { + expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OP_MAINNET_ACM_AGGREGATOR)).to.be.false; + }); + it("Guardian and all timelocks are allowed to call retryMessage ", async () => { + const role = ethers.utils.solidityPack( + ["address", "string"], + [OP_MAINNET_OMNICHAIN_EXECUTOR_OWNER, "retryMessage(uint16,bytes,uint64,bytes)"], + ); + const roleHash = ethers.utils.keccak256(role); + expect(await acm.hasRole(roleHash, opmainnet.GUARDIAN)).to.be.true; + expect(await acm.hasRole(roleHash, opmainnet.NORMAL_TIMELOCK)).to.be.true; + expect(await acm.hasRole(roleHash, FAST_TRACK_TIMELOCK)).to.be.true; + expect(await acm.hasRole(roleHash, CRITICAL_TIMELOCK)).to.be.true; + }); + + it("Guardian is allowed to call forceResumeReceive but not timelocks", async () => { + const role = ethers.utils.solidityPack( + ["address", "string"], + [OP_MAINNET_OMNICHAIN_EXECUTOR_OWNER, "forceResumeReceive(uint16,bytes)"], + ); + const roleHash = ethers.utils.keccak256(role); + expect(await acm.hasRole(roleHash, opmainnet.GUARDIAN)).to.be.true; + expect(await acm.hasRole(roleHash, opmainnet.NORMAL_TIMELOCK)).to.be.false; + expect(await acm.hasRole(roleHash, FAST_TRACK_TIMELOCK)).to.be.false; + expect(await acm.hasRole(roleHash, CRITICAL_TIMELOCK)).to.be.false; + }); + it("Normal Timelock is allowed to call setSendVersion but not other timelocks and guardian", async () => { + const role = ethers.utils.solidityPack( + ["address", "string"], + [OP_MAINNET_OMNICHAIN_EXECUTOR_OWNER, "setSendVersion(uint16)"], + ); + const roleHash = ethers.utils.keccak256(role); + expect(await acm.hasRole(roleHash, opmainnet.GUARDIAN)).to.be.false; + expect(await acm.hasRole(roleHash, opmainnet.NORMAL_TIMELOCK)).to.be.true; + expect(await acm.hasRole(roleHash, FAST_TRACK_TIMELOCK)).to.be.false; + expect(await acm.hasRole(roleHash, CRITICAL_TIMELOCK)).to.be.false; + }); + }); +}); diff --git a/src/networkAddresses.ts b/src/networkAddresses.ts index 3c17f05f4..0fa4c47eb 100644 --- a/src/networkAddresses.ts +++ b/src/networkAddresses.ts @@ -205,7 +205,7 @@ export const NETWORK_ADDRESSES = { POOL_REGISTRY: "0x6538C861C7A6997602311342657b9143dD9E8152", }, opmainnet: { - NORMAL_TIMELOCK: "", // To be deployed + NORMAL_TIMELOCK: "0x0C6f1E6B4fDa846f63A0d5a8a73EB811E0e0C04b", VTREASURY: "0x104c01EB7b4664551BE6A9bdB26a8C5c6Be7d3da", GUARDIAN: "0x2e94dd14E81999CdBF5deDE31938beD7308354b3", RESILIENT_ORACLE: "0x21FC48569bd3a6623281f55FC1F8B48B9386907b", @@ -215,5 +215,8 @@ export const NETWORK_ADDRESSES = { XVS_VAULT_PROXY: "0x133120607C018c949E91AE333785519F6d947e01", GENERIC_TEST_USER_ACCOUNT: "0x6f057A858171e187124ddEDF034dAc63De5dE5dB", POOL_REGISTRY: "0x147780799840d541C1d7c998F0cbA996d11D62bb", + ENDPOINT: "0x3c2269811836af69497E5F486A85D7316753cf62", + LZ_LIBRARY: "0x4D73AdB72bC3DD368966edD0f0b2148401A178E2", + OMNICHAIN_GOVERNANCE_EXECUTOR: "0x09b11b1CAdC08E239970A8993783f0f8EeC60ABf", }, }; diff --git a/vips/vip-395/bscmainnet.ts b/vips/vip-395/bscmainnet.ts index e9cf269a9..fde05b82a 100644 --- a/vips/vip-395/bscmainnet.ts +++ b/vips/vip-395/bscmainnet.ts @@ -2,13 +2,18 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { LzChainId, ProposalType } from "src/types"; import { makeProposal } from "src/utils"; -const { zksyncmainnet } = NETWORK_ADDRESSES; +const { zksyncmainnet, opmainnet } = NETWORK_ADDRESSES; export const OMNICHAIN_PROPOSAL_SENDER = "0x36a69dE601381be7b0DcAc5D5dD058825505F8f6"; +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; export const ZKSYNCMAINNET_OMNICHAIN_EXECUTOR_OWNER = "0xdfaed3E5d9707629Ed5c225b4fB980c064286771"; export const ZKSYNCMAINNET_ACM = "0x526159A92A82afE5327d37Ef446b68FD9a5cA914"; -export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; export const ZKSYNCMAINNET_ACM_AGGREGATOR = "0x88B1452e512c8fcf83889DdCfe54dF37D561Db82"; + +export const OP_MAINNET_OMNICHAIN_EXECUTOR_OWNER = "0xe6d9Eb3A07a1dc4496fc71417D7A7b9d5666BaA3"; +export const OP_MAINNET_ACM = "0xD71b1F33f6B0259683f11174EE4Ddc2bb9cE4eD6"; +export const OP_MAINNET_ACM_AGGREGATOR = "0xbbEBaF646e7a3E4064a899e68565B1b439eFdf70"; + export const MAX_DAILY_LIMIT = 100; const vip395 = () => { @@ -22,6 +27,7 @@ const vip395 = () => { }; return makeProposal( [ + // Omnichain sender configuration for zksync { target: OMNICHAIN_PROPOSAL_SENDER, signature: "setMaxDailyLimit(uint16,uint256)", @@ -32,6 +38,9 @@ const vip395 = () => { signature: "setTrustedRemoteAddress(uint16,bytes)", params: [LzChainId.zksyncmainnet, zksyncmainnet.OMNICHAIN_GOVERNANCE_EXECUTOR], }, + + // Remote commands for zksync + { target: ZKSYNCMAINNET_OMNICHAIN_EXECUTOR_OWNER, signature: "acceptOwnership()", @@ -56,6 +65,45 @@ const vip395 = () => { params: [DEFAULT_ADMIN_ROLE, ZKSYNCMAINNET_ACM_AGGREGATOR], dstChainId: LzChainId.zksyncmainnet, }, + + // Omnichain sender configuration for op mainnet + { + target: OMNICHAIN_PROPOSAL_SENDER, + signature: "setMaxDailyLimit(uint16,uint256)", + params: [LzChainId.opmainnet, MAX_DAILY_LIMIT], + }, + { + target: OMNICHAIN_PROPOSAL_SENDER, + signature: "setTrustedRemoteAddress(uint16,bytes)", + params: [LzChainId.opmainnet, opmainnet.OMNICHAIN_GOVERNANCE_EXECUTOR], + }, + + // Remote commands for op mainnet + + { + target: OP_MAINNET_OMNICHAIN_EXECUTOR_OWNER, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opmainnet, + }, + { + target: OP_MAINNET_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OP_MAINNET_ACM_AGGREGATOR], + dstChainId: LzChainId.opmainnet, + }, + { + target: OP_MAINNET_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.opmainnet, + }, + { + target: OP_MAINNET_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OP_MAINNET_ACM_AGGREGATOR], + dstChainId: LzChainId.opmainnet, + }, ], meta, ProposalType.REGULAR, From e48befd07aee597ceb7b3052de924dd939286c2f Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Fri, 8 Nov 2024 10:45:20 +0300 Subject: [PATCH 126/178] fixup! feat: add mainnet VIP for pufETH --- multisig/proposals/ethereum/vip-100/index.ts | 2 +- .../ethereum/vip-100/abi/erc20.json | 295 ++++++++++++++++++ .../simulations/ethereum/vip-100/index.ts | 25 ++ 3 files changed, 321 insertions(+), 1 deletion(-) create mode 100644 multisig/simulations/ethereum/vip-100/abi/erc20.json create mode 100644 multisig/simulations/ethereum/vip-100/index.ts diff --git a/multisig/proposals/ethereum/vip-100/index.ts b/multisig/proposals/ethereum/vip-100/index.ts index 9e61fedc3..135fdd49b 100644 --- a/multisig/proposals/ethereum/vip-100/index.ts +++ b/multisig/proposals/ethereum/vip-100/index.ts @@ -5,7 +5,7 @@ import { makeProposal } from "../../../../src/utils"; const { VTREASURY, NORMAL_TIMELOCK } = NETWORK_ADDRESSES.ethereum; -const PUFETH = "0xD9A442856C234a39a81a089C06451EBAa4306a72"; +export const PUFETH = "0xD9A442856C234a39a81a089C06451EBAa4306a72"; const INITIAL_SUPPLY = parseUnits("5", 18); export const vip100 = () => { diff --git a/multisig/simulations/ethereum/vip-100/abi/erc20.json b/multisig/simulations/ethereum/vip-100/abi/erc20.json new file mode 100644 index 000000000..374b04c75 --- /dev/null +++ b/multisig/simulations/ethereum/vip-100/abi/erc20.json @@ -0,0 +1,295 @@ +[ + { + "inputs": [ + { "internalType": "string", "name": "name_", "type": "string" }, + { "internalType": "string", "name": "symbol_", "type": "string" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "userAddress", "type": "address" }, + { "indexed": false, "internalType": "address payable", "name": "relayerAddress", "type": "address" }, + { "indexed": false, "internalType": "bytes", "name": "functionSignature", "type": "bytes" } + ], + "name": "MetaTransactionExecuted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, + { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } + ], + "name": "RoleAdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleGranted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } + ], + "name": "RoleRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_ADMIN_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "ERC712_VERSION", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "PREDICATE_ROLE", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "userAddress", "type": "address" }, + { "internalType": "bytes", "name": "functionSignature", "type": "bytes" }, + { "internalType": "bytes32", "name": "sigR", "type": "bytes32" }, + { "internalType": "bytes32", "name": "sigS", "type": "bytes32" }, + { "internalType": "uint8", "name": "sigV", "type": "uint8" } + ], + "name": "executeMetaTransaction", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [], + "name": "getChainId", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [], + "name": "getDomainSeperator", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "getNonce", + "outputs": [{ "internalType": "uint256", "name": "nonce", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleAdmin", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "uint256", "name": "index", "type": "uint256" } + ], + "name": "getRoleMember", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], + "name": "getRoleMemberCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "grantRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "hasRole", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "user", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "renounceRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "bytes32", "name": "role", "type": "bytes32" }, + { "internalType": "address", "name": "account", "type": "address" } + ], + "name": "revokeRole", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "recipient", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/ethereum/vip-100/index.ts b/multisig/simulations/ethereum/vip-100/index.ts new file mode 100644 index 000000000..1a73e188c --- /dev/null +++ b/multisig/simulations/ethereum/vip-100/index.ts @@ -0,0 +1,25 @@ +import { expect } from "chai"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip100, { PUFETH } from "../../../proposals/ethereum/vip-100"; +import ERC20_ABI from "./abi/erc20.json"; + +const { NORMAL_TIMELOCK, VTREASURY } = NETWORK_ADDRESSES.ethereum; + +forking(21130180, async () => { + const pufETH = new ethers.Contract(PUFETH, ERC20_ABI, ethers.provider); + + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip100()); + }); + + it("transfers initial supply from treasury to normal timelock", async () => { + expect(await pufETH.balanceOf(NORMAL_TIMELOCK)).to.equal(parseUnits("5", 18)); + expect(await pufETH.balanceOf(VTREASURY)).to.equal(0); + }); + }); +}); From 06cb316565a4f231ecc9b61c4c7606c7e0e1e2ca Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Fri, 8 Nov 2024 12:49:17 +0300 Subject: [PATCH 127/178] fixup! feat: add mainnet VIP for pufETH --- simulations/vip-400/ethereum.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/simulations/vip-400/ethereum.ts b/simulations/vip-400/ethereum.ts index ef52d8bcc..72180cb6d 100644 --- a/simulations/vip-400/ethereum.ts +++ b/simulations/vip-400/ethereum.ts @@ -30,7 +30,7 @@ const WETH = "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2"; const WETH_CHAINLINK_FEED = "0x5f4eC3Df9cbd43714FE2740f5E3616155c5b8419"; const PUFETH_HOLDER = "0xDdA0483184E75a5579ef9635ED14BacCf9d50283"; -const { POOL_REGISTRY, RESILIENT_ORACLE, REDSTONE_ORACLE, GUARDIAN, VTREASURY, CHAINLINK_ORACLE } = ethereum; +const { POOL_REGISTRY, RESILIENT_ORACLE, REDSTONE_ORACLE, GUARDIAN, CHAINLINK_ORACLE } = ethereum; forking(21130180, async () => { const resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, ethers.provider); @@ -94,7 +94,7 @@ forking(21130180, async () => { it("check supply", async () => { const expectedSupply = parseUnits("5", 8); - expect(await vToken.balanceOf(VTREASURY)).to.equal(expectedSupply); + expect(await vToken.balanceOf("0x495aeBf595D4C641af21A2a021C983C6565CA1A2")).to.equal(expectedSupply); }); it("has correct protocol share reserve", async () => { From 019c19d4f57d9f16ab44e1e8ea03c7337b79e63b Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Fri, 8 Nov 2024 19:19:02 +0530 Subject: [PATCH 128/178] fix: fix getSourceChainId & add new network in remote network --- simulations/vip-395/opmainnet.ts | 2 +- src/types.ts | 4 ++-- src/utils.ts | 2 ++ 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/simulations/vip-395/opmainnet.ts b/simulations/vip-395/opmainnet.ts index f54177941..c04bd2607 100644 --- a/simulations/vip-395/opmainnet.ts +++ b/simulations/vip-395/opmainnet.ts @@ -22,7 +22,7 @@ const { opmainnet } = NETWORK_ADDRESSES; const FAST_TRACK_TIMELOCK = "0x508bD9C31E8d6760De04c70fe6c2b24B3cDea7E7"; const CRITICAL_TIMELOCK = "0xB82479bc345CAA7326D7d21306972033226fC185"; -forking(127726072, async () => { +forking(127735654, async () => { const provider = ethers.provider; let lastProposalReceived: BigNumber; let executor: Contract; diff --git a/src/types.ts b/src/types.ts index 2ba0bd240..82882d688 100644 --- a/src/types.ts +++ b/src/types.ts @@ -18,8 +18,8 @@ export type REMOTE_NETWORKS = | "arbitrumone" | "zksyncsepolia"; -export const REMOTE_TESTNET_NETWORKS = ["sepolia", "opbnbtestnet", "arbitrumsepolia", "zksyncsepolia"]; -export const REMOTE_MAINNET_NETWORKS = ["ethereum", "opbnbmainnet", "arbitrumone", "zksyncmainnet"]; +export const REMOTE_TESTNET_NETWORKS = ["sepolia", "opbnbtestnet", "arbitrumsepolia", "zksyncsepolia", "opsepolia"]; +export const REMOTE_MAINNET_NETWORKS = ["ethereum", "opbnbmainnet", "arbitrumone", "zksyncmainnet", "opmainnet"]; export interface ProposalMeta { version: string; title: string; diff --git a/src/utils.ts b/src/utils.ts index fc2b2617d..aecf145d7 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -72,6 +72,8 @@ export const getSourceChainId = (network: REMOTE_NETWORKS) => { return LzChainId.bscmainnet; } else if (REMOTE_TESTNET_NETWORKS.includes(network as string)) { return LzChainId.bsctestnet; + } else { + throw new Error("Network is not registered. Please register it."); } }; From 7ca43ea6788c4b1bbf01d0e6b6f054e131ffff42 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Fri, 8 Nov 2024 15:26:57 +0100 Subject: [PATCH 129/178] feat: set id and description for the VIP 394 --- .../ethereum/{vip-068 => vip-069}/index.ts | 4 +- .../{vip-068 => vip-069}/abi/erc20.json | 0 .../ethereum/{vip-068 => vip-069}/index.ts | 4 +- .../abi/OmnichainProposalSender.json | 0 .../abi/PoolRegistry.json | 0 .../abi/PrimeConverter.json | 0 .../abi/ResilientOracle.json | 0 .../{vip-391 => vip-394}/abi/comptroller.json | 0 .../{vip-391 => vip-394}/abi/erc20.json | 0 .../{vip-391 => vip-394}/abi/vToken.json | 0 .../{vip-391 => vip-394}/bscmainnet.ts | 4 +- .../{vip-391 => vip-394}/bsctestnet.ts | 4 +- simulations/{vip-391 => vip-394}/ethereum.ts | 10 +-- simulations/{vip-391 => vip-394}/sepolia.ts | 6 +- vips/{vip-391 => vip-394}/bscmainnet.ts | 62 +++++++++++++++++-- vips/{vip-391 => vip-394}/bsctestnet.ts | 6 +- 16 files changed, 77 insertions(+), 23 deletions(-) rename multisig/proposals/ethereum/{vip-068 => vip-069}/index.ts (91%) rename multisig/simulations/ethereum/{vip-068 => vip-069}/abi/erc20.json (100%) rename multisig/simulations/ethereum/{vip-068 => vip-069}/index.ts (85%) rename simulations/{vip-391 => vip-394}/abi/OmnichainProposalSender.json (100%) rename simulations/{vip-391 => vip-394}/abi/PoolRegistry.json (100%) rename simulations/{vip-391 => vip-394}/abi/PrimeConverter.json (100%) rename simulations/{vip-391 => vip-394}/abi/ResilientOracle.json (100%) rename simulations/{vip-391 => vip-394}/abi/comptroller.json (100%) rename simulations/{vip-391 => vip-394}/abi/erc20.json (100%) rename simulations/{vip-391 => vip-394}/abi/vToken.json (100%) rename simulations/{vip-391 => vip-394}/bscmainnet.ts (83%) rename simulations/{vip-391 => vip-394}/bsctestnet.ts (83%) rename simulations/{vip-391 => vip-394}/ethereum.ts (96%) rename simulations/{vip-391 => vip-394}/sepolia.ts (98%) rename vips/{vip-391 => vip-394}/bscmainnet.ts (55%) rename vips/{vip-391 => vip-394}/bsctestnet.ts (97%) diff --git a/multisig/proposals/ethereum/vip-068/index.ts b/multisig/proposals/ethereum/vip-069/index.ts similarity index 91% rename from multisig/proposals/ethereum/vip-068/index.ts rename to multisig/proposals/ethereum/vip-069/index.ts index be126c0d8..22b85e41d 100644 --- a/multisig/proposals/ethereum/vip-068/index.ts +++ b/multisig/proposals/ethereum/vip-069/index.ts @@ -8,7 +8,7 @@ const { ethereum } = NETWORK_ADDRESSES; export const eBTC = "0x657e8C867D8B37dCC18fA4Caead9C45EB088C642"; export const INITIAL_SUPPLY = parseUnits("0.14471345", 8); -export const vip068 = () => { +export const vip069 = () => { return makeProposal([ { target: ethereum.VTREASURY, @@ -18,4 +18,4 @@ export const vip068 = () => { ]); }; -export default vip068; +export default vip069; diff --git a/multisig/simulations/ethereum/vip-068/abi/erc20.json b/multisig/simulations/ethereum/vip-069/abi/erc20.json similarity index 100% rename from multisig/simulations/ethereum/vip-068/abi/erc20.json rename to multisig/simulations/ethereum/vip-069/abi/erc20.json diff --git a/multisig/simulations/ethereum/vip-068/index.ts b/multisig/simulations/ethereum/vip-069/index.ts similarity index 85% rename from multisig/simulations/ethereum/vip-068/index.ts rename to multisig/simulations/ethereum/vip-069/index.ts index ac474cdfc..a612610a2 100644 --- a/multisig/simulations/ethereum/vip-068/index.ts +++ b/multisig/simulations/ethereum/vip-069/index.ts @@ -4,7 +4,7 @@ import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { forking, pretendExecutingVip } from "../../../../src/vip-framework"; -import vip068, { INITIAL_SUPPLY, eBTC } from "../../../proposals/ethereum/vip-068"; +import vip069, { INITIAL_SUPPLY, eBTC } from "../../../proposals/ethereum/vip-069"; import ERC20_ABI from "./abi/erc20.json"; forking(21135461, async () => { @@ -13,7 +13,7 @@ forking(21135461, async () => { describe("Post-VIP behavior", async () => { before(async () => { eBTCContract = new ethers.Contract(eBTC, ERC20_ABI, ethers.provider); - await pretendExecutingVip(await vip068()); + await pretendExecutingVip(await vip069()); }); it("check balance", async () => { diff --git a/simulations/vip-391/abi/OmnichainProposalSender.json b/simulations/vip-394/abi/OmnichainProposalSender.json similarity index 100% rename from simulations/vip-391/abi/OmnichainProposalSender.json rename to simulations/vip-394/abi/OmnichainProposalSender.json diff --git a/simulations/vip-391/abi/PoolRegistry.json b/simulations/vip-394/abi/PoolRegistry.json similarity index 100% rename from simulations/vip-391/abi/PoolRegistry.json rename to simulations/vip-394/abi/PoolRegistry.json diff --git a/simulations/vip-391/abi/PrimeConverter.json b/simulations/vip-394/abi/PrimeConverter.json similarity index 100% rename from simulations/vip-391/abi/PrimeConverter.json rename to simulations/vip-394/abi/PrimeConverter.json diff --git a/simulations/vip-391/abi/ResilientOracle.json b/simulations/vip-394/abi/ResilientOracle.json similarity index 100% rename from simulations/vip-391/abi/ResilientOracle.json rename to simulations/vip-394/abi/ResilientOracle.json diff --git a/simulations/vip-391/abi/comptroller.json b/simulations/vip-394/abi/comptroller.json similarity index 100% rename from simulations/vip-391/abi/comptroller.json rename to simulations/vip-394/abi/comptroller.json diff --git a/simulations/vip-391/abi/erc20.json b/simulations/vip-394/abi/erc20.json similarity index 100% rename from simulations/vip-391/abi/erc20.json rename to simulations/vip-394/abi/erc20.json diff --git a/simulations/vip-391/abi/vToken.json b/simulations/vip-394/abi/vToken.json similarity index 100% rename from simulations/vip-391/abi/vToken.json rename to simulations/vip-394/abi/vToken.json diff --git a/simulations/vip-391/bscmainnet.ts b/simulations/vip-394/bscmainnet.ts similarity index 83% rename from simulations/vip-391/bscmainnet.ts rename to simulations/vip-394/bscmainnet.ts index b65bd66fb..8e77cd224 100644 --- a/simulations/vip-391/bscmainnet.ts +++ b/simulations/vip-394/bscmainnet.ts @@ -1,10 +1,10 @@ import { expectEvents } from "../../src/utils"; import { forking, testVip } from "../../src/vip-framework"; -import vip391 from "../../vips/vip-391/bscmainnet"; +import vip394 from "../../vips/vip-394/bscmainnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; forking(43778615, async () => { - testVip("vip391", await vip391(), { + testVip("vip394", await vip394(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-391/bsctestnet.ts b/simulations/vip-394/bsctestnet.ts similarity index 83% rename from simulations/vip-391/bsctestnet.ts rename to simulations/vip-394/bsctestnet.ts index b5b44e2b8..b77d4af25 100644 --- a/simulations/vip-391/bsctestnet.ts +++ b/simulations/vip-394/bsctestnet.ts @@ -1,10 +1,10 @@ import { expectEvents } from "../../src/utils"; import { forking, testVip } from "../../src/vip-framework"; -import vip391 from "../../vips/vip-391/bsctestnet"; +import vip394 from "../../vips/vip-394/bsctestnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; forking(45194889, async () => { - testVip("vip391", await vip391(), { + testVip("vip394", await vip394(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-391/ethereum.ts b/simulations/vip-394/ethereum.ts similarity index 96% rename from simulations/vip-391/ethereum.ts rename to simulations/vip-394/ethereum.ts index c4765b488..df90aa51f 100644 --- a/simulations/vip-391/ethereum.ts +++ b/simulations/vip-394/ethereum.ts @@ -10,8 +10,8 @@ import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIs import { checkVToken } from "src/vip-framework/checks/checkVToken"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; -import vip068 from "../../multisig/proposals/ethereum/vip-068"; -import vip391, { +import vip069 from "../../multisig/proposals/ethereum/vip-069"; +import vip394, { BORROW_CAP, BaseAssets, CORE_COMPTROLLER, @@ -19,7 +19,7 @@ import vip391, { USDT_PRIME_CONVERTER, eBTC, veBTC, -} from "../../vips/vip-391/bscmainnet"; +} from "../../vips/vip-394/bscmainnet"; import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; import PRIME_CONVERTER_ABI from "./abi/PrimeConverter.json"; import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; @@ -44,7 +44,7 @@ forking(21130278, async () => { let wbtc: Contract; before(async () => { - await pretendExecutingVip(await vip068()); + await pretendExecutingVip(await vip069()); await impersonateAccount(ethereum.NORMAL_TIMELOCK); await setBalance(ethereum.NORMAL_TIMELOCK, parseUnits("1000", 18)); @@ -72,7 +72,7 @@ forking(21130278, async () => { await setMaxStalePeriod(resilientOracle, usdt, ONE_YEAR); }); - testForkedNetworkVipCommands("vip391", await vip391()); + testForkedNetworkVipCommands("vip394", await vip394()); describe("Post-VIP behavior", async () => { it("check price", async () => { diff --git a/simulations/vip-391/sepolia.ts b/simulations/vip-394/sepolia.ts similarity index 98% rename from simulations/vip-391/sepolia.ts rename to simulations/vip-394/sepolia.ts index 33c8d90ed..40dad13b4 100644 --- a/simulations/vip-391/sepolia.ts +++ b/simulations/vip-394/sepolia.ts @@ -9,7 +9,7 @@ import { checkIsolatedPoolsComptrollers } from "src/vip-framework/checks/checkIs import { checkVToken } from "src/vip-framework/checks/checkVToken"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; -import vip391, { +import vip394, { BORROW_CAP, BaseAssets, CORE_COMPTROLLER, @@ -17,7 +17,7 @@ import vip391, { USDT_PRIME_CONVERTER, eBTC, veBTC, -} from "../../vips/vip-391/bsctestnet"; +} from "../../vips/vip-394/bsctestnet"; import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; import PRIME_CONVERTER_ABI from "./abi/PrimeConverter.json"; import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; @@ -55,7 +55,7 @@ forking(6976822, async () => { usdt = await ethers.getContractAt(ERC20_ABI, BaseAssets[0], await ethers.provider.getSigner(USDT_USER)); }); - testForkedNetworkVipCommands("vip391", await vip391()); + testForkedNetworkVipCommands("vip394", await vip394()); describe("Post-VIP behavior", async () => { it("check price", async () => { diff --git a/vips/vip-391/bscmainnet.ts b/vips/vip-394/bscmainnet.ts similarity index 55% rename from vips/vip-391/bscmainnet.ts rename to vips/vip-394/bscmainnet.ts index 49b835dd2..d812c591d 100644 --- a/vips/vip-391/bscmainnet.ts +++ b/vips/vip-394/bscmainnet.ts @@ -30,11 +30,65 @@ export const BaseAssets = [ const CONVERSION_INCENTIVE = parseUnits("0.0001", 18); const eBTCAccountantOracle = "0x077A11d634be3498b9af3EbD3d5D35A0fC3569d8"; -const vip391 = () => { +const vip394 = () => { const meta = { version: "v2", - title: "VIP-391", - description: `### Description`, + title: "VIP-394 [Ethereum] New eBTC market in the Core pool", + description: `#### Summary + +If passed, following the Community proposal “[Support eBTC collateral on Venus on ETH Mainnet](https://community.venus.io/t/support-ebtc-collateral-on-venus-on-eth-mainnet/4603/1)” and [the associated snapshot](https://snapshot.org/#/venus-xvs.eth/proposal/0x2601ffe3252262981a9801504ade2ffd0018a87b226fb2c16c7eca407d0d5619), this VIP adds a market for [eBTC](https://etherscan.io/address/0x657e8c867d8b37dcc18fa4caead9c45eb088c642) into the Core pool on Ethereum, and refunds the [Community Wallet](https://bscscan.com/address/0xc444949e0054A23c44Fc45789738bdF64aed2391) the provided bootstrap liquidity. + +#### Description + +#### Risk parameters + +Following [Chaos Labs recommendations](https://community.venus.io/t/support-ebtc-collateral-on-venus-on-eth-mainnet/4603/4), the risk parameters for the new market are: + +Underlying token: [eBTC](https://etherscan.io/address/0x657e8c867d8b37dcc18fa4caead9c45eb088c642) + +- Borrow cap: 25 +- Supply cap: 12.5 +- Collateral factor: 68% +- Liquidation threshold: 72% +- Reserve factor: 20% + +Bootstrap liquidity: 0.14471345 eBTC - provided by the [Ether.fi project](https://etherscan.io/address/0x86fBaEB3D6b5247F420590D303a6ffC9cd523790). + +Interest rate curve for the new market: + +- kink: 45% +- base (yearly): 0% +- multiplier (yearly): 9% +- jump multiplier (yearly): 200% + +#### Oracles configuration + +The [ResilientOracle](https://docs-v4.venus.io/risk/resilient-price-oracle) deployed to [Ethereum](https://etherscan.io/address/0xd2ce3fb018805ef92b8C5976cb31F84b4E295F94) is used for eBTC. + +- Main oracle: [EtherfiAccountantOracle](https://github.com/VenusProtocol/oracle/pull/233) +- Accountant contract: [0x1b293DC39F94157fA0D1D36d7e0090C8B8B8c13F](https://etherscan.io/address/0x1b293DC39F94157fA0D1D36d7e0090C8B8B8c13F) + +The EtherfiAccountantOracle gets the conversion rate for eBTC/BTC from the Accountant contract, and then the BTC/USD price from the Venus ResilientOracle. + +#### Security and additional considerations + +We applied the following security procedures for this upgrade: + +- **VIP execution simulation**: in a simulation environment, validating the new market is properly added to the Core pool on Ethereum, with the right parameters and the expected bootstrap liquidity +- **Deployment on testnet**: the same market has been deployed to Sepolia, and used in the Venus Protocol testnet deployment + +The bootstrap liquidity is available on the [Venus Treasury on Ethereum](https://etherscan.io/address/0xFD9B071168bC27DBE16406eC3Aba050Ce8Eb22FA). If this VIP passes, [this](https://app.safe.global/transactions/tx?safe=eth:0x285960C5B22fD66A736C7136967A3eB15e93CC67&id=multisig_0x285960C5B22fD66A736C7136967A3eB15e93CC67_0x1f10be126a80e9650d1abb9672b5b4d2df83160ffe8843c0daeac5c79b3b3ec0) multisig transaction will be executed to withdraw those funds, allowing Governance to supply them to the new eBTC market. + +#### Deployed contracts + +- Mainnet veBTC_Core: [0x325cEB02fe1C2fF816A83a5770eA0E88e2faEcF2](https://etherscan.io/address/0x325cEB02fe1C2fF816A83a5770eA0E88e2faEcF2) +- Testnet veBTC_Core: [0x8E6241389e823111259413810b81a050bd45e5cE](https://sepolia.etherscan.io/address/0x8E6241389e823111259413810b81a050bd45e5cE) + +#### References + +- [VIP simulation](https://github.com/VenusProtocol/vips/pull/420) +- [Deployment to Sepolia](https://sepolia.etherscan.io/tx/0xc5f0e85dba931274b1a753a585e866f0b9e22bd8fda0291dfc139d19ee574e1c) +- [Documentation](https://docs-v4.venus.io/)`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", @@ -116,4 +170,4 @@ const vip391 = () => { ProposalType.REGULAR, ); }; -export default vip391; +export default vip394; diff --git a/vips/vip-391/bsctestnet.ts b/vips/vip-394/bsctestnet.ts similarity index 97% rename from vips/vip-391/bsctestnet.ts rename to vips/vip-394/bsctestnet.ts index d78ee262c..52ebfd63d 100644 --- a/vips/vip-391/bsctestnet.ts +++ b/vips/vip-394/bsctestnet.ts @@ -32,10 +32,10 @@ export const BaseAssets = [ ]; const CONVERSION_INCENTIVE = parseUnits("0.0001", 18); -const vip391 = () => { +const vip394 = () => { const meta = { version: "v2", - title: "VIP-391 [Ethereum] New eBTC market in the Core pool", + title: "VIP-394 [Ethereum] New eBTC market in the Core pool", description: `### Description`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", @@ -127,4 +127,4 @@ const vip391 = () => { ProposalType.REGULAR, ); }; -export default vip391; +export default vip394; From 8d4c52ad012c82cb6277e9a1f0a26f87a76ad882 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Fri, 8 Nov 2024 20:33:10 +0530 Subject: [PATCH 130/178] refactor: converter configuration on arbitrum sepolia --- .../arbitrumsepolia/vip-016/commands.ts | 61 +++--- .../arbitrumsepolia/vip-016/index.ts | 73 +------ .../arbitrumsepolia/vip-016/index.ts | 10 +- simulations/vip-395/arbitrumsepolia.ts | 200 +++++++++++++++++- vips/vip-395/bsctestnet.ts | 93 ++++++++ 5 files changed, 323 insertions(+), 114 deletions(-) diff --git a/multisig/proposals/arbitrumsepolia/vip-016/commands.ts b/multisig/proposals/arbitrumsepolia/vip-016/commands.ts index 9e48e39ed..e89434acf 100644 --- a/multisig/proposals/arbitrumsepolia/vip-016/commands.ts +++ b/multisig/proposals/arbitrumsepolia/vip-016/commands.ts @@ -1,4 +1,5 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId } from "src/types"; import { ACM, Assets, CONVERTER_NETWORK, converters } from "./Addresses"; @@ -12,12 +13,6 @@ interface AcceptOwnership { params: []; } -interface ConverterCommand { - target: string; - signature: string; - params: [string]; -} - interface CallPermission { target: string; signature: string; @@ -52,39 +47,35 @@ function generateAcceptOwnershipCommands(ConvertersArray: string[]): AcceptOwner return acceptOwnershipCommandsArray; } -function generateConverterCommands(ConvertersArray: string[]): ConverterCommand[] { - const commandsArray: ConverterCommand[] = []; - - for (const converter of ConvertersArray) { - // Add AddConverterNetwork command - const addConverterNetworkConfig: ConverterCommand = { - target: converter, - signature: "setConverterNetwork(address)", - params: [CONVERTER_NETWORK], - }; - - // Add AddTokenConverter command - const addTokenConverterConfig: ConverterCommand = { - target: CONVERTER_NETWORK, - signature: "addTokenConverter(address)", - params: [converter], - }; - - commandsArray.push(addConverterNetworkConfig); - commandsArray.push(addTokenConverterConfig); - } +const generateSetConverterNetworkCommands = () => { + return converters.map(converter => ({ + target: converter, + signature: "setConverterNetwork(address)", + params: [CONVERTER_NETWORK], + })); +}; - return commandsArray; -} +const generateAddConverterNetworkCommands = () => { + return converters.map(converter => ({ + target: CONVERTER_NETWORK, + signature: "addTokenConverter(address)", + params: [converter], + dstChainId: LzChainId.arbitrumsepolia, + })); +}; function generateCallPermissionCommands(ConvertersArray: string[]): CallPermission[] { const callPermissionCommandsArray: CallPermission[] = []; for (const converter of ConvertersArray) { - const config1 = grant(converter, "setConversionConfig(address,address,ConversionConfig)", arbitrumsepolia.GUARDIAN); - const config2 = grant(converter, "pauseConversion()", arbitrumsepolia.GUARDIAN); - const config3 = grant(converter, "resumeConversion()", arbitrumsepolia.GUARDIAN); - const config4 = grant(converter, "setMinAmountToConvert(uint256)", arbitrumsepolia.GUARDIAN); + const config1 = grant( + converter, + "setConversionConfig(address,address,ConversionConfig)", + arbitrumsepolia.NORMAL_TIMELOCK, + ); + const config2 = grant(converter, "pauseConversion()", arbitrumsepolia.NORMAL_TIMELOCK); + const config3 = grant(converter, "resumeConversion()", arbitrumsepolia.NORMAL_TIMELOCK); + const config4 = grant(converter, "setMinAmountToConvert(uint256)", arbitrumsepolia.NORMAL_TIMELOCK); callPermissionCommandsArray.push(config1); callPermissionCommandsArray.push(config2); @@ -102,6 +93,8 @@ for (let i = 0; i < Assets.length - 1; i++) { export const acceptOwnershipCommandsAllConverters: AcceptOwnership[] = generateAcceptOwnershipCommands(converters); -export const converterCommands: ConverterCommand[] = generateConverterCommands(converters); +export const setConverterNetworkCommands = generateSetConverterNetworkCommands(); + +export const addConverterNetworkCommands = generateAddConverterNetworkCommands(); export const callPermissionCommandsAllConverter: CallPermission[] = generateCallPermissionCommands(converters); diff --git a/multisig/proposals/arbitrumsepolia/vip-016/index.ts b/multisig/proposals/arbitrumsepolia/vip-016/index.ts index 35ba7d41f..efc673552 100644 --- a/multisig/proposals/arbitrumsepolia/vip-016/index.ts +++ b/multisig/proposals/arbitrumsepolia/vip-016/index.ts @@ -1,38 +1,15 @@ -import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { makeProposal } from "src/utils"; import { - BaseAssets, CONVERTER_NETWORK, - USDCPrimeConverterTokenOuts, - USDC_PRIME_CONVERTER, - USDTPrimeConverterTokenOuts, - USDT_PRIME_CONVERTER, - WBTCPrimeConverterTokenOuts, - WBTC_PRIME_CONVERTER, - WETHPrimeConverterTokenOuts, - WETH_PRIME_CONVERTER, - XVSVaultConverterTokenOuts, - XVS_VAULT_CONVERTER, } from "./Addresses"; import { acceptOwnershipCommandsAllConverters, callPermissionCommandsAllConverter, - converterCommands, - grant, - incentiveAndAccessibilities, + setConverterNetworkCommands, } from "./commands"; -const { arbitrumsepolia } = NETWORK_ADDRESSES; - -export const COMPTROLLER_CORE = "0x006D44b6f5927b3eD83bD0c1C36Fb1A3BaCaC208"; -export const COMPTROLLER_LST = "0x3D04F926b2a165BBa17FBfccCCB61513634fa5e4"; -export const PRIME = "0xAdB04AC4942683bc41E27d18234C8DC884786E89"; -export const PLP = "0xE82c2c10F55D3268126C29ec813dC6F086904694"; - export const XVS_VAULT_TREASURY = "0x309b71a417dA9CfA8aC47e6038000B1739d9A3A6"; -export const PROTOCOL_SHARE_RESERVE_PROXY = "0x09267d30798B59c581ce54E861A084C6FC298666"; -export const VTREASURY = "0x4e7ab1fD841E1387Df4c91813Ae03819C33D5bdB"; const vip016 = () => { return makeProposal([ @@ -48,53 +25,7 @@ const vip016 = () => { params: [], }, ...callPermissionCommandsAllConverter, - - grant(CONVERTER_NETWORK, "addTokenConverter(address)", arbitrumsepolia.GUARDIAN), - grant(CONVERTER_NETWORK, "removeTokenConverter(address)", arbitrumsepolia.GUARDIAN), - grant(XVS_VAULT_TREASURY, "fundXVSVault(uint256)", arbitrumsepolia.GUARDIAN), - - { - target: PROTOCOL_SHARE_RESERVE_PROXY, - signature: "addOrUpdateDistributionConfigs((uint8,uint16,address)[])", - params: [ - [ - [0, 6000, VTREASURY], - [0, 2000, XVS_VAULT_CONVERTER], - [0, 500, USDC_PRIME_CONVERTER], // 25% of the Prime allocation - [0, 500, USDT_PRIME_CONVERTER], // 25% of the Prime allocation - [0, 300, WBTC_PRIME_CONVERTER], // 15% of the Prime allocation - [0, 700, WETH_PRIME_CONVERTER], // 35% of the Prime allocation - [1, 8000, VTREASURY], - [1, 2000, XVS_VAULT_CONVERTER], - ], - ], - }, - ...converterCommands, - { - target: USDT_PRIME_CONVERTER, - signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[0], USDTPrimeConverterTokenOuts, incentiveAndAccessibilities], - }, - { - target: USDC_PRIME_CONVERTER, - signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[1], USDCPrimeConverterTokenOuts, incentiveAndAccessibilities], - }, - { - target: WBTC_PRIME_CONVERTER, - signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[2], WBTCPrimeConverterTokenOuts, incentiveAndAccessibilities], - }, - { - target: WETH_PRIME_CONVERTER, - signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[3], WETHPrimeConverterTokenOuts, incentiveAndAccessibilities], - }, - { - target: XVS_VAULT_CONVERTER, - signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", - params: [BaseAssets[4], XVSVaultConverterTokenOuts, incentiveAndAccessibilities], - }, + ...setConverterNetworkCommands, ]); }; diff --git a/multisig/simulations/arbitrumsepolia/vip-016/index.ts b/multisig/simulations/arbitrumsepolia/vip-016/index.ts index f99c6d4a7..200bf55b9 100644 --- a/multisig/simulations/arbitrumsepolia/vip-016/index.ts +++ b/multisig/simulations/arbitrumsepolia/vip-016/index.ts @@ -8,10 +8,6 @@ import { initMainnetUser } from "src/utils"; import { forking, pretendExecutingVip } from "src/vip-framework"; import vip016, { - COMPTROLLER_CORE, - PLP, - PROTOCOL_SHARE_RESERVE_PROXY, - VTREASURY, XVS_VAULT_TREASURY, } from "../../../proposals/arbitrumsepolia/vip-016"; import { @@ -34,6 +30,12 @@ const USDT_HOLDER = "0x4e7ab1fD841E1387Df4c91813Ae03819C33D5bdB"; const USDC_HOLDER = "0x4e7ab1fD841E1387Df4c91813Ae03819C33D5bdB"; const USDT = "0xf3118a17863996B9F2A073c9A66Faaa664355cf8"; const USDC = "0x86f096B1D970990091319835faF3Ee011708eAe8"; + +const COMPTROLLER_CORE = "0x006D44b6f5927b3eD83bD0c1C36Fb1A3BaCaC208"; +const PLP = "0xE82c2c10F55D3268126C29ec813dC6F086904694"; +const PROTOCOL_SHARE_RESERVE_PROXY = "0x09267d30798B59c581ce54E861A084C6FC298666"; +const VTREASURY = "0x4e7ab1fD841E1387Df4c91813Ae03819C33D5bdB"; + forking(94312350, async () => { const provider = ethers.provider; let converterNetwork: Contract; diff --git a/simulations/vip-395/arbitrumsepolia.ts b/simulations/vip-395/arbitrumsepolia.ts index bbefc23f9..77b17c2ae 100644 --- a/simulations/vip-395/arbitrumsepolia.ts +++ b/simulations/vip-395/arbitrumsepolia.ts @@ -1,12 +1,27 @@ -import { mine } from "@nomicfoundation/hardhat-network-helpers"; import { expect } from "chai"; -import { Contract } from "ethers"; +import { BigNumber, Contract, Signer } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { expectEvents } from "src/utils"; +import { expectEvents, initMainnetUser } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; import vip015 from "../../multisig/proposals/arbitrumsepolia/vip-015"; +import vip016, { + XVS_VAULT_TREASURY, +} from "../../multisig/proposals/arbitrumsepolia/vip-016"; +import { + CONVERTER_NETWORK, + USDC_PRIME_CONVERTER, + USDT_PRIME_CONVERTER, + XVS_VAULT_CONVERTER, + converters, +} from "../../multisig/proposals/arbitrumsepolia/vip-016/Addresses"; +import CONVERTER_NETWORK_ABI from "../../multisig/simulations/arbitrumsepolia/vip-016/abi/ConverterNetwork.json"; +import ERC20_ABI from "../../multisig/simulations/arbitrumsepolia/vip-016/abi/ERC20.json"; +import PROTOCOL_SHARE_RESERVE_ABI from "../../multisig/simulations/arbitrumsepolia/vip-016/abi/ProtocolShareReserve.json"; +import SINGLE_TOKEN_CONVERTER_ABI from "../../multisig/simulations/arbitrumsepolia/vip-016/abi/SingleTokenConverter.json"; +import XVS_VAULT_TREASURY_ABI from "../../multisig/simulations/arbitrumsepolia/vip-016/abi/XVSVaultTreasury.json"; import vip395, { ARBITRUM_SEPOLIA_COMPTROLLER_CORE, ARBITRUM_SEPOLIA_COMPTROLLER_LST, @@ -26,14 +41,35 @@ import PRIME_ABI from "./abi/Prime.json"; import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; const { arbitrumsepolia } = NETWORK_ADDRESSES; +const XVS = "0x877Dc896e7b13096D3827872e396927BbE704407"; +const XVS_VAULT = "0x407507DC2809D3aa31D54EcA3BEde5C5c4C8A17F"; +const USDT_HOLDER = "0x4e7ab1fD841E1387Df4c91813Ae03819C33D5bdB"; +const USDC_HOLDER = "0x4e7ab1fD841E1387Df4c91813Ae03819C33D5bdB"; +const USDT = "0xf3118a17863996B9F2A073c9A66Faaa664355cf8"; +const USDC = "0x86f096B1D970990091319835faF3Ee011708eAe8"; -forking(95399250, async () => { +const ARBITRUM_SEPOLIA_PROTOCOL_SHARE_RESERVE_PROXY = "0x09267d30798B59c581ce54E861A084C6FC298666"; +const ARBITRUM_SEPOLIA_VTREASURY = "0x4e7ab1fD841E1387Df4c91813Ae03819C33D5bdB"; + +forking(95542429, async () => { const provider = ethers.provider; let prime: Contract; + let converterNetwork: Contract; + let xvsVaultTreasury: Contract; + let protocolShareReserve: Contract; + let usdtPrimeConverter: Contract; + let usdcPrimeConverter: Contract; before(async () => { + usdcPrimeConverter = new ethers.Contract(USDC_PRIME_CONVERTER, SINGLE_TOKEN_CONVERTER_ABI, provider); + usdtPrimeConverter = new ethers.Contract(USDT_PRIME_CONVERTER, SINGLE_TOKEN_CONVERTER_ABI, provider); + + converterNetwork = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); + protocolShareReserve = new ethers.Contract(ARBITRUM_SEPOLIA_PROTOCOL_SHARE_RESERVE_PROXY, PROTOCOL_SHARE_RESERVE_ABI, provider); + xvsVaultTreasury = new ethers.Contract(XVS_VAULT_TREASURY, XVS_VAULT_TREASURY_ABI, provider); + await pretendExecutingVip(await vip015()); - await mine(100); + await pretendExecutingVip(await vip016()); }); describe("Pre-VIP behaviour", () => { @@ -51,6 +87,8 @@ forking(95399250, async () => { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [PRIME_ABI], ["MarketAdded"], [4]); await expectEvents(txResponse, [PRIME_ABI], ["MintLimitsUpdated"], [1]); + await expectEvents(txResponse, [PROTOCOL_SHARE_RESERVE_ABI], ["DistributionConfigAdded"], [6]); + await expectEvents(txResponse, [PROTOCOL_SHARE_RESERVE_ABI], ["DistributionConfigUpdated"], [2]); }, }); @@ -94,4 +132,156 @@ forking(95399250, async () => { expect(await plp.lastAccruedBlockOrSecond(ARBITRUM_SEPOLIA_WBTC)).to.be.gt(0); }); }); + + describe("Owner checks", () => { + it("Timelock should be the owner of all converters", async () => { + for (const converter of converters) { + const Converter = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); + expect(await Converter.owner()).to.equal(arbitrumsepolia.GUARDIAN); + } + }); + + it("Timelock should be the owner of ConverterNetwork", async () => { + expect(await converterNetwork.owner()).to.equal(arbitrumsepolia.GUARDIAN); + }); + + it("Timelock should be the owner of XVSVaultTreasury", async () => { + expect(await xvsVaultTreasury.owner()).to.equal(arbitrumsepolia.GUARDIAN); + }); + }); + + describe("Generic checks", () => { + let usdt: Contract; + let usdc: Contract; + let user1: Signer; + let usdtHolder: Signer; + let usdcHolder: Signer; + let user1Address: string; + + const amount = parseUnits("1000", 6); + + before(async () => { + usdt = new ethers.Contract(USDT, ERC20_ABI, provider); + usdc = new ethers.Contract(USDC, ERC20_ABI, provider); + + [, user1] = await ethers.getSigners(); + user1Address = await user1.getAddress(); + + usdcHolder = await initMainnetUser(USDC_HOLDER, ethers.utils.parseEther("1")); + usdtHolder = await initMainnetUser(USDT_HOLDER, ethers.utils.parseEther("1")); + + await usdt.connect(usdtHolder).transfer(user1Address, amount); + await usdc.connect(usdcHolder).transfer(user1Address, amount); + }); + + it("PSR should have correct distribution configs", async () => { + const percentageDistributionConverters = [500, 500, 300, 700, 2000]; + expect(await protocolShareReserve.totalDistributions()).to.equal(8); + + for (let i = 0; i < 5; i++) { + expect(await protocolShareReserve.getPercentageDistribution(converters[i], 0)).to.equal( + percentageDistributionConverters[i], + ); + } + + expect(await protocolShareReserve.getPercentageDistribution(ARBITRUM_SEPOLIA_VTREASURY, 0)).to.equal(6000); + expect(await protocolShareReserve.getPercentageDistribution(ARBITRUM_SEPOLIA_VTREASURY, 1)).to.equal(8000); + expect(await protocolShareReserve.getPercentageDistribution(XVS_VAULT_CONVERTER, 1)).to.equal(2000); + }); + + it("XVSVaultTreasury should have correct state variables", async () => { + expect(await xvsVaultTreasury.XVS_ADDRESS()).to.equal(XVS); + expect(await xvsVaultTreasury.xvsVault()).to.equal(XVS_VAULT); + }); + + it("ConverterNetwork should contain all converters", async () => { + expect(await converterNetwork.getAllConverters()).to.deep.equal(converters); + }); + + it("Convert exact tokens should work correctly", async () => { + const amountInMantissa = amount.div(2); + await usdt.connect(usdtHolder).transfer(user1Address, amount); + await usdc.connect(usdtHolder).transfer(USDT_PRIME_CONVERTER, amount); + + const usdcBalanceOfUsdtPrimeConverterPrevious = await usdtPrimeConverter.balanceOf(USDC); + const usdtBalanceOfUsdtPrimePrevious = await usdt.balanceOf(ARBITRUM_SEPOLIA_PLP); + const usdtBalanceOfUserPrevious = await usdt.balanceOf(user1Address); + + const [, amountOutMantissa] = await usdtPrimeConverter + .connect(user1) + .callStatic.getUpdatedAmountOut(amountInMantissa, USDT, USDC); + + await usdt.connect(user1).approve(USDT_PRIME_CONVERTER, amountInMantissa); + await usdtPrimeConverter + .connect(user1) + .convertExactTokens(amountInMantissa, amountInMantissa.div(2), USDT, USDC, user1Address); + + expect(await usdt.balanceOf(user1Address)).to.equal(usdtBalanceOfUserPrevious.sub(amountInMantissa)); + expect(await usdtPrimeConverter.balanceOf(USDT)).to.equal(0); + expect(await usdtPrimeConverter.balanceOf(USDC)).to.equal( + usdcBalanceOfUsdtPrimeConverterPrevious.sub(amountOutMantissa), + ); + expect(await usdt.balanceOf(ARBITRUM_SEPOLIA_PLP)).to.equal(BigNumber.from(usdtBalanceOfUsdtPrimePrevious).add(amountInMantissa)); + }); + + it("ConvertForExactTokens should work properly", async () => { + await usdc.connect(usdcHolder).transfer(user1Address, amount); + await usdc.connect(user1).transfer(USDT_PRIME_CONVERTER, amount); + + const amountOutMantissa = amount.div(2); + const amountInMaxMantissa = amount; + await usdt.connect(usdtHolder).transfer(user1Address, amount); + + const usdcBalanceOfUsdtPrimeConverterPrevious = await usdtPrimeConverter.balanceOf(USDC); + const usdtBalanceOfUsdtPrimePrevious = await usdt.balanceOf(ARBITRUM_SEPOLIA_PLP); + const usdtBalanceOfUserPrevious = await usdt.balanceOf(user1Address); + + const [, amountInMantissa] = await usdtPrimeConverter.connect(user1).getAmountIn(amountOutMantissa, USDT, USDC); + + await usdt.connect(user1).approve(USDT_PRIME_CONVERTER, amount); + await usdtPrimeConverter + .connect(user1) + .convertForExactTokens(amountInMaxMantissa, amountOutMantissa, USDT, USDC, user1Address); + + expect(await usdt.balanceOf(user1Address)).to.equal(usdtBalanceOfUserPrevious.sub(amountInMantissa)); + expect(await usdtPrimeConverter.balanceOf(USDT)).to.equal(0); + expect(await usdtPrimeConverter.balanceOf(USDC)).to.equal( + usdcBalanceOfUsdtPrimeConverterPrevious.sub(amountOutMantissa), + ); + expect(await usdt.balanceOf(ARBITRUM_SEPOLIA_PLP)).to.equal(BigNumber.from(usdtBalanceOfUsdtPrimePrevious).add(amountInMantissa)); + }); + + it("Private conversion should occur on updateAssetsState", async () => { + const newAmount = amount.mul(2); + await usdc.connect(usdcHolder).transfer(user1Address, newAmount); + await usdt.connect(usdtHolder).transfer(user1Address, newAmount); + + const destinationAddressForUsdcConverter = await usdcPrimeConverter.destinationAddress(); + + await usdc.connect(user1).transfer(USDT_PRIME_CONVERTER, amount); + await usdtPrimeConverter.connect(user1).updateAssetsState(ARBITRUM_SEPOLIA_COMPTROLLER_CORE, USDC); + + const usdcBalanceUsdtPrimeConverterPrevious = await usdtPrimeConverter.balanceOf(USDC); + const usdtBalanceUsdtPrimePrevious = await usdt.balanceOf(ARBITRUM_SEPOLIA_PLP); + + const plpBalanceForUsdcPrevious = await usdc.balanceOf(destinationAddressForUsdcConverter); + await usdt.connect(user1).transfer(USDC_PRIME_CONVERTER, amount); + + // Private Conversion will occur + await usdcPrimeConverter.connect(user1).updateAssetsState(ARBITRUM_SEPOLIA_COMPTROLLER_CORE, USDT); + + const usdcBalanceUsdtPrimeConverterCurrent = await usdtPrimeConverter.balanceOf(USDC); + const usdtBalanceUsdtPrimeCurrent = await usdt.balanceOf(ARBITRUM_SEPOLIA_PLP); + + expect(usdtBalanceUsdtPrimeCurrent).to.equal(usdtBalanceUsdtPrimePrevious.add(amount)); + expect(usdcBalanceUsdtPrimeConverterCurrent).to.closeTo( + usdcBalanceUsdtPrimeConverterPrevious.sub(amount), + parseUnits("1", 7), + ); + expect(await usdc.balanceOf(destinationAddressForUsdcConverter)).to.closeTo( + plpBalanceForUsdcPrevious.add(amount), + parseUnits("1", 7), + ); + }); + }); }); diff --git a/vips/vip-395/bsctestnet.ts b/vips/vip-395/bsctestnet.ts index 521d200a9..4f510d8f0 100644 --- a/vips/vip-395/bsctestnet.ts +++ b/vips/vip-395/bsctestnet.ts @@ -1,7 +1,30 @@ import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { LzChainId, ProposalType } from "src/types"; import { makeProposal } from "src/utils"; +import { + ACM, + BaseAssets, + CONVERTER_NETWORK, + USDCPrimeConverterTokenOuts, + USDC_PRIME_CONVERTER, + USDTPrimeConverterTokenOuts, + USDT_PRIME_CONVERTER, + WBTCPrimeConverterTokenOuts, + WBTC_PRIME_CONVERTER, + WETHPrimeConverterTokenOuts, + WETH_PRIME_CONVERTER, + XVSVaultConverterTokenOuts, + XVS_VAULT_CONVERTER, +} from "../../multisig/proposals/arbitrumsepolia/vip-016/Addresses"; +import { + addConverterNetworkCommands, + incentiveAndAccessibilities, +} from "../../multisig/proposals/arbitrumsepolia/vip-016/commands"; + +const { arbitrumsepolia } = NETWORK_ADDRESSES; + export const OMNICHAIN_PROPOSAL_SENDER = "0xCfD34AEB46b1CB4779c945854d405E91D27A1899"; export const ARBITRUM_SEPOLIA_COMPTROLLER_CORE = "0x006D44b6f5927b3eD83bD0c1C36Fb1A3BaCaC208"; @@ -22,6 +45,10 @@ export const ARBITRUM_SEPOLIA_VUSDC_CORE = "0xd9d1e754464eFc7493B177d2c7be04816E export const ARBITRUM_SEPOLIA_VWBTC_CORE = "0x49FB90A5815904649C44B87001a160C1301D6a2C"; export const ARBITRUM_SEPOLIA_VWETH_LST = "0xd7057250b439c0849377bB6C3263eb8f9cf49d98"; +export const ARBITRUM_SEPOLIA_XVS_VAULT_TREASURY = "0x309b71a417dA9CfA8aC47e6038000B1739d9A3A6"; +export const ARBITRUM_SEPOLIA_PROTOCOL_SHARE_RESERVE_PROXY = "0x09267d30798B59c581ce54E861A084C6FC298666"; +export const ARBITRUM_SEPOLIA_VTREASURY = "0x4e7ab1fD841E1387Df4c91813Ae03819C33D5bdB"; + export const MAX_DAILY_LIMIT = 100; const vip395 = () => { @@ -98,6 +125,72 @@ const vip395 = () => { ], dstChainId: LzChainId.arbitrumsepolia, }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [CONVERTER_NETWORK, "addTokenConverter(address)", arbitrumsepolia.NORMAL_TIMELOCK], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [CONVERTER_NETWORK, "removeTokenConverter(address)", arbitrumsepolia.NORMAL_TIMELOCK], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [ARBITRUM_SEPOLIA_XVS_VAULT_TREASURY, "fundXVSVault(uint256)", arbitrumsepolia.NORMAL_TIMELOCK], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: ARBITRUM_SEPOLIA_PROTOCOL_SHARE_RESERVE_PROXY, + signature: "addOrUpdateDistributionConfigs((uint8,uint16,address)[])", + params: [ + [ + [0, 6000, ARBITRUM_SEPOLIA_VTREASURY], + [0, 2000, XVS_VAULT_CONVERTER], + [0, 500, USDC_PRIME_CONVERTER], // 25% of the Prime allocation + [0, 500, USDT_PRIME_CONVERTER], // 25% of the Prime allocation + [0, 300, WBTC_PRIME_CONVERTER], // 15% of the Prime allocation + [0, 700, WETH_PRIME_CONVERTER], // 35% of the Prime allocation + [1, 8000, ARBITRUM_SEPOLIA_VTREASURY], + [1, 2000, XVS_VAULT_CONVERTER], + ], + ], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: USDT_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[0], USDTPrimeConverterTokenOuts, incentiveAndAccessibilities], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: USDC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[1], USDCPrimeConverterTokenOuts, incentiveAndAccessibilities], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: WBTC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[2], WBTCPrimeConverterTokenOuts, incentiveAndAccessibilities], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: WETH_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[3], WETHPrimeConverterTokenOuts, incentiveAndAccessibilities], + dstChainId: LzChainId.arbitrumsepolia, + }, + { + target: XVS_VAULT_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[4], XVSVaultConverterTokenOuts, incentiveAndAccessibilities], + dstChainId: LzChainId.arbitrumsepolia, + }, + ...addConverterNetworkCommands, ], meta, ProposalType.REGULAR, From 48c684fab11e6308dc996d060a5199b4aef44ed5 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Fri, 8 Nov 2024 21:18:59 +0530 Subject: [PATCH 131/178] fix: lint issues --- .../proposals/arbitrumsepolia/vip-016/index.ts | 4 +--- .../arbitrumsepolia/vip-016/index.ts | 4 +--- simulations/vip-395/arbitrumsepolia.ts | 18 ++++++++++++------ 3 files changed, 14 insertions(+), 12 deletions(-) diff --git a/multisig/proposals/arbitrumsepolia/vip-016/index.ts b/multisig/proposals/arbitrumsepolia/vip-016/index.ts index efc673552..66373e477 100644 --- a/multisig/proposals/arbitrumsepolia/vip-016/index.ts +++ b/multisig/proposals/arbitrumsepolia/vip-016/index.ts @@ -1,8 +1,6 @@ import { makeProposal } from "src/utils"; -import { - CONVERTER_NETWORK, -} from "./Addresses"; +import { CONVERTER_NETWORK } from "./Addresses"; import { acceptOwnershipCommandsAllConverters, callPermissionCommandsAllConverter, diff --git a/multisig/simulations/arbitrumsepolia/vip-016/index.ts b/multisig/simulations/arbitrumsepolia/vip-016/index.ts index 200bf55b9..2c34e2945 100644 --- a/multisig/simulations/arbitrumsepolia/vip-016/index.ts +++ b/multisig/simulations/arbitrumsepolia/vip-016/index.ts @@ -7,9 +7,7 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { initMainnetUser } from "src/utils"; import { forking, pretendExecutingVip } from "src/vip-framework"; -import vip016, { - XVS_VAULT_TREASURY, -} from "../../../proposals/arbitrumsepolia/vip-016"; +import vip016, { XVS_VAULT_TREASURY } from "../../../proposals/arbitrumsepolia/vip-016"; import { CONVERTER_NETWORK, USDC_PRIME_CONVERTER, diff --git a/simulations/vip-395/arbitrumsepolia.ts b/simulations/vip-395/arbitrumsepolia.ts index 77b17c2ae..56a23138a 100644 --- a/simulations/vip-395/arbitrumsepolia.ts +++ b/simulations/vip-395/arbitrumsepolia.ts @@ -7,9 +7,7 @@ import { expectEvents, initMainnetUser } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; import vip015 from "../../multisig/proposals/arbitrumsepolia/vip-015"; -import vip016, { - XVS_VAULT_TREASURY, -} from "../../multisig/proposals/arbitrumsepolia/vip-016"; +import vip016, { XVS_VAULT_TREASURY } from "../../multisig/proposals/arbitrumsepolia/vip-016"; import { CONVERTER_NETWORK, USDC_PRIME_CONVERTER, @@ -65,7 +63,11 @@ forking(95542429, async () => { usdtPrimeConverter = new ethers.Contract(USDT_PRIME_CONVERTER, SINGLE_TOKEN_CONVERTER_ABI, provider); converterNetwork = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); - protocolShareReserve = new ethers.Contract(ARBITRUM_SEPOLIA_PROTOCOL_SHARE_RESERVE_PROXY, PROTOCOL_SHARE_RESERVE_ABI, provider); + protocolShareReserve = new ethers.Contract( + ARBITRUM_SEPOLIA_PROTOCOL_SHARE_RESERVE_PROXY, + PROTOCOL_SHARE_RESERVE_ABI, + provider, + ); xvsVaultTreasury = new ethers.Contract(XVS_VAULT_TREASURY, XVS_VAULT_TREASURY_ABI, provider); await pretendExecutingVip(await vip015()); @@ -221,7 +223,9 @@ forking(95542429, async () => { expect(await usdtPrimeConverter.balanceOf(USDC)).to.equal( usdcBalanceOfUsdtPrimeConverterPrevious.sub(amountOutMantissa), ); - expect(await usdt.balanceOf(ARBITRUM_SEPOLIA_PLP)).to.equal(BigNumber.from(usdtBalanceOfUsdtPrimePrevious).add(amountInMantissa)); + expect(await usdt.balanceOf(ARBITRUM_SEPOLIA_PLP)).to.equal( + BigNumber.from(usdtBalanceOfUsdtPrimePrevious).add(amountInMantissa), + ); }); it("ConvertForExactTokens should work properly", async () => { @@ -248,7 +252,9 @@ forking(95542429, async () => { expect(await usdtPrimeConverter.balanceOf(USDC)).to.equal( usdcBalanceOfUsdtPrimeConverterPrevious.sub(amountOutMantissa), ); - expect(await usdt.balanceOf(ARBITRUM_SEPOLIA_PLP)).to.equal(BigNumber.from(usdtBalanceOfUsdtPrimePrevious).add(amountInMantissa)); + expect(await usdt.balanceOf(ARBITRUM_SEPOLIA_PLP)).to.equal( + BigNumber.from(usdtBalanceOfUsdtPrimePrevious).add(amountInMantissa), + ); }); it("Private conversion should occur on updateAssetsState", async () => { From 4f75a57a7f2823e20662e67f2c7d6e42e459eb6e Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Mon, 11 Nov 2024 09:46:48 +0530 Subject: [PATCH 132/178] refactor: file structure --- .../proposals/zksyncmainnet/{vip-015 => vip-016}/index.ts | 4 ++-- .../{vip-015 => vip-016}/abi/AccessControlManagerAbi.json | 0 .../simulations/zksyncmainnet/{vip-015 => vip-016}/index.ts | 4 ++-- simulations/vip-395/zksyncmainnet.ts | 4 ++-- 4 files changed, 6 insertions(+), 6 deletions(-) rename multisig/proposals/zksyncmainnet/{vip-015 => vip-016}/index.ts (90%) rename multisig/simulations/zksyncmainnet/{vip-015 => vip-016}/abi/AccessControlManagerAbi.json (100%) rename multisig/simulations/zksyncmainnet/{vip-015 => vip-016}/index.ts (86%) diff --git a/multisig/proposals/zksyncmainnet/vip-015/index.ts b/multisig/proposals/zksyncmainnet/vip-016/index.ts similarity index 90% rename from multisig/proposals/zksyncmainnet/vip-015/index.ts rename to multisig/proposals/zksyncmainnet/vip-016/index.ts index dabf25128..083039089 100644 --- a/multisig/proposals/zksyncmainnet/vip-015/index.ts +++ b/multisig/proposals/zksyncmainnet/vip-016/index.ts @@ -4,7 +4,7 @@ export const ZKSYNCMAINNET_ACM = "0x526159A92A82afE5327d37Ef446b68FD9a5cA914"; export const ZKSYNCMAINNET_NORMAL_TIMELOCK = "0x093565Bc20AA326F4209eBaF3a26089272627613"; const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; -export const vip015 = () => { +export const vip016 = () => { return makeProposal([ { target: ZKSYNCMAINNET_ACM, @@ -13,4 +13,4 @@ export const vip015 = () => { }, ]); }; -export default vip015; +export default vip016; diff --git a/multisig/simulations/zksyncmainnet/vip-015/abi/AccessControlManagerAbi.json b/multisig/simulations/zksyncmainnet/vip-016/abi/AccessControlManagerAbi.json similarity index 100% rename from multisig/simulations/zksyncmainnet/vip-015/abi/AccessControlManagerAbi.json rename to multisig/simulations/zksyncmainnet/vip-016/abi/AccessControlManagerAbi.json diff --git a/multisig/simulations/zksyncmainnet/vip-015/index.ts b/multisig/simulations/zksyncmainnet/vip-016/index.ts similarity index 86% rename from multisig/simulations/zksyncmainnet/vip-015/index.ts rename to multisig/simulations/zksyncmainnet/vip-016/index.ts index 4ff684e5d..e68e6867b 100644 --- a/multisig/simulations/zksyncmainnet/vip-015/index.ts +++ b/multisig/simulations/zksyncmainnet/vip-016/index.ts @@ -3,7 +3,7 @@ import { Contract } from "ethers"; import { ethers } from "hardhat"; import { forking, pretendExecutingVip } from "src/vip-framework"; -import vip015, { ZKSYNCMAINNET_ACM, ZKSYNCMAINNET_NORMAL_TIMELOCK } from "../../../proposals/zksyncmainnet/vip-015"; +import vip016, { ZKSYNCMAINNET_ACM, ZKSYNCMAINNET_NORMAL_TIMELOCK } from "../../../proposals/zksyncmainnet/vip-016"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManagerAbi.json"; forking(48280698, async () => { @@ -21,7 +21,7 @@ forking(48280698, async () => { }); describe("Post-VIP behavior", async () => { before(async () => { - await pretendExecutingVip(await vip015()); + await pretendExecutingVip(await vip016()); }); it("Normal Timelock has default admin role", async () => { const hasRole = await acm.hasRole(defaultAdminRole, ZKSYNCMAINNET_NORMAL_TIMELOCK); diff --git a/simulations/vip-395/zksyncmainnet.ts b/simulations/vip-395/zksyncmainnet.ts index 5138a5d13..117672d8e 100644 --- a/simulations/vip-395/zksyncmainnet.ts +++ b/simulations/vip-395/zksyncmainnet.ts @@ -6,7 +6,7 @@ import { LzChainId } from "src/types"; import { expectEvents, getOmnichainProposalSenderAddress } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip015 from "../../multisig/proposals/zksyncmainnet/vip-015"; +import vip016 from "../../multisig/proposals/zksyncmainnet/vip-016"; import vip395, { DEFAULT_ADMIN_ROLE, ZKSYNCMAINNET_ACM, @@ -36,7 +36,7 @@ forking(48280698, async () => { ); executorOwner = new ethers.Contract(ZKSYNCMAINNET_OMNICHAIN_EXECUTOR_OWNER, OMNICHAIN_EXECUTOR_OWNER_ABI, provider); lastProposalReceived = await executor.lastProposalReceived(); - await pretendExecutingVip(await vip015()); + await pretendExecutingVip(await vip016()); }); describe("Pre-VIP behaviour", async () => { From 7f931d4fb3f2067b6a1d9eddce899951ed23d93c Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Mon, 11 Nov 2024 10:23:09 +0530 Subject: [PATCH 133/178] fix: zksync test node set up --- hardhat.config.zksync.ts | 2 +- src/vip-framework/index.ts | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/hardhat.config.zksync.ts b/hardhat.config.zksync.ts index d7f186b2a..891d648f3 100644 --- a/hardhat.config.zksync.ts +++ b/hardhat.config.zksync.ts @@ -149,7 +149,7 @@ const config: HardhatUserConfig = { }, zksynctestnode: { url: process.env.ZKSYNC_ERA_LOCAL_TEST_NODE || "http://localhost:8011", - chainId: 260, + chainId: 324, // change it to 300 for zksyncsepolia accounts: DEPLOYER_PRIVATE_KEY ? [`0x${DEPLOYER_PRIVATE_KEY}`] : [], blockGasLimit: BLOCK_GAS_LIMIT_PER_NETWORK.zksyncsepolia, timeout: 2000000000, diff --git a/src/vip-framework/index.ts b/src/vip-framework/index.ts index 6773a1f3b..15e138e8a 100644 --- a/src/vip-framework/index.ts +++ b/src/vip-framework/index.ts @@ -270,6 +270,8 @@ export const testForkedNetworkVipCommands = (description: string, proposal: Prop it("should be executed successfully", async () => { if (FORKED_NETWORK == "zksyncsepolia" || FORKED_NETWORK == "zksyncmainnet") { await mineOnZksync(DELAY_BLOCKS[proposalType]); + const [signer] = await ethers.getSigners(); + await initMainnetUser(signer.address, ethers.utils.parseEther("2")); } else { await mine(DELAY_BLOCKS[proposalType]); } From 2f79418fa6235c4d037a1f7449316e5490b2a4cb Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Mon, 11 Nov 2024 08:05:09 +0300 Subject: [PATCH 134/178] fixup! chore: upgrade hardhat to support new eth opcodes --- hardhat.config.ts | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/hardhat.config.ts b/hardhat.config.ts index 2351f5c96..b924e1767 100644 --- a/hardhat.config.ts +++ b/hardhat.config.ts @@ -95,12 +95,32 @@ task("test", "Update fork config") await runSuper(taskArguments); }); +// Pretend that Cancun hardfork was activated at block 0 +const assumeCancun = { + hardforkHistory: { + cancun: 0, + }, +}; + const config: HardhatUserConfig = { defaultNetwork: "hardhat", networks: { hardhat: { allowUnlimitedContractSize: true, loggingEnabled: false, + // Forking networks with unknown hardfork activation history causes errors in + // new versions of Hardhat. Following https://github.com/NomicFoundation/hardhat/pull/5394, + // we assume Cancun hardfork was active from the beginning for all unknown chains + chains: { + 56: assumeCancun, + 97: assumeCancun, + 5611: assumeCancun, + 204: assumeCancun, + 421614: assumeCancun, + 42161: assumeCancun, + 11155420: assumeCancun, + 10: assumeCancun, + }, }, bsctestnet: { url: process.env.ARCHIVE_NODE_bsctestnet || "https://data-seed-prebsc-1-s1.binance.org:8545", From c923e3f1d62e339505a1e11f0845bd4ee7beb61b Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Mon, 11 Nov 2024 12:08:51 +0530 Subject: [PATCH 135/178] fix: typo in simulations Co-authored-by: Jesus Lanchas --- simulations/vip-395/opmainnet.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/simulations/vip-395/opmainnet.ts b/simulations/vip-395/opmainnet.ts index c04bd2607..f288b43f8 100644 --- a/simulations/vip-395/opmainnet.ts +++ b/simulations/vip-395/opmainnet.ts @@ -40,7 +40,7 @@ forking(127735654, async () => { }); describe("Pre-VIP behaviour", async () => { - it("Normal Timelock has default admin role on ZKsync mainnet", async () => { + it("Normal Timelock has default admin role on OP mainnet", async () => { const acm = await ethers.getContractAt(ACCESS_CONTROL_MANAGER_ABI, OP_MAINNET_ACM); const hasRole = await acm.hasRole(DEFAULT_ADMIN_ROLE, opmainnet.NORMAL_TIMELOCK); expect(hasRole).equals(true); From 5dad6d69ab2570614d1e077cfa3269cb5e946460 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Mon, 11 Nov 2024 12:09:40 +0530 Subject: [PATCH 136/178] fix: typo in simulations Co-authored-by: Jesus Lanchas --- simulations/vip-395/opmainnet.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/simulations/vip-395/opmainnet.ts b/simulations/vip-395/opmainnet.ts index f288b43f8..3965f4796 100644 --- a/simulations/vip-395/opmainnet.ts +++ b/simulations/vip-395/opmainnet.ts @@ -110,7 +110,7 @@ forking(127735654, async () => { expect(await executorOwner.functionRegistry(selector)).equals(signature); } }); - it("Default admin role must be revoked from ACMAggregator contract on ZKsync mainnet", async () => { + it("Default admin role must be revoked from ACMAggregator contract on OP mainnet", async () => { expect(await acm.hasRole(DEFAULT_ADMIN_ROLE, OP_MAINNET_ACM_AGGREGATOR)).to.be.false; }); it("Guardian and all timelocks are allowed to call retryMessage ", async () => { From 98c6e096eab32fa029b73cd75209b843f49d6580 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Mon, 11 Nov 2024 12:16:04 +0530 Subject: [PATCH 137/178] fix: add missing networks in types.ts --- src/types.ts | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/types.ts b/src/types.ts index 82882d688..85eed8884 100644 --- a/src/types.ts +++ b/src/types.ts @@ -7,7 +7,10 @@ export type SUPPORTED_NETWORKS = | "ethereum" | "opbnbtestnet" | "opbnbmainnet" - | "zksyncsepolia"; + | "zksyncsepolia" + | "zksyncmainnet" + | "opsepolia" + | "opmainnet"; export type REMOTE_NETWORKS = | "sepolia" @@ -16,7 +19,10 @@ export type REMOTE_NETWORKS = | "opbnbmainnet" | "arbitrumsepolia" | "arbitrumone" - | "zksyncsepolia"; + | "zksyncsepolia" + | "zksyncmainnet" + | "opsepolia" + | "opmainnet"; export const REMOTE_TESTNET_NETWORKS = ["sepolia", "opbnbtestnet", "arbitrumsepolia", "zksyncsepolia", "opsepolia"]; export const REMOTE_MAINNET_NETWORKS = ["ethereum", "opbnbmainnet", "arbitrumone", "zksyncmainnet", "opmainnet"]; From 92681fe7498fb4e91d4b904a051fe05fb2900bd6 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Mon, 11 Nov 2024 16:01:22 +0530 Subject: [PATCH 138/178] refactor: remove unwanted command --- simulations/vip-395/arbitrumsepolia.ts | 2 +- vips/vip-395/bsctestnet.ts | 9 --------- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/simulations/vip-395/arbitrumsepolia.ts b/simulations/vip-395/arbitrumsepolia.ts index 56a23138a..38a41c0e1 100644 --- a/simulations/vip-395/arbitrumsepolia.ts +++ b/simulations/vip-395/arbitrumsepolia.ts @@ -49,7 +49,7 @@ const USDC = "0x86f096B1D970990091319835faF3Ee011708eAe8"; const ARBITRUM_SEPOLIA_PROTOCOL_SHARE_RESERVE_PROXY = "0x09267d30798B59c581ce54E861A084C6FC298666"; const ARBITRUM_SEPOLIA_VTREASURY = "0x4e7ab1fD841E1387Df4c91813Ae03819C33D5bdB"; -forking(95542429, async () => { +forking(96329874, async () => { const provider = ethers.provider; let prime: Contract; let converterNetwork: Contract; diff --git a/vips/vip-395/bsctestnet.ts b/vips/vip-395/bsctestnet.ts index 4f510d8f0..6c65473b3 100644 --- a/vips/vip-395/bsctestnet.ts +++ b/vips/vip-395/bsctestnet.ts @@ -63,15 +63,6 @@ const vip395 = () => { }; return makeProposal( [ - { - target: ARBITRUM_SEPOLIA_PLP, - signature: "setTokensDistributionSpeed(address[],uint256[])", - params: [ - [ARBITRUM_SEPOLIA_WETH, ARBITRUM_SEPOLIA_WBTC, ARBITRUM_SEPOLIA_USDC, ARBITRUM_SEPOLIA_USDT], - [0, 0, 0, 0], - ], - dstChainId: LzChainId.arbitrumsepolia, - }, { target: ARBITRUM_SEPOLIA_PRIME, signature: "addMarket(address,address,uint256,uint256)", From e02b0de00cb911cd9c1b03cf6f8a23a5fb4ba9e5 Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Mon, 11 Nov 2024 20:00:40 +0300 Subject: [PATCH 139/178] fixup! chore: upgrade hardhat to support new eth opcodes --- hardhat.config.ts | 36 +++++++++++++++++++----------------- hardhat.config.zksync.ts | 13 +++++++++++++ src/chains.ts | 15 +++++++++++++++ 3 files changed, 47 insertions(+), 17 deletions(-) create mode 100644 src/chains.ts diff --git a/hardhat.config.ts b/hardhat.config.ts index b924e1767..afeb30266 100644 --- a/hardhat.config.ts +++ b/hardhat.config.ts @@ -5,6 +5,7 @@ import "@nomiclabs/hardhat-ethers"; import * as dotenv from "dotenv"; import { ethers } from "ethers"; import { HardhatUserConfig, task } from "hardhat/config"; +import { ChainId } from "src/chains"; import "./type-extensions"; @@ -112,19 +113,19 @@ const config: HardhatUserConfig = { // new versions of Hardhat. Following https://github.com/NomicFoundation/hardhat/pull/5394, // we assume Cancun hardfork was active from the beginning for all unknown chains chains: { - 56: assumeCancun, - 97: assumeCancun, - 5611: assumeCancun, - 204: assumeCancun, - 421614: assumeCancun, - 42161: assumeCancun, - 11155420: assumeCancun, - 10: assumeCancun, + [ChainId.bscmainnet]: assumeCancun, + [ChainId.bsctestnet]: assumeCancun, + [ChainId.opbnbtestnet]: assumeCancun, + [ChainId.opbnbmainnet]: assumeCancun, + [ChainId.arbitrumsepolia]: assumeCancun, + [ChainId.arbitrumone]: assumeCancun, + [ChainId.opsepolia]: assumeCancun, + [ChainId.opmainnet]: assumeCancun, }, }, bsctestnet: { url: process.env.ARCHIVE_NODE_bsctestnet || "https://data-seed-prebsc-1-s1.binance.org:8545", - chainId: 97, + chainId: ChainId.bsctestnet, accounts: DEPLOYER_PRIVATE_KEY ? [`0x${DEPLOYER_PRIVATE_KEY}`] : [], gasPrice: ethers.utils.parseUnits("10", "gwei").toNumber(), gasMultiplier: 10, @@ -133,52 +134,53 @@ const config: HardhatUserConfig = { }, bscmainnet: { url: process.env.ARCHIVE_NODE_bscmainnet || "https://bsc-dataseed.binance.org/", + chainId: ChainId.bscmainnet, accounts: DEPLOYER_PRIVATE_KEY ? [`0x${DEPLOYER_PRIVATE_KEY}`] : [], blockGasLimit: BLOCK_GAS_LIMIT_PER_NETWORK.bscmainnet, }, sepolia: { url: process.env.ARCHIVE_NODE_sepolia || "https://ethereum-sepolia.blockpi.network/v1/rpc/public", - chainId: 11155111, + chainId: ChainId.sepolia, accounts: DEPLOYER_PRIVATE_KEY ? [`0x${DEPLOYER_PRIVATE_KEY}`] : [], blockGasLimit: BLOCK_GAS_LIMIT_PER_NETWORK.sepolia, }, ethereum: { url: process.env.ARCHIVE_NODE_ethereum || "https://ethereum.blockpi.network/v1/rpc/public", - chainId: 1, + chainId: ChainId.ethereum, accounts: DEPLOYER_PRIVATE_KEY ? [`0x${DEPLOYER_PRIVATE_KEY}`] : [], blockGasLimit: BLOCK_GAS_LIMIT_PER_NETWORK.ethereum, }, opbnbtestnet: { url: process.env.ARCHIVE_NODE_opbnbtestnet || "https://opbnb-testnet-rpc.bnbchain.org", - chainId: 5611, + chainId: ChainId.opbnbtestnet, accounts: DEPLOYER_PRIVATE_KEY ? [`0x${DEPLOYER_PRIVATE_KEY}`] : [], blockGasLimit: BLOCK_GAS_LIMIT_PER_NETWORK.opbnbtestnet, }, opbnbmainnet: { url: process.env.ARCHIVE_NODE_opbnbmainnet || "https://opbnb-mainnet-rpc.bnbchain.org", - chainId: 204, + chainId: ChainId.opbnbmainnet, accounts: DEPLOYER_PRIVATE_KEY ? [`0x${DEPLOYER_PRIVATE_KEY}`] : [], blockGasLimit: BLOCK_GAS_LIMIT_PER_NETWORK.opbnbmainnet, }, arbitrumsepolia: { url: process.env.ARCHIVE_NODE_arbitrumsepolia || "https://sepolia-rollup.arbitrum.io/rpc", - chainId: 421614, + chainId: ChainId.arbitrumsepolia, accounts: DEPLOYER_PRIVATE_KEY ? [`0x${DEPLOYER_PRIVATE_KEY}`] : [], }, arbitrumone: { url: process.env.ARCHIVE_NODE_arbitrumone || "https://arb1.arbitrum.io/rpc", - chainId: 42161, + chainId: ChainId.arbitrumone, accounts: DEPLOYER_PRIVATE_KEY ? [`0x${DEPLOYER_PRIVATE_KEY}`] : [], }, opsepolia: { url: process.env.ARCHIVE_NODE_opsepolia || "https://sepolia.optimism.io", - chainId: 11155420, + chainId: ChainId.opsepolia, accounts: DEPLOYER_PRIVATE_KEY ? [`0x${DEPLOYER_PRIVATE_KEY}`] : [], blockGasLimit: BLOCK_GAS_LIMIT_PER_NETWORK.opsepolia, }, opmainnet: { url: process.env.ARCHIVE_NODE_opmainnet || "https://mainnet.optimism.io", - chainId: 10, + chainId: ChainId.opmainnet, accounts: DEPLOYER_PRIVATE_KEY ? [`0x${DEPLOYER_PRIVATE_KEY}`] : [], blockGasLimit: BLOCK_GAS_LIMIT_PER_NETWORK.opmainnet, }, diff --git a/hardhat.config.zksync.ts b/hardhat.config.zksync.ts index be1385f8d..7b10bb138 100644 --- a/hardhat.config.zksync.ts +++ b/hardhat.config.zksync.ts @@ -7,6 +7,7 @@ import "@nomicfoundation/hardhat-chai-matchers"; import "@nomiclabs/hardhat-ethers"; import * as dotenv from "dotenv"; import { HardhatUserConfig, task } from "hardhat/config"; +import { ChainId } from "src/chains"; import "./type-extensions"; @@ -94,6 +95,13 @@ task("test", "Update fork config") await runSuper(taskArguments); }); +// Pretend that Cancun hardfork was activated at block 0 +const assumeCancun = { + hardforkHistory: { + cancun: 0, + }, +}; + const config: HardhatUserConfig = { defaultNetwork: "hardhat", zksolc: { @@ -132,6 +140,11 @@ const config: HardhatUserConfig = { allowUnlimitedContractSize: true, loggingEnabled: false, zksync: true, + chains: { + [ChainId.zksyncmainnet]: assumeCancun, + [ChainId.zksyncsepolia]: assumeCancun, + [ChainId.zkSyncTestNode]: assumeCancun, + }, }, zksyncsepolia: { url: process.env.ARCHIVE_NODE_zksyncsepolia || "https://sepolia.era.zksync.dev", diff --git a/src/chains.ts b/src/chains.ts new file mode 100644 index 000000000..162466162 --- /dev/null +++ b/src/chains.ts @@ -0,0 +1,15 @@ +export enum ChainId { + ethereum = 1, + sepolia = 11155111, + bscmainnet = 56, + bsctestnet = 97, + opbnbtestnet = 5611, + opbnbmainnet = 204, + arbitrumsepolia = 421614, + arbitrumone = 42161, + opsepolia = 11155420, + opmainnet = 10, + zksyncsepolia = 300, + zksyncmainnet = 324, + zkSyncTestNode = 260, +} From fb59bccf8e3dbab48b29d2757f3a849eb4c5a4db Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Mon, 11 Nov 2024 20:28:21 +0300 Subject: [PATCH 140/178] fixup! feat: add mainnet VIP for pufETH --- .../ethereum/{vip-100 => vip-070}/index.ts | 4 +- .../sepolia/{vip-100 => vip-070}/index.ts | 4 +- .../{vip-100 => vip-070}/abi/erc20.json | 0 .../ethereum/{vip-100 => vip-070}/index.ts | 4 +- .../abi/PoolRegistry.json | 0 .../abi/ResilientOracle.json | 0 .../{vip-100 => vip-070}/abi/comptroller.json | 0 .../{vip-100 => vip-070}/abi/erc20.json | 0 .../{vip-100 => vip-070}/abi/vToken.json | 0 .../{vip-100 => vip-070}/abi/weth.json | 0 .../sepolia/{vip-100 => vip-070}/index.ts | 4 +- .../abi/OmnichainProposalSender.json | 0 .../abi/PoolRegistry.json | 0 .../abi/ResilientOracle.json | 0 .../abi/SingleTokenConverter.json | 0 .../{vip-400 => vip-395}/abi/comptroller.json | 0 .../{vip-400 => vip-395}/abi/vToken.json | 0 .../{vip-400 => vip-395}/abi/weth.json | 0 .../{vip-400 => vip-395}/bscmainnet.ts | 4 +- simulations/{vip-400 => vip-395}/ethereum.ts | 12 ++-- vips/{vip-400 => vip-395}/bscmainnet.ts | 64 +++++++++++++++++-- 21 files changed, 73 insertions(+), 23 deletions(-) rename multisig/proposals/ethereum/{vip-100 => vip-070}/index.ts (91%) rename multisig/proposals/sepolia/{vip-100 => vip-070}/index.ts (98%) rename multisig/simulations/ethereum/{vip-100 => vip-070}/abi/erc20.json (100%) rename multisig/simulations/ethereum/{vip-100 => vip-070}/index.ts (86%) rename multisig/simulations/sepolia/{vip-100 => vip-070}/abi/PoolRegistry.json (100%) rename multisig/simulations/sepolia/{vip-100 => vip-070}/abi/ResilientOracle.json (100%) rename multisig/simulations/sepolia/{vip-100 => vip-070}/abi/comptroller.json (100%) rename multisig/simulations/sepolia/{vip-100 => vip-070}/abi/erc20.json (100%) rename multisig/simulations/sepolia/{vip-100 => vip-070}/abi/vToken.json (100%) rename multisig/simulations/sepolia/{vip-100 => vip-070}/abi/weth.json (100%) rename multisig/simulations/sepolia/{vip-100 => vip-070}/index.ts (97%) rename simulations/{vip-400 => vip-395}/abi/OmnichainProposalSender.json (100%) rename simulations/{vip-400 => vip-395}/abi/PoolRegistry.json (100%) rename simulations/{vip-400 => vip-395}/abi/ResilientOracle.json (100%) rename simulations/{vip-400 => vip-395}/abi/SingleTokenConverter.json (100%) rename simulations/{vip-400 => vip-395}/abi/comptroller.json (100%) rename simulations/{vip-400 => vip-395}/abi/vToken.json (100%) rename simulations/{vip-400 => vip-395}/abi/weth.json (100%) rename simulations/{vip-400 => vip-395}/bscmainnet.ts (83%) rename simulations/{vip-400 => vip-395}/ethereum.ts (95%) rename vips/{vip-400 => vip-395}/bscmainnet.ts (61%) diff --git a/multisig/proposals/ethereum/vip-100/index.ts b/multisig/proposals/ethereum/vip-070/index.ts similarity index 91% rename from multisig/proposals/ethereum/vip-100/index.ts rename to multisig/proposals/ethereum/vip-070/index.ts index 135fdd49b..32154a0ec 100644 --- a/multisig/proposals/ethereum/vip-100/index.ts +++ b/multisig/proposals/ethereum/vip-070/index.ts @@ -8,7 +8,7 @@ const { VTREASURY, NORMAL_TIMELOCK } = NETWORK_ADDRESSES.ethereum; export const PUFETH = "0xD9A442856C234a39a81a089C06451EBAa4306a72"; const INITIAL_SUPPLY = parseUnits("5", 18); -export const vip100 = () => { +export const vip070 = () => { return makeProposal([ { target: VTREASURY, @@ -18,4 +18,4 @@ export const vip100 = () => { ]); }; -export default vip100; +export default vip070; diff --git a/multisig/proposals/sepolia/vip-100/index.ts b/multisig/proposals/sepolia/vip-070/index.ts similarity index 98% rename from multisig/proposals/sepolia/vip-100/index.ts rename to multisig/proposals/sepolia/vip-070/index.ts index 7ffff9a6f..905f58abe 100644 --- a/multisig/proposals/sepolia/vip-100/index.ts +++ b/multisig/proposals/sepolia/vip-070/index.ts @@ -49,7 +49,7 @@ export const marketSpec = { const pufETH_ONE_JUMP_REDSTONE_ORACLE = "0xB6aA35247097a2711CF4941DECD00b858124d959"; -export const vip100 = () => { +export const vip070 = () => { return makeProposal([ // Configure Oracle { @@ -113,4 +113,4 @@ export const vip100 = () => { ]); }; -export default vip100; +export default vip070; diff --git a/multisig/simulations/ethereum/vip-100/abi/erc20.json b/multisig/simulations/ethereum/vip-070/abi/erc20.json similarity index 100% rename from multisig/simulations/ethereum/vip-100/abi/erc20.json rename to multisig/simulations/ethereum/vip-070/abi/erc20.json diff --git a/multisig/simulations/ethereum/vip-100/index.ts b/multisig/simulations/ethereum/vip-070/index.ts similarity index 86% rename from multisig/simulations/ethereum/vip-100/index.ts rename to multisig/simulations/ethereum/vip-070/index.ts index 1a73e188c..653f89622 100644 --- a/multisig/simulations/ethereum/vip-100/index.ts +++ b/multisig/simulations/ethereum/vip-070/index.ts @@ -4,7 +4,7 @@ import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { forking, pretendExecutingVip } from "src/vip-framework"; -import vip100, { PUFETH } from "../../../proposals/ethereum/vip-100"; +import vip070, { PUFETH } from "../../../proposals/ethereum/vip-070"; import ERC20_ABI from "./abi/erc20.json"; const { NORMAL_TIMELOCK, VTREASURY } = NETWORK_ADDRESSES.ethereum; @@ -14,7 +14,7 @@ forking(21130180, async () => { describe("Post-VIP behavior", async () => { before(async () => { - await pretendExecutingVip(await vip100()); + await pretendExecutingVip(await vip070()); }); it("transfers initial supply from treasury to normal timelock", async () => { diff --git a/multisig/simulations/sepolia/vip-100/abi/PoolRegistry.json b/multisig/simulations/sepolia/vip-070/abi/PoolRegistry.json similarity index 100% rename from multisig/simulations/sepolia/vip-100/abi/PoolRegistry.json rename to multisig/simulations/sepolia/vip-070/abi/PoolRegistry.json diff --git a/multisig/simulations/sepolia/vip-100/abi/ResilientOracle.json b/multisig/simulations/sepolia/vip-070/abi/ResilientOracle.json similarity index 100% rename from multisig/simulations/sepolia/vip-100/abi/ResilientOracle.json rename to multisig/simulations/sepolia/vip-070/abi/ResilientOracle.json diff --git a/multisig/simulations/sepolia/vip-100/abi/comptroller.json b/multisig/simulations/sepolia/vip-070/abi/comptroller.json similarity index 100% rename from multisig/simulations/sepolia/vip-100/abi/comptroller.json rename to multisig/simulations/sepolia/vip-070/abi/comptroller.json diff --git a/multisig/simulations/sepolia/vip-100/abi/erc20.json b/multisig/simulations/sepolia/vip-070/abi/erc20.json similarity index 100% rename from multisig/simulations/sepolia/vip-100/abi/erc20.json rename to multisig/simulations/sepolia/vip-070/abi/erc20.json diff --git a/multisig/simulations/sepolia/vip-100/abi/vToken.json b/multisig/simulations/sepolia/vip-070/abi/vToken.json similarity index 100% rename from multisig/simulations/sepolia/vip-100/abi/vToken.json rename to multisig/simulations/sepolia/vip-070/abi/vToken.json diff --git a/multisig/simulations/sepolia/vip-100/abi/weth.json b/multisig/simulations/sepolia/vip-070/abi/weth.json similarity index 100% rename from multisig/simulations/sepolia/vip-100/abi/weth.json rename to multisig/simulations/sepolia/vip-070/abi/weth.json diff --git a/multisig/simulations/sepolia/vip-100/index.ts b/multisig/simulations/sepolia/vip-070/index.ts similarity index 97% rename from multisig/simulations/sepolia/vip-100/index.ts rename to multisig/simulations/sepolia/vip-070/index.ts index 842589b68..5efe8ff7c 100644 --- a/multisig/simulations/sepolia/vip-100/index.ts +++ b/multisig/simulations/sepolia/vip-070/index.ts @@ -10,7 +10,7 @@ import { checkVToken } from "src/vip-framework/checks/checkVToken"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; import { forking, pretendExecutingVip } from "src/vip-framework/index"; -import vip100, { marketSpec } from "../../../proposals/sepolia/vip-100"; +import vip070, { marketSpec } from "../../../proposals/sepolia/vip-070"; import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; import COMPTROLLER_ABI from "./abi/comptroller.json"; @@ -43,7 +43,7 @@ forking(6805700, async () => { describe("Post-VIP behavior", async () => { before(async () => { - await pretendExecutingVip(await vip100()); + await pretendExecutingVip(await vip070()); }); it("check price", async () => { diff --git a/simulations/vip-400/abi/OmnichainProposalSender.json b/simulations/vip-395/abi/OmnichainProposalSender.json similarity index 100% rename from simulations/vip-400/abi/OmnichainProposalSender.json rename to simulations/vip-395/abi/OmnichainProposalSender.json diff --git a/simulations/vip-400/abi/PoolRegistry.json b/simulations/vip-395/abi/PoolRegistry.json similarity index 100% rename from simulations/vip-400/abi/PoolRegistry.json rename to simulations/vip-395/abi/PoolRegistry.json diff --git a/simulations/vip-400/abi/ResilientOracle.json b/simulations/vip-395/abi/ResilientOracle.json similarity index 100% rename from simulations/vip-400/abi/ResilientOracle.json rename to simulations/vip-395/abi/ResilientOracle.json diff --git a/simulations/vip-400/abi/SingleTokenConverter.json b/simulations/vip-395/abi/SingleTokenConverter.json similarity index 100% rename from simulations/vip-400/abi/SingleTokenConverter.json rename to simulations/vip-395/abi/SingleTokenConverter.json diff --git a/simulations/vip-400/abi/comptroller.json b/simulations/vip-395/abi/comptroller.json similarity index 100% rename from simulations/vip-400/abi/comptroller.json rename to simulations/vip-395/abi/comptroller.json diff --git a/simulations/vip-400/abi/vToken.json b/simulations/vip-395/abi/vToken.json similarity index 100% rename from simulations/vip-400/abi/vToken.json rename to simulations/vip-395/abi/vToken.json diff --git a/simulations/vip-400/abi/weth.json b/simulations/vip-395/abi/weth.json similarity index 100% rename from simulations/vip-400/abi/weth.json rename to simulations/vip-395/abi/weth.json diff --git a/simulations/vip-400/bscmainnet.ts b/simulations/vip-395/bscmainnet.ts similarity index 83% rename from simulations/vip-400/bscmainnet.ts rename to simulations/vip-395/bscmainnet.ts index de744bcf9..db004a4c6 100644 --- a/simulations/vip-400/bscmainnet.ts +++ b/simulations/vip-395/bscmainnet.ts @@ -1,10 +1,10 @@ import { expectEvents } from "../../src/utils"; import { forking, testVip } from "../../src/vip-framework"; -import vip400 from "../../vips/vip-400/bscmainnet"; +import vip395 from "../../vips/vip-395/bscmainnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; forking(43771100, async () => { - testVip("vip400", await vip400(), { + testVip("vip400", await vip395(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-400/ethereum.ts b/simulations/vip-395/ethereum.ts similarity index 95% rename from simulations/vip-400/ethereum.ts rename to simulations/vip-395/ethereum.ts index 72180cb6d..e4404080e 100644 --- a/simulations/vip-400/ethereum.ts +++ b/simulations/vip-395/ethereum.ts @@ -10,13 +10,13 @@ import { checkVToken } from "src/vip-framework/checks/checkVToken"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework/index"; -import vip100 from "../../multisig/proposals/ethereum/vip-100"; -import vip400, { +import vip070 from "../../multisig/proposals/ethereum/vip-070"; +import vip395, { CONVERSION_INCENTIVE, PUFETH_REDSTONE_FEED, converterBaseAssets, marketSpec, -} from "../../vips/vip-400/bscmainnet"; +} from "../../vips/vip-395/bscmainnet"; import POOL_REGISTRY_ABI from "./abi/PoolRegistry.json"; import RESILIENT_ORACLE_ABI from "./abi/ResilientOracle.json"; import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; @@ -43,7 +43,7 @@ forking(21130180, async () => { await setRedstonePrice(REDSTONE_ORACLE, marketSpec.vToken.underlying.address, PUFETH_REDSTONE_FEED, FTT); await setMaxStalePeriodInChainlinkOracle(CHAINLINK_ORACLE, WETH, WETH_CHAINLINK_FEED, GUARDIAN); - await pretendExecutingVip(await vip100()); + await pretendExecutingVip(await vip070()); }); describe("Pre-VIP behavior", () => { @@ -57,11 +57,11 @@ forking(21130180, async () => { }); }); - testForkedNetworkVipCommands("vip400", await vip400()); + testForkedNetworkVipCommands("vip400", await vip395()); describe("Post-VIP behavior", async () => { before(async () => { - await pretendExecutingVip(await vip400()); + await pretendExecutingVip(await vip395()); }); it("check price", async () => { diff --git a/vips/vip-400/bscmainnet.ts b/vips/vip-395/bscmainnet.ts similarity index 61% rename from vips/vip-400/bscmainnet.ts rename to vips/vip-395/bscmainnet.ts index 42783fc04..505f09389 100644 --- a/vips/vip-400/bscmainnet.ts +++ b/vips/vip-395/bscmainnet.ts @@ -79,14 +79,64 @@ enum ConversionAccessibility { ONLY_FOR_USERS = 3, } -export const vip400 = () => { +export const vip395 = () => { const meta = { version: "v2", - title: "VIP-400", - description: `### Description`, - forDescription: "I agree that Venus Protocol should proceed with this proposal", - againstDescription: "I do not think that Venus Protocol should proceed with this proposal", - abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + title: "VIP-395 [Ethereum] New pufETH market in the Liquid Staked ETH pool", + description: `#### Summary + +If passed, following the Community proposal “[Proposal for Listing pufETH on Venus](https://community.venus.io/t/proposal-for-listing-pufeth-on-venus/4572)” and [the associated snapshot](https://snapshot.org/#/venus-xvs.eth/proposal/0xea592b48d56f18309e713e5faa8776b1191172175091af365f3bf3853f5536a6), this VIP adds a market for [pufETH](https://etherscan.io/address/0xD9A442856C234a39a81a089C06451EBAa4306a72) into the Liquid Staked ETH pool on Ethereum. + +#### Description + +#### Risk parameters + +Following [Chaos Labs recommendations](https://community.venus.io/t/proposal-for-listing-pufeth-on-venus/4572/8), the risk parameters for the new market are: + +Underlying token: [pufETH](https://etherscan.io/address/0xD9A442856C234a39a81a089C06451EBAa4306a72) + +- Borrow cap: 3,000 +- Supply cap: 300 +- Collateral factor: 80% +- Liquidation threshold: 85% +- Reserve factor: 20% + +Bootstrap liquidity: 5 pufETH - provided by [Puffer Finance](https://etherscan.io/address/0x495aeBf595D4C641af21A2a021C983C6565CA1A2). + +Interest rate curve for the new market: + +- kink: 45% +- base (yearly): 0% +- multiplier (yearly): 4.5% +- jump multiplier (yearly): 200% + +#### Oracles configuration + +The [ResilientOracle](https://docs-v4.venus.io/risk/resilient-price-oracle) deployed to [Ethereum](https://etherscan.io/address/0xd2ce3fb018805ef92b8C5976cb31F84b4E295F94) is used for pufETH, using under the hood the market price for pufETH/ETH provided by RedStone ([feed](https://etherscan.io/address/0x76A495b0bFfb53ef3F0E94ef0763e03cE410835C)), and the ETH/USD price provided by the ResilientOracle. + +#### Security and additional considerations + +We applied the following security procedures for this upgrade: + +- **VIP execution simulation:** in a simulation environment, validating the new market is properly added to the Liquid Staked ETH pool on Ethereum, with the right parameters and the expected bootstrap liquidity +- **Deployment on testnet:** the same market has been deployed to Sepolia, and used in the Venus Protocol testnet deployment + +The bootstrap liquidity is available on the [Venus Treasury on Ethereum](https://etherscan.io/address/0xFD9B071168bC27DBE16406eC3Aba050Ce8Eb22FA). If this VIP passes, [this](https://app.safe.global/transactions/tx?safe=eth:0x285960C5B22fD66A736C7136967A3eB15e93CC67&id=multisig_0x285960C5B22fD66A736C7136967A3eB15e93CC67_0x25e0dbb5234ea065c8679f298abb1b2998f08b314e34d3bd3237c5c724c96ea0) multisig transaction will be executed to withdraw those funds, allowing Governance to supply them to the new pufETH market. + +#### Deployed contracts + +- Mainnet vpufETH_LiquidStakedETH: [0xE0ee5dDeBFe0abe0a4Af50299D68b74Cec31668e](https://etherscan.io/address/0xE0ee5dDeBFe0abe0a4Af50299D68b74Cec31668e) +- Testnet vpufETH_LiquidStakedETH: [0x1E4d64B7c6f1F71969E5137B5Ee8cBa9Ab9c9356](https://sepolia.etherscan.io/address/0x1E4d64B7c6f1F71969E5137B5Ee8cBa9Ab9c9356) + +#### References + +- [VIP simulation](https://github.com/VenusProtocol/vips/pull/401) +- [Deployment to Sepolia](https://sepolia.etherscan.io/tx/0x7c27c86bbabc084c2cb30c46c4acebbe849974eebf25318455f7dad6fac2065f) +- [Documentation](https://docs-v4.venus.io/) +`, + forDescription: "Process to configure and launch the new market", + againstDescription: "Defer configuration and launch of the new market", + abstainDescription: "No opinion on the matter", }; return makeProposal( @@ -170,4 +220,4 @@ export const vip400 = () => { ); }; -export default vip400; +export default vip395; From d5fac4e85e280bf88b83a32207b1238b73b6a613 Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 13 Nov 2024 10:14:08 +0400 Subject: [PATCH 141/178] fix: converted to fast track --- vips/vip-392/bscmainnet.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vips/vip-392/bscmainnet.ts b/vips/vip-392/bscmainnet.ts index 60909c0ca..b3be5d388 100644 --- a/vips/vip-392/bscmainnet.ts +++ b/vips/vip-392/bscmainnet.ts @@ -71,7 +71,7 @@ const vip392 = () => { }, ], meta, - ProposalType.REGULAR, + ProposalType.FAST_TRACK, ); }; From b55335bf54213e29f6df9040333274a93450cf26 Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 13 Nov 2024 10:23:50 +0400 Subject: [PATCH 142/178] fix: set caps for vFDUSD --- simulations/vip-392/abi/CoreComptroller.json | 954 +++++++++++++++++++ simulations/vip-392/bscmainnet.ts | 27 + vips/vip-392/bscmainnet.ts | 17 + 3 files changed, 998 insertions(+) create mode 100644 simulations/vip-392/abi/CoreComptroller.json diff --git a/simulations/vip-392/abi/CoreComptroller.json b/simulations/vip-392/abi/CoreComptroller.json new file mode 100644 index 000000000..ad25568bc --- /dev/null +++ b/simulations/vip-392/abi/CoreComptroller.json @@ -0,0 +1,954 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "ActionPaused", + "type": "error" + }, + { "inputs": [], "name": "BorrowActionNotPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "BorrowCapIsNotZero", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { "inputs": [], "name": "CollateralFactorIsNotZero", "type": "error" }, + { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, + { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, + { "inputs": [], "name": "EnterMarketActionNotPaused", "type": "error" }, + { "inputs": [], "name": "ExitMarketActionNotPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, + { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, + { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, + { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, + { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, + { "inputs": [], "name": "LiquidateActionNotPaused", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { "inputs": [], "name": "MintActionNotPaused", "type": "error" }, + { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "PriceError", + "type": "error" + }, + { "inputs": [], "name": "RedeemActionNotPaused", "type": "error" }, + { "inputs": [], "name": "RepayActionNotPaused", "type": "error" }, + { "inputs": [], "name": "SeizeActionNotPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "SupplyCapIsNotZero", "type": "error" }, + { "inputs": [], "name": "TooMuchRepay", "type": "error" }, + { "inputs": [], "name": "TransferActionNotPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "expectedSender", "type": "address" }, + { "internalType": "address", "name": "actualSender", "type": "address" } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, + { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "MarketUnlisted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "accountAssets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "actionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allMarkets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "approvedDelegates", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "borrowCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "contract VToken", "name": "vToken", "type": "address" } + ], + "name": "checkMembership", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], + "name": "enterMarkets", + "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], + "name": "exitMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAssetsIn", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getBorrowingPower", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "vTokenModify", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isForcedLiquidationEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "isMarketListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [ + { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "bool", "name": "isListed", "type": "bool" }, + { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "seizerContract", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, + { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, + { "internalType": "bool", "name": "paused", "type": "bool" } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "supplyCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "unlistMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "delegate", "type": "address" }, + { "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-392/bscmainnet.ts b/simulations/vip-392/bscmainnet.ts index 69d249792..9f7c69095 100644 --- a/simulations/vip-392/bscmainnet.ts +++ b/simulations/vip-392/bscmainnet.ts @@ -1,15 +1,21 @@ import { expect } from "chai"; +import { parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; import { expectEvents } from "src/utils"; import { forking, testVip } from "src/vip-framework"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; import vip392, { + BORROW_CAP, BSC_VETH_LST_IRM, BSC_vETH_CORE, BSC_vETH_CORE_IRM, BSC_vETH_LST, + COMPTROLLER, + SUPPLY_CAP, + vFDUSD, } from "../../vips/vip-392/bscmainnet"; +import COMPTROLLER_ABI from "./abi/CoreComptroller.json"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; import VTOKEN_CORE_POOL_ABI from "./abi/VTokenCorePool.json"; @@ -18,6 +24,17 @@ forking(43743361, async () => { const vETHCore = new ethers.Contract(BSC_vETH_CORE, VTOKEN_CORE_POOL_ABI, provider); const vETHLST = new ethers.Contract(BSC_vETH_LST, VTOKEN_CORE_POOL_ABI, provider); + const comptroller = new ethers.Contract(COMPTROLLER, COMPTROLLER_ABI, provider); + + describe("Pre-VIP behavior", async () => { + it("check supply and borrow cap", async () => { + const supplyCap = await comptroller.supplyCaps(vFDUSD); + const borrowCap = await comptroller.borrowCaps(vFDUSD); + + expect(supplyCap).to.eq(parseUnits("45000000", 18)); + expect(borrowCap).to.eq(parseUnits("40000000", 18)); + }); + }); testVip("VIP-392", await vip392(), { callbackAfterExecution: async txResponse => { @@ -27,6 +44,8 @@ forking(43743361, async () => { ["ExecuteRemoteProposal", "StorePayload"], [3, 0], ); + + await expectEvents(txResponse, [COMPTROLLER_ABI], ["NewBorrowCap", "NewSupplyCap"], [1, 1]); }, }); @@ -51,5 +70,13 @@ forking(43743361, async () => { kink: "0.9", }); }); + + it("check supply and borrow cap", async () => { + const supplyCap = await comptroller.supplyCaps(vFDUSD); + const borrowCap = await comptroller.borrowCaps(vFDUSD); + + expect(supplyCap).to.eq(SUPPLY_CAP); + expect(borrowCap).to.eq(BORROW_CAP); + }); }); }); diff --git a/vips/vip-392/bscmainnet.ts b/vips/vip-392/bscmainnet.ts index b3be5d388..51a984303 100644 --- a/vips/vip-392/bscmainnet.ts +++ b/vips/vip-392/bscmainnet.ts @@ -1,3 +1,4 @@ +import { parseUnits } from "ethers/lib/utils"; import { LzChainId, ProposalType } from "src/types"; import { makeProposal } from "src/utils"; @@ -17,6 +18,11 @@ export const ETHEREUM_IRM = "0x2F81dAA9de0fD60fb9B105Cfc5b67A31Fda547b6"; export const OPBNB_vETH_CORE = "0x509e81eF638D489936FA85BC58F52Df01190d26C"; export const OPBNB_IRM = "0x0d75544019e3015eEbF61F26595D08d60f3aC841"; +export const vFDUSD = "0xC4eF4229FEc74Ccfe17B2bdeF7715fAC740BA0ba"; +export const COMPTROLLER = "0xfD36E2c2a6789Db23113685031d7F16329158384"; +export const SUPPLY_CAP = parseUnits("100000000", 18); +export const BORROW_CAP = parseUnits("80000000", 18); + const vip392 = () => { const meta = { version: "v2", @@ -69,6 +75,17 @@ const vip392 = () => { params: [OPBNB_IRM], dstChainId: LzChainId.opbnbmainnet, }, + + { + target: COMPTROLLER, + signature: "_setMarketSupplyCaps(address[],uint256[])", + params: [[vFDUSD], [SUPPLY_CAP]], + }, + { + target: COMPTROLLER, + signature: "_setMarketBorrowCaps(address[],uint256[])", + params: [[vFDUSD], [BORROW_CAP]], + }, ], meta, ProposalType.FAST_TRACK, From d5a8523cbcd7c52501024176e9864d78b0c09454 Mon Sep 17 00:00:00 2001 From: web3rover Date: Wed, 13 Nov 2024 10:59:30 +0400 Subject: [PATCH 143/178] fix: updated block number --- simulations/vip-392/arbitrumone.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/simulations/vip-392/arbitrumone.ts b/simulations/vip-392/arbitrumone.ts index 8b6f9f335..61a9180f2 100644 --- a/simulations/vip-392/arbitrumone.ts +++ b/simulations/vip-392/arbitrumone.ts @@ -7,7 +7,7 @@ import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; import vip392, { ARBITRUM_IRM, ARBITRUM_vETH_CORE, ARBITRUM_vETH_LST } from "../../vips/vip-392/bscmainnet"; import VTOKEN_ABI from "./abi/vToken.json"; -forking(271980750, async () => { +forking(273956364, async () => { let vETHCore: Contract; let vETHLST: Contract; From 3881c385393b9b0f6ad7da1ccd9895f5d32203e5 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Thu, 14 Nov 2024 02:47:37 +0700 Subject: [PATCH 144/178] feat: set ID and description for VIP 396 --- .../abi/CoreComptroller.json | 0 .../abi/OmnichainProposalSender.json | 0 .../abi/VTokenCorePool.json | 0 .../{vip-392 => vip-396}/abi/vToken.json | 0 .../{vip-392 => vip-396}/arbitrumone.ts | 4 +- .../{vip-392 => vip-396}/bscmainnet.ts | 6 +-- simulations/{vip-392 => vip-396}/ethereum.ts | 4 +- .../{vip-392 => vip-396}/opbnbmainnet.ts | 4 +- vips/{vip-392 => vip-396}/bscmainnet.ts | 53 +++++++++++++++++-- 9 files changed, 58 insertions(+), 13 deletions(-) rename simulations/{vip-392 => vip-396}/abi/CoreComptroller.json (100%) rename simulations/{vip-392 => vip-396}/abi/OmnichainProposalSender.json (100%) rename simulations/{vip-392 => vip-396}/abi/VTokenCorePool.json (100%) rename simulations/{vip-392 => vip-396}/abi/vToken.json (100%) rename simulations/{vip-392 => vip-396}/arbitrumone.ts (88%) rename simulations/{vip-392 => vip-396}/bscmainnet.ts (96%) rename simulations/{vip-392 => vip-396}/ethereum.ts (87%) rename simulations/{vip-392 => vip-396}/opbnbmainnet.ts (88%) rename vips/{vip-392 => vip-396}/bscmainnet.ts (54%) diff --git a/simulations/vip-392/abi/CoreComptroller.json b/simulations/vip-396/abi/CoreComptroller.json similarity index 100% rename from simulations/vip-392/abi/CoreComptroller.json rename to simulations/vip-396/abi/CoreComptroller.json diff --git a/simulations/vip-392/abi/OmnichainProposalSender.json b/simulations/vip-396/abi/OmnichainProposalSender.json similarity index 100% rename from simulations/vip-392/abi/OmnichainProposalSender.json rename to simulations/vip-396/abi/OmnichainProposalSender.json diff --git a/simulations/vip-392/abi/VTokenCorePool.json b/simulations/vip-396/abi/VTokenCorePool.json similarity index 100% rename from simulations/vip-392/abi/VTokenCorePool.json rename to simulations/vip-396/abi/VTokenCorePool.json diff --git a/simulations/vip-392/abi/vToken.json b/simulations/vip-396/abi/vToken.json similarity index 100% rename from simulations/vip-392/abi/vToken.json rename to simulations/vip-396/abi/vToken.json diff --git a/simulations/vip-392/arbitrumone.ts b/simulations/vip-396/arbitrumone.ts similarity index 88% rename from simulations/vip-392/arbitrumone.ts rename to simulations/vip-396/arbitrumone.ts index 61a9180f2..deb46ae78 100644 --- a/simulations/vip-392/arbitrumone.ts +++ b/simulations/vip-396/arbitrumone.ts @@ -4,7 +4,7 @@ import { ethers } from "hardhat"; import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; -import vip392, { ARBITRUM_IRM, ARBITRUM_vETH_CORE, ARBITRUM_vETH_LST } from "../../vips/vip-392/bscmainnet"; +import vip396, { ARBITRUM_IRM, ARBITRUM_vETH_CORE, ARBITRUM_vETH_LST } from "../../vips/vip-396/bscmainnet"; import VTOKEN_ABI from "./abi/vToken.json"; forking(273956364, async () => { @@ -16,7 +16,7 @@ forking(273956364, async () => { vETHLST = await ethers.getContractAt(VTOKEN_ABI, ARBITRUM_vETH_LST); }); - testForkedNetworkVipCommands("vip392", await vip392()); + testForkedNetworkVipCommands("vip396", await vip396()); describe("Post-VIP behavior", async () => { it("check it correctly sets new interest rate model", async () => { diff --git a/simulations/vip-392/bscmainnet.ts b/simulations/vip-396/bscmainnet.ts similarity index 96% rename from simulations/vip-392/bscmainnet.ts rename to simulations/vip-396/bscmainnet.ts index 9f7c69095..97b1657fb 100644 --- a/simulations/vip-392/bscmainnet.ts +++ b/simulations/vip-396/bscmainnet.ts @@ -5,7 +5,7 @@ import { expectEvents } from "src/utils"; import { forking, testVip } from "src/vip-framework"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; -import vip392, { +import vip396, { BORROW_CAP, BSC_VETH_LST_IRM, BSC_vETH_CORE, @@ -14,7 +14,7 @@ import vip392, { COMPTROLLER, SUPPLY_CAP, vFDUSD, -} from "../../vips/vip-392/bscmainnet"; +} from "../../vips/vip-396/bscmainnet"; import COMPTROLLER_ABI from "./abi/CoreComptroller.json"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; import VTOKEN_CORE_POOL_ABI from "./abi/VTokenCorePool.json"; @@ -36,7 +36,7 @@ forking(43743361, async () => { }); }); - testVip("VIP-392", await vip392(), { + testVip("VIP-396", await vip396(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-392/ethereum.ts b/simulations/vip-396/ethereum.ts similarity index 87% rename from simulations/vip-392/ethereum.ts rename to simulations/vip-396/ethereum.ts index 83995da6f..b6dabb1fc 100644 --- a/simulations/vip-392/ethereum.ts +++ b/simulations/vip-396/ethereum.ts @@ -4,7 +4,7 @@ import { ethers } from "hardhat"; import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; -import vip392, { ETHEREUM_IRM, ETHEREUM_vETH_CORE, ETHEREUM_vETH_LST } from "../../vips/vip-392/bscmainnet"; +import vip396, { ETHEREUM_IRM, ETHEREUM_vETH_CORE, ETHEREUM_vETH_LST } from "../../vips/vip-396/bscmainnet"; import VTOKEN_ABI from "./abi/vToken.json"; forking(21131771, async () => { @@ -16,7 +16,7 @@ forking(21131771, async () => { vETHLST = await ethers.getContractAt(VTOKEN_ABI, ETHEREUM_vETH_LST); }); - testForkedNetworkVipCommands("vip392", await vip392()); + testForkedNetworkVipCommands("vip396", await vip396()); describe("Post-VIP behavior", async () => { it("check it correctly sets new interest rate model", async () => { diff --git a/simulations/vip-392/opbnbmainnet.ts b/simulations/vip-396/opbnbmainnet.ts similarity index 88% rename from simulations/vip-392/opbnbmainnet.ts rename to simulations/vip-396/opbnbmainnet.ts index ed34a458d..b538f2e03 100644 --- a/simulations/vip-392/opbnbmainnet.ts +++ b/simulations/vip-396/opbnbmainnet.ts @@ -4,7 +4,7 @@ import { ethers } from "hardhat"; import { forking, testForkedNetworkVipCommands } from "src/vip-framework"; import { checkInterestRate } from "src/vip-framework/checks/interestRateModel"; -import vip392, { OPBNB_IRM, OPBNB_vETH_CORE } from "../../vips/vip-392/bscmainnet"; +import vip396, { OPBNB_IRM, OPBNB_vETH_CORE } from "../../vips/vip-396/bscmainnet"; import VTOKEN_ABI from "./abi/vToken.json"; forking(39230450, async () => { @@ -14,7 +14,7 @@ forking(39230450, async () => { vETHCore = await ethers.getContractAt(VTOKEN_ABI, OPBNB_vETH_CORE); }); - testForkedNetworkVipCommands("vip392", await vip392()); + testForkedNetworkVipCommands("vip396", await vip396()); describe("Post-VIP behavior", async () => { it("check it correctly sets new interest rate model", async () => { diff --git a/vips/vip-392/bscmainnet.ts b/vips/vip-396/bscmainnet.ts similarity index 54% rename from vips/vip-392/bscmainnet.ts rename to vips/vip-396/bscmainnet.ts index 51a984303..4d01af93f 100644 --- a/vips/vip-392/bscmainnet.ts +++ b/vips/vip-396/bscmainnet.ts @@ -23,11 +23,55 @@ export const COMPTROLLER = "0xfD36E2c2a6789Db23113685031d7F16329158384"; export const SUPPLY_CAP = parseUnits("100000000", 18); export const BORROW_CAP = parseUnits("80000000", 18); -const vip392 = () => { +const vip396 = () => { const meta = { version: "v2", - title: "VIP-392", - description: ``, + title: "VIP-396 Risk Parameters Adjustments (ETH, FDUSD)", + description: `#### Description + +If passed, this VIP will perform the following actions as per Chaos Labs’ latest recommendations in these Venus community forum publications: + +[Chaos Labs - Risk Parameter Updates - 11/11/24](https://community.venus.io/t/chaos-labs-risk-parameter-updates-11-11-24/4718) + +- BNB Chain + - [ETH - Core pool](https://bscscan.com/address/0xf508fCD89b8bd15579dc79A6827cB4686A3592c8) + - Current kink: 85%. Recommendation: 90% + - Current multiplier: 0.0425. Recommendation: 0.03 + - Current jump multiplier: 2. Recommendation: 4.5 + - [ETH - Liquid Staked ETH](https://bscscan.com/address/0xeCCACF760FEA7943C5b0285BD09F601505A29c05) + - Current kink: 80%. Recommendation: 90% + - Current multiplier: 0.035. Recommendation: 0.03 + - Current jump multiplier: 0.8. Recommendation: 4.5 +- Ethereum + - [WETH - Core](https://etherscan.io/address/0x7c8ff7d2A1372433726f879BD945fFb250B94c65) + - Current kink: 80%. Recommendation: 90% + - Current multiplier: 0.09. Recommendation: 0.03 + - Current jump multiplier: 0.75. Recommendation: 4.5 + - [WETH - Liquid Staked ETH](https://etherscan.io/address/0xc82780Db1257C788F262FBbDA960B3706Dfdcaf2) + - Current jump multiplier: 0.8. Recommendation: 4.5 +- Arbitrum + - [WETH - Core](https://arbiscan.io/address/0x68a34332983f4Bf866768DD6D6E638b02eF5e1f0) + - Current kink: 80%. Recommendation: 90% + - Current multiplier: 0.035. Recommendation: 0.03 + - Current jump multiplier: 2.5. Recommendation: 4.5 + - [WETH - Liquid Staked ETH](https://arbiscan.io/address/0x39D6d13Ea59548637104E40e729E4aABE27FE106) + - Current kink: 80%. Recommendation: 90% + - Current multiplier: 0.035. Recommendation: 0.03 + - Current jump multiplier: 2.5. Recommendation: 4.5 +- opBNB + - [ETH - Core](https://opbnbscan.com/address/0x509e81eF638D489936FA85BC58F52Df01190d26C) + - Current kink: 45%. Recommendation: 90% + - Current jump multiplier: 1. Recommendation: 4.5 + +[Chaos Labs - Risk Parameter Updates - 11/13/24](https://community.venus.io/t/chaos-labs-risk-parameter-updates-11-13-24/4722) + +- [FDUSD (Core pool)](https://bscscan.com/address/0xC4eF4229FEc74Ccfe17B2bdeF7715fAC740BA0ba): + - Increase supply cap, from 45M FDUSD to 100M FDUSD + - Increase borrow cap, from 40M FDUSD to 80M FDUSD + +Complete analysis and details of these recommendations are available in the above publications. + +VIP simulation: [https://github.com/VenusProtocol/vips/pull/422](https://github.com/VenusProtocol/vips/pull/422)`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", @@ -35,6 +79,7 @@ const vip392 = () => { return makeProposal( [ + { target: BSC_vETH_CORE, signature: "_setInterestRateModel(address)", @@ -92,4 +137,4 @@ const vip392 = () => { ); }; -export default vip392; +export default vip396; From c8c9672996233c0b49078318afe1359693fa36e5 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Thu, 14 Nov 2024 03:01:15 +0700 Subject: [PATCH 145/178] feat: fund the normal timelock contract with BNB to send cross-chain messages --- simulations/vip-396/bscmainnet.ts | 3 +++ vips/vip-396/bscmainnet.ts | 15 +++++++++++++-- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/simulations/vip-396/bscmainnet.ts b/simulations/vip-396/bscmainnet.ts index 97b1657fb..eb0e162bd 100644 --- a/simulations/vip-396/bscmainnet.ts +++ b/simulations/vip-396/bscmainnet.ts @@ -18,6 +18,7 @@ import vip396, { import COMPTROLLER_ABI from "./abi/CoreComptroller.json"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; import VTOKEN_CORE_POOL_ABI from "./abi/VTokenCorePool.json"; +import TREASURY_ABI from "./abi/VTreasuryAbi.json"; forking(43743361, async () => { const provider = ethers.provider; @@ -46,6 +47,8 @@ forking(43743361, async () => { ); await expectEvents(txResponse, [COMPTROLLER_ABI], ["NewBorrowCap", "NewSupplyCap"], [1, 1]); + + await expectEvents(txResponse, [TREASURY_ABI], ["WithdrawTreasuryBNB"], [1]); }, }); diff --git a/vips/vip-396/bscmainnet.ts b/vips/vip-396/bscmainnet.ts index 4d01af93f..95824240c 100644 --- a/vips/vip-396/bscmainnet.ts +++ b/vips/vip-396/bscmainnet.ts @@ -1,6 +1,10 @@ import { parseUnits } from "ethers/lib/utils"; import { LzChainId, ProposalType } from "src/types"; import { makeProposal } from "src/utils"; +import { NORMAL_TIMELOCK } from "src/vip-framework"; + +const TREASURY = "0xF322942f644A996A617BD29c16bd7d231d9F35E9"; +export const BNB_AMOUNT = parseUnits("10", 18); export const BSC_VETH_LST_IRM = "0x49a06B82b3c907AB140879F73f1d8dE262962c30"; export const BSC_vETH_CORE_IRM = "0x3aa125788FC6b9F801772baEa887aA40328015e9"; @@ -71,6 +75,8 @@ If passed, this VIP will perform the following actions as per Chaos Labs’ late Complete analysis and details of these recommendations are available in the above publications. +Moreover, this VIP will transfer 10 BNB from the [Venus Treasury on BNB](https://bscscan.com/address/0xf322942f644a996a617bd29c16bd7d231d9f35e9) to the [Normal Timelock](https://bscscan.com/address/0x939bD8d64c0A9583A7Dcea9933f7b21697ab6396) contract, to fund the cross-chain messages. + VIP simulation: [https://github.com/VenusProtocol/vips/pull/422](https://github.com/VenusProtocol/vips/pull/422)`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", @@ -79,7 +85,12 @@ VIP simulation: [https://github.com/VenusProtocol/vips/pull/422](https://github. return makeProposal( [ - + { + target: TREASURY, + signature: "withdrawTreasuryBNB(uint256,address)", + params: [BNB_AMOUNT, NORMAL_TIMELOCK], + value: "0", + }, { target: BSC_vETH_CORE, signature: "_setInterestRateModel(address)", @@ -133,7 +144,7 @@ VIP simulation: [https://github.com/VenusProtocol/vips/pull/422](https://github. }, ], meta, - ProposalType.FAST_TRACK, + ProposalType.REGULAR, ); }; From 5447bcadf6ebcf11bfcbc0528e5fb4f3300ba2dc Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Thu, 14 Nov 2024 03:14:00 +0700 Subject: [PATCH 146/178] feat: fund the Critical and Fast-track timelocks with BNB needed for cross-chain messages --- simulations/vip-396/abi/VTreasuryAbi.json | 83 +++++++++++++++++++++++ simulations/vip-396/bscmainnet.ts | 2 +- vips/vip-396/bscmainnet.ts | 18 ++++- 3 files changed, 99 insertions(+), 4 deletions(-) create mode 100644 simulations/vip-396/abi/VTreasuryAbi.json diff --git a/simulations/vip-396/abi/VTreasuryAbi.json b/simulations/vip-396/abi/VTreasuryAbi.json new file mode 100644 index 000000000..df5a655ee --- /dev/null +++ b/simulations/vip-396/abi/VTreasuryAbi.json @@ -0,0 +1,83 @@ +[ + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": false, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryBEP20", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "indexed": false, "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "WithdrawTreasuryBNB", + "type": "event" + }, + { "payable": true, "stateMutability": "payable", "type": "fallback" }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "address", "name": "tokenAddress", "type": "address" }, + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryBEP20", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { "internalType": "uint256", "name": "withdrawAmount", "type": "uint256" }, + { "internalType": "address payable", "name": "withdrawAddress", "type": "address" } + ], + "name": "withdrawTreasuryBNB", + "outputs": [], + "payable": true, + "stateMutability": "payable", + "type": "function" + } +] diff --git a/simulations/vip-396/bscmainnet.ts b/simulations/vip-396/bscmainnet.ts index eb0e162bd..b8ad4df69 100644 --- a/simulations/vip-396/bscmainnet.ts +++ b/simulations/vip-396/bscmainnet.ts @@ -48,7 +48,7 @@ forking(43743361, async () => { await expectEvents(txResponse, [COMPTROLLER_ABI], ["NewBorrowCap", "NewSupplyCap"], [1, 1]); - await expectEvents(txResponse, [TREASURY_ABI], ["WithdrawTreasuryBNB"], [1]); + await expectEvents(txResponse, [TREASURY_ABI], ["WithdrawTreasuryBNB"], [3]); }, }); diff --git a/vips/vip-396/bscmainnet.ts b/vips/vip-396/bscmainnet.ts index 95824240c..7dbe7e419 100644 --- a/vips/vip-396/bscmainnet.ts +++ b/vips/vip-396/bscmainnet.ts @@ -1,10 +1,10 @@ import { parseUnits } from "ethers/lib/utils"; import { LzChainId, ProposalType } from "src/types"; import { makeProposal } from "src/utils"; -import { NORMAL_TIMELOCK } from "src/vip-framework"; +import { CRITICAL_TIMELOCK, FAST_TRACK_TIMELOCK, NORMAL_TIMELOCK } from "src/vip-framework"; const TREASURY = "0xF322942f644A996A617BD29c16bd7d231d9F35E9"; -export const BNB_AMOUNT = parseUnits("10", 18); +export const BNB_AMOUNT = parseUnits("5", 18); export const BSC_VETH_LST_IRM = "0x49a06B82b3c907AB140879F73f1d8dE262962c30"; export const BSC_vETH_CORE_IRM = "0x3aa125788FC6b9F801772baEa887aA40328015e9"; @@ -75,7 +75,7 @@ If passed, this VIP will perform the following actions as per Chaos Labs’ late Complete analysis and details of these recommendations are available in the above publications. -Moreover, this VIP will transfer 10 BNB from the [Venus Treasury on BNB](https://bscscan.com/address/0xf322942f644a996a617bd29c16bd7d231d9f35e9) to the [Normal Timelock](https://bscscan.com/address/0x939bD8d64c0A9583A7Dcea9933f7b21697ab6396) contract, to fund the cross-chain messages. +Moreover, this VIP will transfer 5 BNB from the [Venus Treasury on BNB](https://bscscan.com/address/0xf322942f644a996a617bd29c16bd7d231d9f35e9) to the timelock contracts ([Normal Timelock](https://bscscan.com/address/0x939bD8d64c0A9583A7Dcea9933f7b21697ab6396), [Fast-track Timelock](https://bscscan.com/address/0x555ba73dB1b006F3f2C7dB7126d6e4343aDBce02) and [Critical Timelock](https://bscscan.com/address/0x213c446ec11e45b15a6E29C1C1b402B8897f606d)), to fund the cross-chain messages sent on this VIP and in the future. VIP simulation: [https://github.com/VenusProtocol/vips/pull/422](https://github.com/VenusProtocol/vips/pull/422)`, forDescription: "I agree that Venus Protocol should proceed with this proposal", @@ -91,6 +91,18 @@ VIP simulation: [https://github.com/VenusProtocol/vips/pull/422](https://github. params: [BNB_AMOUNT, NORMAL_TIMELOCK], value: "0", }, + { + target: TREASURY, + signature: "withdrawTreasuryBNB(uint256,address)", + params: [BNB_AMOUNT, FAST_TRACK_TIMELOCK], + value: "0", + }, + { + target: TREASURY, + signature: "withdrawTreasuryBNB(uint256,address)", + params: [BNB_AMOUNT, CRITICAL_TIMELOCK], + value: "0", + }, { target: BSC_vETH_CORE, signature: "_setInterestRateModel(address)", From 7bf3d78216372f0d67f1b53fc64f80dc9ed8198e Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Mon, 18 Nov 2024 12:38:10 +0100 Subject: [PATCH 147/178] refactor: rename TX involved on enabling Prime on arbitrum --- .../arbitrumsepolia/vip-014/index.ts | 49 --- .../arbitrumsepolia/vip-016/index.ts | 51 ++- .../{vip-015 => vip-018}/index.ts | 4 +- .../{vip-016 => vip-019}/Addresses.ts | 0 .../{vip-016 => vip-019}/commands.ts | 0 .../arbitrumsepolia/vip-019/index.ts | 30 ++ .../arbitrumsepolia/vip-014/index.ts | 109 ------ .../{vip-014 => vip-016}/abi/xvs.json | 0 .../abi/xvsProxyOFTDest.json | 0 .../arbitrumsepolia/vip-016/index.ts | 258 +++++--------- .../abi/ILComptroller.json | 0 .../{vip-015 => vip-018}/abi/Prime.json | 0 .../abi/PrimeLiquidityProvider.json | 0 .../{vip-015 => vip-018}/index.ts | 6 +- .../abi/ConverterNetwork.json | 0 .../abi/SingleTokenConverter.json | 0 .../abi/XVSVaultTreasury.json | 0 .../arbitrumsepolia/vip-019/index.ts | 68 ++++ .../vip-395}/abi/ERC20.json | 0 .../vip-395/abi/OmnichainProposalSender.json | 314 ++++++++++++++++++ .../vip-395}/abi/ProtocolShareReserve.json | 0 simulations/vip-395/arbitrumsepolia.ts | 20 +- simulations/vip-395/bsctestnet.ts | 18 +- vips/vip-395/bsctestnet.ts | 13 +- 24 files changed, 559 insertions(+), 381 deletions(-) delete mode 100644 multisig/proposals/arbitrumsepolia/vip-014/index.ts rename multisig/proposals/arbitrumsepolia/{vip-015 => vip-018}/index.ts (97%) rename multisig/proposals/arbitrumsepolia/{vip-016 => vip-019}/Addresses.ts (100%) rename multisig/proposals/arbitrumsepolia/{vip-016 => vip-019}/commands.ts (100%) create mode 100644 multisig/proposals/arbitrumsepolia/vip-019/index.ts delete mode 100644 multisig/simulations/arbitrumsepolia/vip-014/index.ts rename multisig/simulations/arbitrumsepolia/{vip-014 => vip-016}/abi/xvs.json (100%) rename multisig/simulations/arbitrumsepolia/{vip-014 => vip-016}/abi/xvsProxyOFTDest.json (100%) rename multisig/simulations/arbitrumsepolia/{vip-015 => vip-018}/abi/ILComptroller.json (100%) rename multisig/simulations/arbitrumsepolia/{vip-015 => vip-018}/abi/Prime.json (100%) rename multisig/simulations/arbitrumsepolia/{vip-015 => vip-018}/abi/PrimeLiquidityProvider.json (100%) rename multisig/simulations/arbitrumsepolia/{vip-015 => vip-018}/index.ts (95%) rename multisig/simulations/arbitrumsepolia/{vip-016 => vip-019}/abi/ConverterNetwork.json (100%) rename multisig/simulations/arbitrumsepolia/{vip-016 => vip-019}/abi/SingleTokenConverter.json (100%) rename multisig/simulations/arbitrumsepolia/{vip-016 => vip-019}/abi/XVSVaultTreasury.json (100%) create mode 100644 multisig/simulations/arbitrumsepolia/vip-019/index.ts rename {multisig/simulations/arbitrumsepolia/vip-016 => simulations/vip-395}/abi/ERC20.json (100%) create mode 100644 simulations/vip-395/abi/OmnichainProposalSender.json rename {multisig/simulations/arbitrumsepolia/vip-016 => simulations/vip-395}/abi/ProtocolShareReserve.json (100%) diff --git a/multisig/proposals/arbitrumsepolia/vip-014/index.ts b/multisig/proposals/arbitrumsepolia/vip-014/index.ts deleted file mode 100644 index 43560a24f..000000000 --- a/multisig/proposals/arbitrumsepolia/vip-014/index.ts +++ /dev/null @@ -1,49 +0,0 @@ -import { parseUnits } from "ethers/lib/utils"; -import { LzChainId } from "src/types"; -import { makeProposal } from "src/utils"; - -const XVS_BRIDGE_ADMIN = "0xc94578caCC89a29B044a0a1D54d20d48A645E5C8"; - -export const MIN_DST_GAS = "300000"; -export const SINGLE_SEND_LIMIT = parseUnits("10000", 18); -export const MAX_DAILY_SEND_LIMIT = parseUnits("50000", 18); -export const SINGLE_RECEIVE_LIMIT = parseUnits("10200", 18); -export const MAX_DAILY_RECEIVE_LIMIT = parseUnits("51000", 18); -export const OP_SEPOLIA_TRUSTED_REMOTE = "0x79a36dc9a43d05db4747c59c02f48ed500e47df1"; - -const vip014 = () => { - return makeProposal([ - { - target: XVS_BRIDGE_ADMIN, - signature: "setTrustedRemoteAddress(uint16,bytes)", - params: [LzChainId.opsepolia, OP_SEPOLIA_TRUSTED_REMOTE], - }, - { - target: XVS_BRIDGE_ADMIN, - signature: "setMinDstGas(uint16,uint16,uint256)", - params: [LzChainId.opsepolia, 0, MIN_DST_GAS], - }, - { - target: XVS_BRIDGE_ADMIN, - signature: "setMaxDailyLimit(uint16,uint256)", - params: [LzChainId.opsepolia, MAX_DAILY_SEND_LIMIT], - }, - { - target: XVS_BRIDGE_ADMIN, - signature: "setMaxSingleTransactionLimit(uint16,uint256)", - params: [LzChainId.opsepolia, SINGLE_SEND_LIMIT], - }, - { - target: XVS_BRIDGE_ADMIN, - signature: "setMaxDailyReceiveLimit(uint16,uint256)", - params: [LzChainId.opsepolia, MAX_DAILY_RECEIVE_LIMIT], - }, - { - target: XVS_BRIDGE_ADMIN, - signature: "setMaxSingleReceiveTransactionLimit(uint16,uint256)", - params: [LzChainId.opsepolia, SINGLE_RECEIVE_LIMIT], - }, - ]); -}; - -export default vip014; diff --git a/multisig/proposals/arbitrumsepolia/vip-016/index.ts b/multisig/proposals/arbitrumsepolia/vip-016/index.ts index 66373e477..638d9e7b9 100644 --- a/multisig/proposals/arbitrumsepolia/vip-016/index.ts +++ b/multisig/proposals/arbitrumsepolia/vip-016/index.ts @@ -1,29 +1,48 @@ +import { parseUnits } from "ethers/lib/utils"; +import { LzChainId } from "src/types"; import { makeProposal } from "src/utils"; -import { CONVERTER_NETWORK } from "./Addresses"; -import { - acceptOwnershipCommandsAllConverters, - callPermissionCommandsAllConverter, - setConverterNetworkCommands, -} from "./commands"; +const XVS_BRIDGE_ADMIN = "0xc94578caCC89a29B044a0a1D54d20d48A645E5C8"; -export const XVS_VAULT_TREASURY = "0x309b71a417dA9CfA8aC47e6038000B1739d9A3A6"; +export const MIN_DST_GAS = "300000"; +export const SINGLE_SEND_LIMIT = parseUnits("10000", 18); +export const MAX_DAILY_SEND_LIMIT = parseUnits("50000", 18); +export const SINGLE_RECEIVE_LIMIT = parseUnits("10200", 18); +export const MAX_DAILY_RECEIVE_LIMIT = parseUnits("51000", 18); +export const OP_SEPOLIA_TRUSTED_REMOTE = "0x79a36dc9a43d05db4747c59c02f48ed500e47df1"; const vip016 = () => { return makeProposal([ - ...acceptOwnershipCommandsAllConverters, { - target: XVS_VAULT_TREASURY, - signature: "acceptOwnership()", - params: [], + target: XVS_BRIDGE_ADMIN, + signature: "setTrustedRemoteAddress(uint16,bytes)", + params: [LzChainId.opsepolia, OP_SEPOLIA_TRUSTED_REMOTE], }, { - target: CONVERTER_NETWORK, - signature: "acceptOwnership()", - params: [], + target: XVS_BRIDGE_ADMIN, + signature: "setMinDstGas(uint16,uint16,uint256)", + params: [LzChainId.opsepolia, 0, MIN_DST_GAS], + }, + { + target: XVS_BRIDGE_ADMIN, + signature: "setMaxDailyLimit(uint16,uint256)", + params: [LzChainId.opsepolia, MAX_DAILY_SEND_LIMIT], + }, + { + target: XVS_BRIDGE_ADMIN, + signature: "setMaxSingleTransactionLimit(uint16,uint256)", + params: [LzChainId.opsepolia, SINGLE_SEND_LIMIT], + }, + { + target: XVS_BRIDGE_ADMIN, + signature: "setMaxDailyReceiveLimit(uint16,uint256)", + params: [LzChainId.opsepolia, MAX_DAILY_RECEIVE_LIMIT], + }, + { + target: XVS_BRIDGE_ADMIN, + signature: "setMaxSingleReceiveTransactionLimit(uint16,uint256)", + params: [LzChainId.opsepolia, SINGLE_RECEIVE_LIMIT], }, - ...callPermissionCommandsAllConverter, - ...setConverterNetworkCommands, ]); }; diff --git a/multisig/proposals/arbitrumsepolia/vip-015/index.ts b/multisig/proposals/arbitrumsepolia/vip-018/index.ts similarity index 97% rename from multisig/proposals/arbitrumsepolia/vip-015/index.ts rename to multisig/proposals/arbitrumsepolia/vip-018/index.ts index 57d26ab4b..be8947419 100644 --- a/multisig/proposals/arbitrumsepolia/vip-015/index.ts +++ b/multisig/proposals/arbitrumsepolia/vip-018/index.ts @@ -16,7 +16,7 @@ export const PRIME_NEW_IMPLEMENTATION = "0x507866eCb585275E006D9098867a0e9B08C11 export const PRIME_OLD_IMPLEMENTATION = "0x255EFC81Ba715FA7C2C27bdd983A3CeF9BB07fEf"; export const PROXY_ADMIN = "0xA78A1Df376c3CEeBC5Fab574fe6EdDbbF76fd03e"; -const vip015 = () => { +const vip018 = () => { return makeProposal([ { target: PROXY_ADMIN, @@ -51,4 +51,4 @@ const vip015 = () => { ]); }; -export default vip015; +export default vip018; diff --git a/multisig/proposals/arbitrumsepolia/vip-016/Addresses.ts b/multisig/proposals/arbitrumsepolia/vip-019/Addresses.ts similarity index 100% rename from multisig/proposals/arbitrumsepolia/vip-016/Addresses.ts rename to multisig/proposals/arbitrumsepolia/vip-019/Addresses.ts diff --git a/multisig/proposals/arbitrumsepolia/vip-016/commands.ts b/multisig/proposals/arbitrumsepolia/vip-019/commands.ts similarity index 100% rename from multisig/proposals/arbitrumsepolia/vip-016/commands.ts rename to multisig/proposals/arbitrumsepolia/vip-019/commands.ts diff --git a/multisig/proposals/arbitrumsepolia/vip-019/index.ts b/multisig/proposals/arbitrumsepolia/vip-019/index.ts new file mode 100644 index 000000000..fb8d255a1 --- /dev/null +++ b/multisig/proposals/arbitrumsepolia/vip-019/index.ts @@ -0,0 +1,30 @@ +import { makeProposal } from "src/utils"; + +import { CONVERTER_NETWORK } from "./Addresses"; +import { + acceptOwnershipCommandsAllConverters, + callPermissionCommandsAllConverter, + setConverterNetworkCommands, +} from "./commands"; + +export const XVS_VAULT_TREASURY = "0x309b71a417dA9CfA8aC47e6038000B1739d9A3A6"; + +const vip019 = () => { + return makeProposal([ + ...acceptOwnershipCommandsAllConverters, + { + target: XVS_VAULT_TREASURY, + signature: "acceptOwnership()", + params: [], + }, + { + target: CONVERTER_NETWORK, + signature: "acceptOwnership()", + params: [], + }, + ...callPermissionCommandsAllConverter, + ...setConverterNetworkCommands, + ]); +}; + +export default vip019; diff --git a/multisig/simulations/arbitrumsepolia/vip-014/index.ts b/multisig/simulations/arbitrumsepolia/vip-014/index.ts deleted file mode 100644 index 3dd9c55c3..000000000 --- a/multisig/simulations/arbitrumsepolia/vip-014/index.ts +++ /dev/null @@ -1,109 +0,0 @@ -import { SignerWithAddress } from "@nomiclabs/hardhat-ethers/signers"; -import { expect } from "chai"; -import { Contract } from "ethers"; -import { parseUnits } from "ethers/lib/utils"; -import { ethers } from "hardhat"; -import { LzChainId } from "src/types"; -import { initMainnetUser } from "src/utils"; -import { forking, pretendExecutingVip } from "src/vip-framework"; - -import vip014, { - MAX_DAILY_RECEIVE_LIMIT, - MAX_DAILY_SEND_LIMIT, - OP_SEPOLIA_TRUSTED_REMOTE, - SINGLE_RECEIVE_LIMIT, - SINGLE_SEND_LIMIT, -} from "../../../proposals/arbitrumsepolia/vip-014"; -import XVS_ABI from "./abi/xvs.json"; -import XVS_BRIDGE_ABI from "./abi/xvsProxyOFTDest.json"; - -const XVS = "0x877Dc896e7b13096D3827872e396927BbE704407"; -const XVS_BRIDGE = "0xFdC5cEC63FD167DA46cF006585b30D03B104eFD4"; -const XVS_HOLDER = "0xFd7dA20ea0bE63ACb0852f97E950376E7E4a817D"; - -forking(79930177, async () => { - let xvs: Contract; - let xvsBridge: Contract; - let xvsHolderSigner: SignerWithAddress; - let receiver: SignerWithAddress; - let receiverAddressBytes32: string; - let defaultAdapterParams: string; - - before(async () => { - xvs = await ethers.getContractAt(XVS_ABI, XVS); - xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); - xvsHolderSigner = await initMainnetUser(XVS_HOLDER, ethers.utils.parseEther("5")); - [receiver] = await ethers.getSigners(); - receiverAddressBytes32 = ethers.utils.defaultAbiCoder.encode(["address"], [receiver.address]); - defaultAdapterParams = ethers.utils.solidityPack(["uint16", "uint256"], [1, 300000]); - }); - - describe("Post-Execution state", () => { - before(async () => { - await pretendExecutingVip(await vip014()); - }); - - it("Should match trusted remote address", async () => { - const trustedRemote = await xvsBridge.getTrustedRemoteAddress(LzChainId.opsepolia); - expect(trustedRemote).equals(OP_SEPOLIA_TRUSTED_REMOTE); - }); - - it("Should match single send transaction limit", async () => { - expect(await xvsBridge.chainIdToMaxSingleTransactionLimit(LzChainId.opsepolia)).to.equal(SINGLE_SEND_LIMIT); - }); - - it("Should match single receive transaction limit", async () => { - expect(await xvsBridge.chainIdToMaxSingleReceiveTransactionLimit(LzChainId.opsepolia)).to.equal( - SINGLE_RECEIVE_LIMIT, - ); - }); - - it("Should match max daily send limit", async () => { - expect(await xvsBridge.chainIdToMaxDailyLimit(LzChainId.opsepolia)).to.equal(MAX_DAILY_SEND_LIMIT); - }); - - it("Should match max daily receive limit", async () => { - expect(await xvsBridge.chainIdToMaxDailyReceiveLimit(LzChainId.opsepolia)).to.equal(MAX_DAILY_RECEIVE_LIMIT); - }); - - it("Should emit an event on successful bridging of XVS (Arbitrum sepolia -> Op Sepolia)", async () => { - const amount = parseUnits("1", 18); - const nativeFee = ( - await xvsBridge.estimateSendFee( - LzChainId.opsepolia, - receiverAddressBytes32, - amount, - false, - defaultAdapterParams, - ) - ).nativeFee; - - const circulatingSupplyBefore = await xvsBridge.circulatingSupply(); - const totalSupplyBefore = await xvs.totalSupply(); - const minterToMintedAmountBefore = await xvs.minterToMintedAmount(XVS_BRIDGE); - - await expect( - xvsBridge - .connect(xvsHolderSigner) - .sendFrom( - xvsHolderSigner.address, - LzChainId.opsepolia, - receiverAddressBytes32, - amount, - [xvsHolderSigner.address, ethers.constants.AddressZero, defaultAdapterParams], - { value: nativeFee }, - ), - ) - .to.be.emit(xvsBridge, "SendToChain") - .withArgs(LzChainId.opsepolia, XVS_HOLDER, receiverAddressBytes32, amount); - - const circulatingSupplyAfter = await xvsBridge.circulatingSupply(); - const totalSupplyAfter = await xvs.totalSupply(); - const minterToMintedAmountAfter = await xvs.minterToMintedAmount(XVS_BRIDGE); - - expect(circulatingSupplyBefore).equals(circulatingSupplyAfter.add(amount)); - expect(totalSupplyBefore).equals(totalSupplyAfter.add(amount)); - expect(minterToMintedAmountBefore).equals(minterToMintedAmountAfter.add(amount)); - }); - }); -}); diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/xvs.json b/multisig/simulations/arbitrumsepolia/vip-016/abi/xvs.json similarity index 100% rename from multisig/simulations/arbitrumsepolia/vip-014/abi/xvs.json rename to multisig/simulations/arbitrumsepolia/vip-016/abi/xvs.json diff --git a/multisig/simulations/arbitrumsepolia/vip-014/abi/xvsProxyOFTDest.json b/multisig/simulations/arbitrumsepolia/vip-016/abi/xvsProxyOFTDest.json similarity index 100% rename from multisig/simulations/arbitrumsepolia/vip-014/abi/xvsProxyOFTDest.json rename to multisig/simulations/arbitrumsepolia/vip-016/abi/xvsProxyOFTDest.json diff --git a/multisig/simulations/arbitrumsepolia/vip-016/index.ts b/multisig/simulations/arbitrumsepolia/vip-016/index.ts index 2c34e2945..f735cd0da 100644 --- a/multisig/simulations/arbitrumsepolia/vip-016/index.ts +++ b/multisig/simulations/arbitrumsepolia/vip-016/index.ts @@ -1,207 +1,109 @@ -/* eslint-disable @typescript-eslint/no-unused-vars */ +import { SignerWithAddress } from "@nomiclabs/hardhat-ethers/signers"; import { expect } from "chai"; -import { BigNumber, Contract, Signer } from "ethers"; +import { Contract } from "ethers"; import { parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId } from "src/types"; import { initMainnetUser } from "src/utils"; import { forking, pretendExecutingVip } from "src/vip-framework"; -import vip016, { XVS_VAULT_TREASURY } from "../../../proposals/arbitrumsepolia/vip-016"; -import { - CONVERTER_NETWORK, - USDC_PRIME_CONVERTER, - USDT_PRIME_CONVERTER, - XVS_VAULT_CONVERTER, - converters, -} from "../../../proposals/arbitrumsepolia/vip-016/Addresses"; -import CONVERTER_NETWORK_ABI from "./abi/ConverterNetwork.json"; -import ERC20_ABI from "./abi/ERC20.json"; -import PROTOCOL_SHARE_RESERVE_ABI from "./abi/ProtocolShareReserve.json"; -import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; -import XVS_VAULT_TREASURY_ABI from "./abi/XVSVaultTreasury.json"; +import vip016, { + MAX_DAILY_RECEIVE_LIMIT, + MAX_DAILY_SEND_LIMIT, + OP_SEPOLIA_TRUSTED_REMOTE, + SINGLE_RECEIVE_LIMIT, + SINGLE_SEND_LIMIT, +} from "../../../proposals/arbitrumsepolia/vip-016"; +import XVS_ABI from "./abi/xvs.json"; +import XVS_BRIDGE_ABI from "./abi/xvsProxyOFTDest.json"; -const { arbitrumsepolia } = NETWORK_ADDRESSES; const XVS = "0x877Dc896e7b13096D3827872e396927BbE704407"; -const XVS_VAULT = "0x407507DC2809D3aa31D54EcA3BEde5C5c4C8A17F"; -const USDT_HOLDER = "0x4e7ab1fD841E1387Df4c91813Ae03819C33D5bdB"; -const USDC_HOLDER = "0x4e7ab1fD841E1387Df4c91813Ae03819C33D5bdB"; -const USDT = "0xf3118a17863996B9F2A073c9A66Faaa664355cf8"; -const USDC = "0x86f096B1D970990091319835faF3Ee011708eAe8"; +const XVS_BRIDGE = "0xFdC5cEC63FD167DA46cF006585b30D03B104eFD4"; +const XVS_HOLDER = "0xFd7dA20ea0bE63ACb0852f97E950376E7E4a817D"; -const COMPTROLLER_CORE = "0x006D44b6f5927b3eD83bD0c1C36Fb1A3BaCaC208"; -const PLP = "0xE82c2c10F55D3268126C29ec813dC6F086904694"; -const PROTOCOL_SHARE_RESERVE_PROXY = "0x09267d30798B59c581ce54E861A084C6FC298666"; -const VTREASURY = "0x4e7ab1fD841E1387Df4c91813Ae03819C33D5bdB"; - -forking(94312350, async () => { - const provider = ethers.provider; - let converterNetwork: Contract; - let xvsVaultTreasury: Contract; - let protocolShareReserve: Contract; - let usdtPrimeConverter: Contract; - let usdcPrimeConverter: Contract; +forking(79930177, async () => { + let xvs: Contract; + let xvsBridge: Contract; + let xvsHolderSigner: SignerWithAddress; + let receiver: SignerWithAddress; + let receiverAddressBytes32: string; + let defaultAdapterParams: string; before(async () => { - usdcPrimeConverter = new ethers.Contract(USDC_PRIME_CONVERTER, SINGLE_TOKEN_CONVERTER_ABI, provider); - usdtPrimeConverter = new ethers.Contract(USDT_PRIME_CONVERTER, SINGLE_TOKEN_CONVERTER_ABI, provider); - - converterNetwork = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); - protocolShareReserve = new ethers.Contract(PROTOCOL_SHARE_RESERVE_PROXY, PROTOCOL_SHARE_RESERVE_ABI, provider); - xvsVaultTreasury = new ethers.Contract(XVS_VAULT_TREASURY, XVS_VAULT_TREASURY_ABI, provider); - - await pretendExecutingVip(await vip016()); - }); - - describe("Owner checks", () => { - it("Timelock should be the owner of all converters", async () => { - for (const converter of converters) { - const Converter = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); - expect(await Converter.owner()).to.equal(arbitrumsepolia.GUARDIAN); - } - }); - - it("Timelock should be the owner of ConverterNetwork", async () => { - expect(await converterNetwork.owner()).to.equal(arbitrumsepolia.GUARDIAN); - }); - - it("Timelock should be the owner of XVSVaultTreasury", async () => { - expect(await xvsVaultTreasury.owner()).to.equal(arbitrumsepolia.GUARDIAN); - }); + xvs = await ethers.getContractAt(XVS_ABI, XVS); + xvsBridge = await ethers.getContractAt(XVS_BRIDGE_ABI, XVS_BRIDGE); + xvsHolderSigner = await initMainnetUser(XVS_HOLDER, ethers.utils.parseEther("5")); + [receiver] = await ethers.getSigners(); + receiverAddressBytes32 = ethers.utils.defaultAbiCoder.encode(["address"], [receiver.address]); + defaultAdapterParams = ethers.utils.solidityPack(["uint16", "uint256"], [1, 300000]); }); - describe("Generic checks", () => { - let usdt: Contract; - let usdc: Contract; - let user1: Signer; - let usdtHolder: Signer; - let usdcHolder: Signer; - let user1Address: string; - - const amount = parseUnits("1000", 6); - + describe("Post-Execution state", () => { before(async () => { - usdt = new ethers.Contract(USDT, ERC20_ABI, provider); - usdc = new ethers.Contract(USDC, ERC20_ABI, provider); - - [, user1] = await ethers.getSigners(); - user1Address = await user1.getAddress(); - - usdcHolder = await initMainnetUser(USDC_HOLDER, ethers.utils.parseEther("1")); - usdtHolder = await initMainnetUser(USDT_HOLDER, ethers.utils.parseEther("1")); - - await usdt.connect(usdtHolder).transfer(user1Address, amount); - await usdc.connect(usdcHolder).transfer(user1Address, amount); - }); - - it("PSR should have correct distribution configs", async () => { - const percentageDistributionConverters = [500, 500, 300, 700, 2000]; - expect(await protocolShareReserve.totalDistributions()).to.equal(8); - - for (let i = 0; i < 5; i++) { - expect(await protocolShareReserve.getPercentageDistribution(converters[i], 0)).to.equal( - percentageDistributionConverters[i], - ); - } - - expect(await protocolShareReserve.getPercentageDistribution(VTREASURY, 0)).to.equal(6000); - expect(await protocolShareReserve.getPercentageDistribution(VTREASURY, 1)).to.equal(8000); - expect(await protocolShareReserve.getPercentageDistribution(XVS_VAULT_CONVERTER, 1)).to.equal(2000); + await pretendExecutingVip(await vip016()); }); - it("XVSVaultTreasury should have correct state variables", async () => { - expect(await xvsVaultTreasury.XVS_ADDRESS()).to.equal(XVS); - expect(await xvsVaultTreasury.xvsVault()).to.equal(XVS_VAULT); + it("Should match trusted remote address", async () => { + const trustedRemote = await xvsBridge.getTrustedRemoteAddress(LzChainId.opsepolia); + expect(trustedRemote).equals(OP_SEPOLIA_TRUSTED_REMOTE); }); - it("ConverterNetwork should contain all converters", async () => { - expect(await converterNetwork.getAllConverters()).to.deep.equal(converters); + it("Should match single send transaction limit", async () => { + expect(await xvsBridge.chainIdToMaxSingleTransactionLimit(LzChainId.opsepolia)).to.equal(SINGLE_SEND_LIMIT); }); - it("Convert exact tokens should work correctly", async () => { - const amountInMantissa = amount.div(2); - await usdt.connect(usdtHolder).transfer(user1Address, amount); - await usdc.connect(usdtHolder).transfer(USDT_PRIME_CONVERTER, amount); - - const usdcBalanceOfUsdtPrimeConverterPrevious = await usdtPrimeConverter.balanceOf(USDC); - const usdtBalanceOfUsdtPrimePrevious = await usdt.balanceOf(PLP); - const usdtBalanceOfUserPrevious = await usdt.balanceOf(user1Address); - - const [, amountOutMantissa] = await usdtPrimeConverter - .connect(user1) - .callStatic.getUpdatedAmountOut(amountInMantissa, USDT, USDC); - - await usdt.connect(user1).approve(USDT_PRIME_CONVERTER, amountInMantissa); - await usdtPrimeConverter - .connect(user1) - .convertExactTokens(amountInMantissa, amountInMantissa.div(2), USDT, USDC, user1Address); - - expect(await usdt.balanceOf(user1Address)).to.equal(usdtBalanceOfUserPrevious.sub(amountInMantissa)); - expect(await usdtPrimeConverter.balanceOf(USDT)).to.equal(0); - expect(await usdtPrimeConverter.balanceOf(USDC)).to.equal( - usdcBalanceOfUsdtPrimeConverterPrevious.sub(amountOutMantissa), + it("Should match single receive transaction limit", async () => { + expect(await xvsBridge.chainIdToMaxSingleReceiveTransactionLimit(LzChainId.opsepolia)).to.equal( + SINGLE_RECEIVE_LIMIT, ); - expect(await usdt.balanceOf(PLP)).to.equal(BigNumber.from(usdtBalanceOfUsdtPrimePrevious).add(amountInMantissa)); }); - it("ConvertForExactTokens should work properly", async () => { - await usdc.connect(usdcHolder).transfer(user1Address, amount); - await usdc.connect(user1).transfer(USDT_PRIME_CONVERTER, amount); - - const amountOutMantissa = amount.div(2); - const amountInMaxMantissa = amount; - await usdt.connect(usdtHolder).transfer(user1Address, amount); - - const usdcBalanceOfUsdtPrimeConverterPrevious = await usdtPrimeConverter.balanceOf(USDC); - const usdtBalanceOfUsdtPrimePrevious = await usdt.balanceOf(PLP); - const usdtBalanceOfUserPrevious = await usdt.balanceOf(user1Address); - - const [, amountInMantissa] = await usdtPrimeConverter.connect(user1).getAmountIn(amountOutMantissa, USDT, USDC); - - await usdt.connect(user1).approve(USDT_PRIME_CONVERTER, amount); - await usdtPrimeConverter - .connect(user1) - .convertForExactTokens(amountInMaxMantissa, amountOutMantissa, USDT, USDC, user1Address); - - expect(await usdt.balanceOf(user1Address)).to.equal(usdtBalanceOfUserPrevious.sub(amountInMantissa)); - expect(await usdtPrimeConverter.balanceOf(USDT)).to.equal(0); - expect(await usdtPrimeConverter.balanceOf(USDC)).to.equal( - usdcBalanceOfUsdtPrimeConverterPrevious.sub(amountOutMantissa), - ); - expect(await usdt.balanceOf(PLP)).to.equal(BigNumber.from(usdtBalanceOfUsdtPrimePrevious).add(amountInMantissa)); + it("Should match max daily send limit", async () => { + expect(await xvsBridge.chainIdToMaxDailyLimit(LzChainId.opsepolia)).to.equal(MAX_DAILY_SEND_LIMIT); }); - it("Private conversion should occur on updateAssetsState", async () => { - const newAmount = amount.mul(2); - await usdc.connect(usdcHolder).transfer(user1Address, newAmount); - await usdt.connect(usdtHolder).transfer(user1Address, newAmount); - - const destinationAddressForUsdcConverter = await usdcPrimeConverter.destinationAddress(); - - await usdc.connect(user1).transfer(USDT_PRIME_CONVERTER, amount); - await usdtPrimeConverter.connect(user1).updateAssetsState(COMPTROLLER_CORE, USDC); - - const usdcBalanceUsdtPrimeConverterPrevious = await usdtPrimeConverter.balanceOf(USDC); - const usdtBalanceUsdtPrimePrevious = await usdt.balanceOf(PLP); - - const plpBalanceForUsdcPrevious = await usdc.balanceOf(destinationAddressForUsdcConverter); - await usdt.connect(user1).transfer(USDC_PRIME_CONVERTER, amount); - - // Private Conversion will occur - await usdcPrimeConverter.connect(user1).updateAssetsState(COMPTROLLER_CORE, USDT); - - const usdcBalanceUsdtPrimeConverterCurrent = await usdtPrimeConverter.balanceOf(USDC); - const usdtBalanceUsdtPrimeCurrent = await usdt.balanceOf(PLP); + it("Should match max daily receive limit", async () => { + expect(await xvsBridge.chainIdToMaxDailyReceiveLimit(LzChainId.opsepolia)).to.equal(MAX_DAILY_RECEIVE_LIMIT); + }); - expect(usdtBalanceUsdtPrimeCurrent).to.equal(usdtBalanceUsdtPrimePrevious.add(amount)); - expect(usdcBalanceUsdtPrimeConverterCurrent).to.closeTo( - usdcBalanceUsdtPrimeConverterPrevious.sub(amount), - parseUnits("1", 7), - ); - expect(await usdc.balanceOf(destinationAddressForUsdcConverter)).to.closeTo( - plpBalanceForUsdcPrevious.add(amount), - parseUnits("1", 7), - ); + it("Should emit an event on successful bridging of XVS (Arbitrum sepolia -> Op Sepolia)", async () => { + const amount = parseUnits("1", 18); + const nativeFee = ( + await xvsBridge.estimateSendFee( + LzChainId.opsepolia, + receiverAddressBytes32, + amount, + false, + defaultAdapterParams, + ) + ).nativeFee; + + const circulatingSupplyBefore = await xvsBridge.circulatingSupply(); + const totalSupplyBefore = await xvs.totalSupply(); + const minterToMintedAmountBefore = await xvs.minterToMintedAmount(XVS_BRIDGE); + + await expect( + xvsBridge + .connect(xvsHolderSigner) + .sendFrom( + xvsHolderSigner.address, + LzChainId.opsepolia, + receiverAddressBytes32, + amount, + [xvsHolderSigner.address, ethers.constants.AddressZero, defaultAdapterParams], + { value: nativeFee }, + ), + ) + .to.be.emit(xvsBridge, "SendToChain") + .withArgs(LzChainId.opsepolia, XVS_HOLDER, receiverAddressBytes32, amount); + + const circulatingSupplyAfter = await xvsBridge.circulatingSupply(); + const totalSupplyAfter = await xvs.totalSupply(); + const minterToMintedAmountAfter = await xvs.minterToMintedAmount(XVS_BRIDGE); + + expect(circulatingSupplyBefore).equals(circulatingSupplyAfter.add(amount)); + expect(totalSupplyBefore).equals(totalSupplyAfter.add(amount)); + expect(minterToMintedAmountBefore).equals(minterToMintedAmountAfter.add(amount)); }); }); }); diff --git a/multisig/simulations/arbitrumsepolia/vip-015/abi/ILComptroller.json b/multisig/simulations/arbitrumsepolia/vip-018/abi/ILComptroller.json similarity index 100% rename from multisig/simulations/arbitrumsepolia/vip-015/abi/ILComptroller.json rename to multisig/simulations/arbitrumsepolia/vip-018/abi/ILComptroller.json diff --git a/multisig/simulations/arbitrumsepolia/vip-015/abi/Prime.json b/multisig/simulations/arbitrumsepolia/vip-018/abi/Prime.json similarity index 100% rename from multisig/simulations/arbitrumsepolia/vip-015/abi/Prime.json rename to multisig/simulations/arbitrumsepolia/vip-018/abi/Prime.json diff --git a/multisig/simulations/arbitrumsepolia/vip-015/abi/PrimeLiquidityProvider.json b/multisig/simulations/arbitrumsepolia/vip-018/abi/PrimeLiquidityProvider.json similarity index 100% rename from multisig/simulations/arbitrumsepolia/vip-015/abi/PrimeLiquidityProvider.json rename to multisig/simulations/arbitrumsepolia/vip-018/abi/PrimeLiquidityProvider.json diff --git a/multisig/simulations/arbitrumsepolia/vip-015/index.ts b/multisig/simulations/arbitrumsepolia/vip-018/index.ts similarity index 95% rename from multisig/simulations/arbitrumsepolia/vip-015/index.ts rename to multisig/simulations/arbitrumsepolia/vip-018/index.ts index 4a3edb40f..edface965 100644 --- a/multisig/simulations/arbitrumsepolia/vip-015/index.ts +++ b/multisig/simulations/arbitrumsepolia/vip-018/index.ts @@ -4,7 +4,7 @@ import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { forking, pretendExecutingVip } from "src/vip-framework"; -import vip015, { +import vip018, { COMPTROLLER_CORE, COMPTROLLER_LST, PLP, @@ -13,7 +13,7 @@ import vip015, { USDT, WBTC, WETH, -} from "../../../proposals/arbitrumsepolia/vip-015"; +} from "../../../proposals/arbitrumsepolia/vip-018"; import COMPTROLLER_ABI from "./abi/ILComptroller.json"; import PRIME_ABI from "./abi/Prime.json"; import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; @@ -51,7 +51,7 @@ forking(95153347, async () => { let plp: Contract; before(async () => { - await pretendExecutingVip(await vip015()); + await pretendExecutingVip(await vip018()); prime = new ethers.Contract(PRIME, PRIME_ABI, provider); plp = new ethers.Contract(PLP, PLP_ABI, provider); diff --git a/multisig/simulations/arbitrumsepolia/vip-016/abi/ConverterNetwork.json b/multisig/simulations/arbitrumsepolia/vip-019/abi/ConverterNetwork.json similarity index 100% rename from multisig/simulations/arbitrumsepolia/vip-016/abi/ConverterNetwork.json rename to multisig/simulations/arbitrumsepolia/vip-019/abi/ConverterNetwork.json diff --git a/multisig/simulations/arbitrumsepolia/vip-016/abi/SingleTokenConverter.json b/multisig/simulations/arbitrumsepolia/vip-019/abi/SingleTokenConverter.json similarity index 100% rename from multisig/simulations/arbitrumsepolia/vip-016/abi/SingleTokenConverter.json rename to multisig/simulations/arbitrumsepolia/vip-019/abi/SingleTokenConverter.json diff --git a/multisig/simulations/arbitrumsepolia/vip-016/abi/XVSVaultTreasury.json b/multisig/simulations/arbitrumsepolia/vip-019/abi/XVSVaultTreasury.json similarity index 100% rename from multisig/simulations/arbitrumsepolia/vip-016/abi/XVSVaultTreasury.json rename to multisig/simulations/arbitrumsepolia/vip-019/abi/XVSVaultTreasury.json diff --git a/multisig/simulations/arbitrumsepolia/vip-019/index.ts b/multisig/simulations/arbitrumsepolia/vip-019/index.ts new file mode 100644 index 000000000..520b620fd --- /dev/null +++ b/multisig/simulations/arbitrumsepolia/vip-019/index.ts @@ -0,0 +1,68 @@ +/* eslint-disable @typescript-eslint/no-unused-vars */ +import { expect } from "chai"; +import { BigNumber, Contract, Signer } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { initMainnetUser } from "src/utils"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip019, { XVS_VAULT_TREASURY } from "../../../proposals/arbitrumsepolia/vip-019"; +import { + CONVERTER_NETWORK, + USDC_PRIME_CONVERTER, + USDT_PRIME_CONVERTER, + XVS_VAULT_CONVERTER, + converters, +} from "../../../proposals/arbitrumsepolia/vip-019/Addresses"; +import CONVERTER_NETWORK_ABI from "./abi/ConverterNetwork.json"; +import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; +import XVS_VAULT_TREASURY_ABI from "./abi/XVSVaultTreasury.json"; + +const { arbitrumsepolia } = NETWORK_ADDRESSES; +const XVS = "0x877Dc896e7b13096D3827872e396927BbE704407"; +const XVS_VAULT = "0x407507DC2809D3aa31D54EcA3BEde5C5c4C8A17F"; + +forking(94312350, async () => { + const provider = ethers.provider; + let converterNetwork: Contract; + let xvsVaultTreasury: Contract; + + before(async () => { + converterNetwork = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); + xvsVaultTreasury = new ethers.Contract(XVS_VAULT_TREASURY, XVS_VAULT_TREASURY_ABI, provider); + + await pretendExecutingVip(await vip019()); + }); + + describe("Owner checks", () => { + it("Timelock should be the owner of all converters", async () => { + for (const converter of converters) { + const Converter = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); + expect(await Converter.owner()).to.equal(arbitrumsepolia.GUARDIAN); + } + }); + + it("Timelock should be the owner of ConverterNetwork", async () => { + expect(await converterNetwork.owner()).to.equal(arbitrumsepolia.GUARDIAN); + }); + + it("Timelock should be the owner of XVSVaultTreasury", async () => { + expect(await xvsVaultTreasury.owner()).to.equal(arbitrumsepolia.GUARDIAN); + }); + }); + + describe("Generic checks", () => { + it("XVSVaultTreasury should have correct state variables", async () => { + expect(await xvsVaultTreasury.XVS_ADDRESS()).to.equal(XVS); + expect(await xvsVaultTreasury.xvsVault()).to.equal(XVS_VAULT); + }); + + it("Converters should belong to the same ConverterNetwork", async () => { + for (const converter of converters) { + const Converter = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); + expect(await Converter.converterNetwork()).to.equal(CONVERTER_NETWORK); + } + }); + }); +}); diff --git a/multisig/simulations/arbitrumsepolia/vip-016/abi/ERC20.json b/simulations/vip-395/abi/ERC20.json similarity index 100% rename from multisig/simulations/arbitrumsepolia/vip-016/abi/ERC20.json rename to simulations/vip-395/abi/ERC20.json diff --git a/simulations/vip-395/abi/OmnichainProposalSender.json b/simulations/vip-395/abi/OmnichainProposalSender.json new file mode 100644 index 000000000..66fd4df02 --- /dev/null +++ b/simulations/vip-395/abi/OmnichainProposalSender.json @@ -0,0 +1,314 @@ +[ + { + "inputs": [ + { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } + ], + "name": "ClearPayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } + ], + "name": "ExecuteRemoteProposal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "FallbackWithdraw", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } + ], + "name": "StorePayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], + "name": "TrustedRemoteRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "LZ_ENDPOINT", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourCommandsSent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLastProposalSentTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bool", "name": "useZro_", "type": "bool" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } + ], + "name": "estimateFees", + "outputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } + ], + "name": "execute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "fallbackWithdraw", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "proposalCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], + "name": "removeTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "retryExecute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" }, + { "internalType": "bytes", "name": "config_", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "storedExecutionHashes", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } +] diff --git a/multisig/simulations/arbitrumsepolia/vip-016/abi/ProtocolShareReserve.json b/simulations/vip-395/abi/ProtocolShareReserve.json similarity index 100% rename from multisig/simulations/arbitrumsepolia/vip-016/abi/ProtocolShareReserve.json rename to simulations/vip-395/abi/ProtocolShareReserve.json diff --git a/simulations/vip-395/arbitrumsepolia.ts b/simulations/vip-395/arbitrumsepolia.ts index 38a41c0e1..5e398faab 100644 --- a/simulations/vip-395/arbitrumsepolia.ts +++ b/simulations/vip-395/arbitrumsepolia.ts @@ -6,20 +6,18 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents, initMainnetUser } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip015 from "../../multisig/proposals/arbitrumsepolia/vip-015"; -import vip016, { XVS_VAULT_TREASURY } from "../../multisig/proposals/arbitrumsepolia/vip-016"; +import vip018 from "../../multisig/proposals/arbitrumsepolia/vip-018"; +import vip019, { XVS_VAULT_TREASURY } from "../../multisig/proposals/arbitrumsepolia/vip-019"; import { CONVERTER_NETWORK, USDC_PRIME_CONVERTER, USDT_PRIME_CONVERTER, XVS_VAULT_CONVERTER, converters, -} from "../../multisig/proposals/arbitrumsepolia/vip-016/Addresses"; -import CONVERTER_NETWORK_ABI from "../../multisig/simulations/arbitrumsepolia/vip-016/abi/ConverterNetwork.json"; -import ERC20_ABI from "../../multisig/simulations/arbitrumsepolia/vip-016/abi/ERC20.json"; -import PROTOCOL_SHARE_RESERVE_ABI from "../../multisig/simulations/arbitrumsepolia/vip-016/abi/ProtocolShareReserve.json"; -import SINGLE_TOKEN_CONVERTER_ABI from "../../multisig/simulations/arbitrumsepolia/vip-016/abi/SingleTokenConverter.json"; -import XVS_VAULT_TREASURY_ABI from "../../multisig/simulations/arbitrumsepolia/vip-016/abi/XVSVaultTreasury.json"; +} from "../../multisig/proposals/arbitrumsepolia/vip-019/Addresses"; +import CONVERTER_NETWORK_ABI from "../../multisig/simulations/arbitrumsepolia/vip-019/abi/ConverterNetwork.json"; +import SINGLE_TOKEN_CONVERTER_ABI from "../../multisig/simulations/arbitrumsepolia/vip-019/abi/SingleTokenConverter.json"; +import XVS_VAULT_TREASURY_ABI from "../../multisig/simulations/arbitrumsepolia/vip-019/abi/XVSVaultTreasury.json"; import vip395, { ARBITRUM_SEPOLIA_COMPTROLLER_CORE, ARBITRUM_SEPOLIA_COMPTROLLER_LST, @@ -34,9 +32,11 @@ import vip395, { ARBITRUM_SEPOLIA_WBTC, ARBITRUM_SEPOLIA_WETH, } from "../../vips/vip-395/bsctestnet"; +import ERC20_ABI from "./abi/ERC20.json"; import COMPTROLLER_ABI from "./abi/ILComptroller.json"; import PRIME_ABI from "./abi/Prime.json"; import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; +import PROTOCOL_SHARE_RESERVE_ABI from "./abi/ProtocolShareReserve.json"; const { arbitrumsepolia } = NETWORK_ADDRESSES; const XVS = "0x877Dc896e7b13096D3827872e396927BbE704407"; @@ -70,8 +70,8 @@ forking(96329874, async () => { ); xvsVaultTreasury = new ethers.Contract(XVS_VAULT_TREASURY, XVS_VAULT_TREASURY_ABI, provider); - await pretendExecutingVip(await vip015()); - await pretendExecutingVip(await vip016()); + await pretendExecutingVip(await vip018()); + await pretendExecutingVip(await vip019()); }); describe("Pre-VIP behaviour", () => { diff --git a/simulations/vip-395/bsctestnet.ts b/simulations/vip-395/bsctestnet.ts index d412ccd28..17e68e93a 100644 --- a/simulations/vip-395/bsctestnet.ts +++ b/simulations/vip-395/bsctestnet.ts @@ -1,7 +1,17 @@ -import { forking, testVip } from "src/vip-framework"; - +import { expectEvents } from "../../src/utils"; +import { forking, testVip } from "../../src/vip-framework"; import vip395 from "../../vips/vip-395/bsctestnet"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; -forking(45439039, async () => { - testVip("vip395 arbitrum sepolia Prime configuration", await vip395()); +forking(45736960, async () => { + testVip("vip395 arbitrum sepolia Prime configuration", await vip395(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [1, 0], + ); + }, + }); }); diff --git a/vips/vip-395/bsctestnet.ts b/vips/vip-395/bsctestnet.ts index 6c65473b3..7d55581f5 100644 --- a/vips/vip-395/bsctestnet.ts +++ b/vips/vip-395/bsctestnet.ts @@ -17,16 +17,14 @@ import { WETH_PRIME_CONVERTER, XVSVaultConverterTokenOuts, XVS_VAULT_CONVERTER, -} from "../../multisig/proposals/arbitrumsepolia/vip-016/Addresses"; +} from "../../multisig/proposals/arbitrumsepolia/vip-019/Addresses"; import { addConverterNetworkCommands, incentiveAndAccessibilities, -} from "../../multisig/proposals/arbitrumsepolia/vip-016/commands"; +} from "../../multisig/proposals/arbitrumsepolia/vip-019/commands"; const { arbitrumsepolia } = NETWORK_ADDRESSES; -export const OMNICHAIN_PROPOSAL_SENDER = "0xCfD34AEB46b1CB4779c945854d405E91D27A1899"; - export const ARBITRUM_SEPOLIA_COMPTROLLER_CORE = "0x006D44b6f5927b3eD83bD0c1C36Fb1A3BaCaC208"; export const ARBITRUM_SEPOLIA_COMPTROLLER_LST = "0x3D04F926b2a165BBa17FBfccCCB61513634fa5e4"; export const ARBITRUM_SEPOLIA_PRIME = "0xAdB04AC4942683bc41E27d18234C8DC884786E89"; @@ -36,9 +34,6 @@ export const ARBITRUM_SEPOLIA_USDT = "0xf3118a17863996B9F2A073c9A66Faaa664355cf8 export const ARBITRUM_SEPOLIA_USDC = "0x86f096B1D970990091319835faF3Ee011708eAe8"; export const ARBITRUM_SEPOLIA_WBTC = "0xFb8d93FD3Cf18386a5564bb5619cD1FdB130dF7D"; export const ARBITRUM_SEPOLIA_WETH = "0x980B62Da83eFf3D4576C647993b0c1D7faf17c73"; -export const ARBITRUM_SEPOLIA_PRIME_NEW_IMPLEMENTATION = "0x507866eCb585275E006D9098867a0e9B08C11CCe"; // contains the setter for the pool registry address -export const ARBITRUM_SEPOLIA_PRIME_OLD_IMPLEMENTATION = "0x255EFC81Ba715FA7C2C27bdd983A3CeF9BB07fEf"; -export const ARBITRUM_SEPOLIA_PROXY_ADMIN = "0xA78A1Df376c3CEeBC5Fab574fe6EdDbbF76fd03e"; export const ARBITRUM_SEPOLIA_VUSDT_CORE = "0xdEFbf0F9Ab6CdDd0a1FdDC894b358D0c0a39B052"; export const ARBITRUM_SEPOLIA_VUSDC_CORE = "0xd9d1e754464eFc7493B177d2c7be04816E089b4C"; @@ -49,12 +44,10 @@ export const ARBITRUM_SEPOLIA_XVS_VAULT_TREASURY = "0x309b71a417dA9CfA8aC47e6038 export const ARBITRUM_SEPOLIA_PROTOCOL_SHARE_RESERVE_PROXY = "0x09267d30798B59c581ce54E861A084C6FC298666"; export const ARBITRUM_SEPOLIA_VTREASURY = "0x4e7ab1fD841E1387Df4c91813Ae03819C33D5bdB"; -export const MAX_DAILY_LIMIT = 100; - const vip395 = () => { const meta = { version: "v2", - title: "vip395", + title: "vip395 arbitrum sepolia Prime configuration", description: `#### Description This VIP will grant permission to timelocks and performs the necessary configuration of OmnichainProposalSender on BNB chain and OmnichainProposalExecutor on SEPOLIA & OPBNBTESTNET chains`, forDescription: "I agree that Venus Protocol should proceed with this proposal", From 9ddc691600128d1cbc15a8e81d244246c2163ff0 Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Sat, 16 Nov 2024 08:53:34 +0300 Subject: [PATCH 148/178] feat: update BNBx oracle and reenable the markets --- simulations/vip-397/abi/comptroller.json | 929 +++++++++++++++++++ simulations/vip-397/abi/resilientOracle.json | 640 +++++++++++++ simulations/vip-397/bscmainnet.ts | 107 +++ vips/vip-397/bscmainnet.ts | 84 ++ 4 files changed, 1760 insertions(+) create mode 100644 simulations/vip-397/abi/comptroller.json create mode 100644 simulations/vip-397/abi/resilientOracle.json create mode 100644 simulations/vip-397/bscmainnet.ts create mode 100644 vips/vip-397/bscmainnet.ts diff --git a/simulations/vip-397/abi/comptroller.json b/simulations/vip-397/abi/comptroller.json new file mode 100644 index 000000000..56890d9b3 --- /dev/null +++ b/simulations/vip-397/abi/comptroller.json @@ -0,0 +1,929 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum ComptrollerStorage.Action", "name": "action", "type": "uint8" } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, + { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, + { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, + { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, + { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, + { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "TooMuchRepay", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "expectedSender", "type": "address" }, + { "internalType": "address", "name": "actualSender", "type": "address" } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "enum ComptrollerStorage.Action", "name": "action", "type": "uint8" }, + { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "accountAssets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum ComptrollerStorage.Action", "name": "action", "type": "uint8" } + ], + "name": "actionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allMarkets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "approvedDelegates", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "borrowCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "contract VToken", "name": "vToken", "type": "address" } + ], + "name": "checkMembership", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], + "name": "enterMarkets", + "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], + "name": "exitMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAssetsIn", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getBorrowingPower", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "vTokenModify", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isForcedLiquidationEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "isMarketListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [ + { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "bool", "name": "isListed", "type": "bool" }, + { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "seizerContract", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, + { "internalType": "enum ComptrollerStorage.Action[]", "name": "actionsList", "type": "uint8[]" }, + { "internalType": "bool", "name": "paused", "type": "bool" } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "supplyCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "delegate", "type": "address" }, + { "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-397/abi/resilientOracle.json b/simulations/vip-397/abi/resilientOracle.json new file mode 100644 index 000000000..fc9c7a5e3 --- /dev/null +++ b/simulations/vip-397/abi/resilientOracle.json @@ -0,0 +1,640 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "vBnbAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + }, + { + "internalType": "contract BoundValidatorInterface", + "name": "_boundValidator", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "mainOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "pivotOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "fallbackOracle", + "type": "address" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "BNB_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [ + { + "internalType": "contract BoundValidatorInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "getOracle", + "outputs": [ + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "bool", + "name": "enabled", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vBnb", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-397/bscmainnet.ts b/simulations/vip-397/bscmainnet.ts new file mode 100644 index 000000000..86c84bcef --- /dev/null +++ b/simulations/vip-397/bscmainnet.ts @@ -0,0 +1,107 @@ +import { expect } from "chai"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { expectEvents, setMaxStalePeriodInChainlinkOracle } from "src/utils"; +import { forking, testVip } from "src/vip-framework"; + +import vip397, { Actions, LST_BNB_COMPTROLLER, RESILIENT_ORACLE } from "../../vips/vip-397/bscmainnet"; +import COMPTROLLER_ABI from "./abi/comptroller.json"; +import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; + +const NATIVE_TOKEN_ADDR = "0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB"; +const CHAINLINK_ORACLE = "0x1B2103441A0A108daD8848D8F5d790e4D402921F"; +const BNB_FEED = "0x0567F2323251f0Aab15c8dFb1967E4e8A7D42aeE"; +const NORMAL_TIMELOCK = "0x939bD8d64c0A9583A7Dcea9933f7b21697ab6396"; + +const BNBX = "0x1bdd3cf7f79cfb8edbb955f20ad99211551ba275"; +const BNBX_VTOKEN = "0x5E21bF67a6af41c74C1773E4b473ca5ce8fd3791"; +const ANKRBNB_VTOKEN = "0xBfe25459BA784e70E2D7a718Be99a1f3521cA17f"; +const SLISBNB_VTOKEN = "0xd3CC9d8f3689B83c91b7B59cAB4946B063EB894A"; +const WBNB_VTOKEN = "0xe10E80B7FD3a29fE46E16C30CC8F4dd938B742e2"; + +forking(44051250, async () => { + const oracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, ethers.provider); + const comptroller = new ethers.Contract(LST_BNB_COMPTROLLER, COMPTROLLER_ABI, ethers.provider); + + describe("Pre-VIP behavior", async () => { + it("check BNBx price", async () => { + const price = await oracle.getPrice(BNBX); + expect(price).to.be.equal(parseUnits("836.031062608011472369", "18")); + }); + + describe("BNBx actions", () => { + it("mint paused", async () => { + expect(await comptroller.actionPaused(BNBX_VTOKEN, Actions.MINT)).to.equal(true); + }); + + it("borrow paused", async () => { + expect(await comptroller.actionPaused(BNBX_VTOKEN, Actions.BORROW)).to.equal(true); + }); + + it("enter market paused", async () => { + expect(await comptroller.actionPaused(BNBX_VTOKEN, Actions.ENTER_MARKET)).to.equal(true); + }); + }); + + describe("Borrows on other markets", () => { + it("ankrBNB borrows paused", async () => { + expect(await comptroller.actionPaused(ANKRBNB_VTOKEN, Actions.BORROW)).to.equal(true); + }); + + it("slisBNB borrows paused", async () => { + expect(await comptroller.actionPaused(SLISBNB_VTOKEN, Actions.BORROW)).to.equal(true); + }); + + it("WBNB borrows paused", async () => { + expect(await comptroller.actionPaused(WBNB_VTOKEN, Actions.BORROW)).to.equal(true); + }); + }); + }); + + testVip("VIP-397", await vip397(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [RESILIENT_ORACLE_ABI], ["TokenConfigAdded"], [1]); + await expectEvents(txResponse, [COMPTROLLER_ABI], ["ActionPausedMarket"], [6]); + }, + }); + + describe("Post-VIP behavior", async () => { + before(async () => { + await setMaxStalePeriodInChainlinkOracle(CHAINLINK_ORACLE, NATIVE_TOKEN_ADDR, BNB_FEED, NORMAL_TIMELOCK); + }); + + it("check BNBx price", async () => { + const price = parseUnits("682.912935326188597512", 18); + expect(await oracle.getPrice(BNBX)).to.equal(price); + expect(await oracle.getUnderlyingPrice(BNBX_VTOKEN)).to.equal(price); + }); + + describe("BNBx actions", () => { + it("mint unpaused", async () => { + expect(await comptroller.actionPaused(BNBX_VTOKEN, Actions.MINT)).to.equal(false); + }); + + it("borrow unpaused", async () => { + expect(await comptroller.actionPaused(BNBX_VTOKEN, Actions.BORROW)).to.equal(false); + }); + + it("enter market unpaused", async () => { + expect(await comptroller.actionPaused(BNBX_VTOKEN, Actions.ENTER_MARKET)).to.equal(false); + }); + }); + + describe("Borrows on other markets", () => { + it("ankrBNB borrows unpaused", async () => { + expect(await comptroller.actionPaused(ANKRBNB_VTOKEN, Actions.BORROW)).to.equal(false); + }); + + it("slisBNB borrows unpaused", async () => { + expect(await comptroller.actionPaused(SLISBNB_VTOKEN, Actions.BORROW)).to.equal(false); + }); + + it("WBNB borrows unpaused", async () => { + expect(await comptroller.actionPaused(WBNB_VTOKEN, Actions.BORROW)).to.equal(false); + }); + }); + }); +}); diff --git a/vips/vip-397/bscmainnet.ts b/vips/vip-397/bscmainnet.ts new file mode 100644 index 000000000..45f228606 --- /dev/null +++ b/vips/vip-397/bscmainnet.ts @@ -0,0 +1,84 @@ +import { ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const SLISBNB_VTOKEN = "0xd3CC9d8f3689B83c91b7B59cAB4946B063EB894A"; +export const WBNB_VTOKEN = "0xe10E80B7FD3a29fE46E16C30CC8F4dd938B742e2"; +export const BNBX_VTOKEN = "0x5E21bF67a6af41c74C1773E4b473ca5ce8fd3791"; +export const ANKRBNB_VTOKEN = "0xBfe25459BA784e70E2D7a718Be99a1f3521cA17f"; +export const LST_BNB_COMPTROLLER = "0xd933909A4a2b7A4638903028f44D1d38ce27c352"; + +export const RESILIENT_ORACLE = "0x6592b5DE802159F3E74B2486b091D11a8256ab8A"; +export const BNBX = "0x1bdd3cf7f79cfb8edbb955f20ad99211551ba275"; +export const BNBX_ORACLE = "0x94f30dC18D12C210E5ae32752B1033afdd89D5DB"; + +export const Actions = { + MINT: 0, + BORROW: 2, + ENTER_MARKET: 7, +}; + +const vip397 = () => { + const meta = { + version: "v2", + title: "VIP-397 BNBx Oracle implementation upgrade", + description: `#### Summary + +This proposal, if approved, will upgrade the implementation of the BNBx Oracle contract on Venus from version 1 (V1) to version 2 (V2), aligning with the latest BNBx stake manager contract recently deployed by Stader Labs. + +#### Description + +Stader Labs has updated their ecosystem by migrating several of their key contracts, including the stake manager contract associated with BNBx. As part of this migration, a new price oracle contract has been introduced for BNBx, designed to improve reliability and compatibility with the updated infrastructure. + +The proposed upgrade involves replacing the existing BNBx Oracle contract on Venus with the new V2 contract to ensure continued accuracy in pricing and compatibility with the underlying infrastructure. + +This upgrade does not modify the protocol’s functionality beyond the scope of the oracle and its interaction with the broader ecosystem. Key features of the V2 contract include: + +- Improved price accuracy mechanisms. +- Compatibility with Stader Labs’ latest deployment architecture. + +#### Security and additional considerations + +To ensure the safety and reliability of this upgrade, the following measures were taken: + +* **Behavior Validation in Simulation Environment** + + The upgraded oracle contract was extensively tested in a simulation environment. Tests confirmed that the price feed accuracy and update frequency function as intended, with no discrepancies observed post-upgrade. + +* **Independent Audits by Stader Labs** + + Stader Labs conducted security audits of the V2 oracle contract as part of their migration process, ensuring that all vulnerabilities identified in prior versions were addressed.`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + + return makeProposal( + [ + { + target: RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [ + BNBX, + [BNBX_ORACLE, "0x0000000000000000000000000000000000000000", "0x0000000000000000000000000000000000000000"], + [true, false, false], + ], + ], + }, + { + target: LST_BNB_COMPTROLLER, + signature: "setActionsPaused(address[],uint8[],bool)", + params: [[SLISBNB_VTOKEN, ANKRBNB_VTOKEN, WBNB_VTOKEN], [Actions.BORROW], false], + }, + { + target: LST_BNB_COMPTROLLER, + signature: "setActionsPaused(address[],uint8[],bool)", + params: [[BNBX_VTOKEN], [Actions.MINT, Actions.BORROW, Actions.ENTER_MARKET], false], + }, + ], + meta, + ProposalType.CRITICAL, + ); +}; + +export default vip397; From 7db29e248a6ff02869a32f8ea80ddeeda1d7fb34 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Wed, 20 Nov 2024 21:57:08 +0530 Subject: [PATCH 149/178] feat: prime and converters configurations on arbitrum one --- .../arbitrumone/vip-018/addresses.ts | 45 + .../proposals/arbitrumone/vip-018/commands.ts | 100 + .../proposals/arbitrumone/vip-018/index.ts | 33 + .../vip-018/abi/ConverterNetwork.json | 448 +++++ .../vip-018/abi/ILComptroller.json | 929 +++++++++ .../arbitrumone/vip-018/abi/Prime.json | 1787 +++++++++++++++++ .../vip-018/abi/PrimeLiquidityProvider.json | 385 ++++ .../vip-018/abi/SingleTokenConverter.json | 1381 +++++++++++++ .../vip-018/abi/XVSVaultTreasury.json | 306 +++ .../simulations/arbitrumone/vip-018/index.ts | 105 + 10 files changed, 5519 insertions(+) create mode 100644 multisig/proposals/arbitrumone/vip-018/addresses.ts create mode 100644 multisig/proposals/arbitrumone/vip-018/commands.ts create mode 100644 multisig/proposals/arbitrumone/vip-018/index.ts create mode 100644 multisig/simulations/arbitrumone/vip-018/abi/ConverterNetwork.json create mode 100644 multisig/simulations/arbitrumone/vip-018/abi/ILComptroller.json create mode 100644 multisig/simulations/arbitrumone/vip-018/abi/Prime.json create mode 100644 multisig/simulations/arbitrumone/vip-018/abi/PrimeLiquidityProvider.json create mode 100644 multisig/simulations/arbitrumone/vip-018/abi/SingleTokenConverter.json create mode 100644 multisig/simulations/arbitrumone/vip-018/abi/XVSVaultTreasury.json create mode 100644 multisig/simulations/arbitrumone/vip-018/index.ts diff --git a/multisig/proposals/arbitrumone/vip-018/addresses.ts b/multisig/proposals/arbitrumone/vip-018/addresses.ts new file mode 100644 index 000000000..d3fb77412 --- /dev/null +++ b/multisig/proposals/arbitrumone/vip-018/addresses.ts @@ -0,0 +1,45 @@ +export const USDT = "0xfd086bc7cd5c481dcc9c85ebe478a1c0b69fcbb9"; +export const USDC = "0xaf88d065e77c8cc2239327c5edb3a432268e5831"; +export const WBTC = "0x2f2a2543b76a4166549f7aab2e75bef0aefc5b0f"; +export const WETH = "0x82af49447d8a07e3bd95bd0d56f35241523fbab1"; +export const PLP = "0x86bf21dB200f29F21253080942Be8af61046Ec29"; +export const XVS = "0xc1Eb7689147C81aC840d4FF0D298489fc7986d52"; +export const XVS_VAULT_TREASURY = "0xb076D4f15c08D7A7B89466327Ba71bc7e1311b58"; + +export const Assets = [USDT, USDC, WBTC, WETH, XVS]; + +export const BaseAssets = [ + USDT, // USDTPrimeConverter BaseAsset + USDC, // USDCPrimeConverter BaseAsset + WBTC, // WBTCPrimeConverter BaseAsset + WETH, // WETHPrimeConverter BaseAsset + XVS, // XVSPrimeConverter BaseAsset +]; + +export const CONVERTER_NETWORK = "0x2F6672C9A0988748b0172D97961BecfD9DC6D6d5"; +export const USDT_PRIME_CONVERTER = "0x435Fac1B002d5D31f374E07c0177A1D709d5DC2D"; +export const USDC_PRIME_CONVERTER = "0x6553C9f9E131191d4fECb6F0E73bE13E229065C6"; +export const WBTC_PRIME_CONVERTER = "0xF91369009c37f029aa28AF89709a352375E5A162"; +export const WETH_PRIME_CONVERTER = "0x4aCB90ddD6df24dC6b0D50df84C94e72012026d0"; +export const XVS_VAULT_CONVERTER = "0x9c5A7aB705EA40876c1B292630a3ff2e0c213DB1"; + +export const ACM = "0xD9dD18EB0cf10CbA837677f28A8F9Bda4bc2b157"; + +export const converters: string[] = [ + USDT_PRIME_CONVERTER, + USDC_PRIME_CONVERTER, + WBTC_PRIME_CONVERTER, + WETH_PRIME_CONVERTER, + XVS_VAULT_CONVERTER, +]; + +// Function to filter assets based on a base asset +const filterAssets = (assets: string[], baseAsset: string) => assets.filter(asset => asset !== baseAsset); + +export const USDTPrimeConverterTokenOuts = filterAssets(Assets, BaseAssets[0]); +export const USDCPrimeConverterTokenOuts = filterAssets(Assets, BaseAssets[1]); +export const WBTCPrimeConverterTokenOuts = filterAssets(Assets, BaseAssets[2]); +export const WETHPrimeConverterTokenOuts = filterAssets(Assets, BaseAssets[3]); +export const XVSVaultConverterTokenOuts = filterAssets(Assets, BaseAssets[4]); +console.log("-------------- USDT", USDTPrimeConverterTokenOuts); +console.log("-------------- USDC", USDCPrimeConverterTokenOuts); diff --git a/multisig/proposals/arbitrumone/vip-018/commands.ts b/multisig/proposals/arbitrumone/vip-018/commands.ts new file mode 100644 index 000000000..43eb6e441 --- /dev/null +++ b/multisig/proposals/arbitrumone/vip-018/commands.ts @@ -0,0 +1,100 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId } from "src/types"; + +import { ACM, Assets, CONVERTER_NETWORK, converters } from "./addresses"; + +const { arbitrumone } = NETWORK_ADDRESSES; + +type IncentiveAndAccessibility = [number, number]; + +interface AcceptOwnership { + target: string; + signature: string; + params: []; +} + +interface CallPermission { + target: string; + signature: string; + params: [string, string, string]; +} + +export const grant = (target: string, signature: string, caller: string): CallPermission => { + const config: CallPermission = { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [target, signature, caller], + }; + + return config; +}; + +const incentiveAndAccessibility: IncentiveAndAccessibility = [0, 1]; + +function generateAcceptOwnershipCommands(ConvertersArray: string[]): AcceptOwnership[] { + const acceptOwnershipCommandsArray: AcceptOwnership[] = []; + + for (const converter of ConvertersArray) { + const config: AcceptOwnership = { + target: converter, + signature: "acceptOwnership()", + params: [], + }; + + acceptOwnershipCommandsArray.push(config); + } + + return acceptOwnershipCommandsArray; +} + +const generateSetConverterNetworkCommands = () => { + return converters.map(converter => ({ + target: converter, + signature: "setConverterNetwork(address)", + params: [CONVERTER_NETWORK], + })); +}; + +const generateAddConverterNetworkCommands = () => { + return converters.map(converter => ({ + target: CONVERTER_NETWORK, + signature: "addTokenConverter(address)", + params: [converter], + dstChainId: LzChainId.arbitrumone, + })); +}; + +function generateCallPermissionCommands(ConvertersArray: string[]): CallPermission[] { + const callPermissionCommandsArray: CallPermission[] = []; + + for (const converter of ConvertersArray) { + const config1 = grant( + converter, + "setConversionConfig(address,address,ConversionConfig)", + arbitrumone.NORMAL_TIMELOCK, + ); + const config2 = grant(converter, "pauseConversion()", arbitrumone.NORMAL_TIMELOCK); + const config3 = grant(converter, "resumeConversion()", arbitrumone.NORMAL_TIMELOCK); + const config4 = grant(converter, "setMinAmountToConvert(uint256)", arbitrumone.NORMAL_TIMELOCK); + + callPermissionCommandsArray.push(config1); + callPermissionCommandsArray.push(config2); + callPermissionCommandsArray.push(config3); + callPermissionCommandsArray.push(config4); + } + return callPermissionCommandsArray; +} + +export const incentiveAndAccessibilities: IncentiveAndAccessibility[] = []; + +for (let i = 0; i < Assets.length - 1; i++) { + incentiveAndAccessibilities.push(incentiveAndAccessibility); +} + +export const acceptOwnershipCommandsAllConverters: AcceptOwnership[] = generateAcceptOwnershipCommands(converters); + +export const setConverterNetworkCommands = generateSetConverterNetworkCommands(); + +export const addConverterNetworkCommands = generateAddConverterNetworkCommands(); + +export const callPermissionCommandsAllConverter: CallPermission[] = generateCallPermissionCommands(converters); diff --git a/multisig/proposals/arbitrumone/vip-018/index.ts b/multisig/proposals/arbitrumone/vip-018/index.ts new file mode 100644 index 000000000..bd22a85b9 --- /dev/null +++ b/multisig/proposals/arbitrumone/vip-018/index.ts @@ -0,0 +1,33 @@ +import { makeProposal } from "src/utils"; + +import { CONVERTER_NETWORK, PLP, USDC, USDT, WBTC, WETH, XVS_VAULT_TREASURY } from "./addresses"; +import { + acceptOwnershipCommandsAllConverters, + callPermissionCommandsAllConverter, + setConverterNetworkCommands, +} from "./commands"; + +const vip018 = () => { + return makeProposal([ + { + target: PLP, + signature: "initializeTokens(address[])", + params: [[WETH, WBTC, USDC, USDT]], + }, + ...acceptOwnershipCommandsAllConverters, + { + target: XVS_VAULT_TREASURY, + signature: "acceptOwnership()", + params: [], + }, + { + target: CONVERTER_NETWORK, + signature: "acceptOwnership()", + params: [], + }, + ...callPermissionCommandsAllConverter, + ...setConverterNetworkCommands, + ]); +}; + +export default vip018; diff --git a/multisig/simulations/arbitrumone/vip-018/abi/ConverterNetwork.json b/multisig/simulations/arbitrumone/vip-018/abi/ConverterNetwork.json new file mode 100644 index 000000000..0fa27deec --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-018/abi/ConverterNetwork.json @@ -0,0 +1,448 @@ +[ + { + "inputs": [], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [], + "name": "ConverterAlreadyExists", + "type": "error" + }, + { + "inputs": [], + "name": "ConverterDoesNotExist", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "loopsLimit", + "type": "uint256" + } + ], + "name": "InvalidMaxLoopsLimit", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidTokenConverterAddress", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "loopsLimit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "requiredLoops", + "type": "uint256" + } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "converter", + "type": "address" + } + ], + "name": "ConverterAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "converter", + "type": "address" + } + ], + "name": "ConverterRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMaxLoopsLimit", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newmaxLoopsLimit", + "type": "uint256" + } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract IAbstractTokenConverter", + "name": "_tokenConverter", + "type": "address" + } + ], + "name": "addTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "allConverters", + "outputs": [ + { + "internalType": "contract IAbstractTokenConverter", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "_tokenAddressOut", + "type": "address" + } + ], + "name": "findTokenConverters", + "outputs": [ + { + "internalType": "address[]", + "name": "converters", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "convertersBalance", + "type": "uint256[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "_tokenAddressOut", + "type": "address" + } + ], + "name": "findTokenConvertersForConverters", + "outputs": [ + { + "internalType": "address[]", + "name": "converters", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "convertersBalance", + "type": "uint256[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getAllConverters", + "outputs": [ + { + "internalType": "contract IAbstractTokenConverter[]", + "name": "converters", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_accessControlManager", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_loopsLimit", + "type": "uint256" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_tokenConverter", + "type": "address" + } + ], + "name": "isTokenConverter", + "outputs": [ + { + "internalType": "bool", + "name": "isConverter", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract IAbstractTokenConverter", + "name": "_tokenConverter", + "type": "address" + } + ], + "name": "removeTokenConverter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "limit", + "type": "uint256" + } + ], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-018/abi/ILComptroller.json b/multisig/simulations/arbitrumone/vip-018/abi/ILComptroller.json new file mode 100644 index 000000000..56890d9b3 --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-018/abi/ILComptroller.json @@ -0,0 +1,929 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum ComptrollerStorage.Action", "name": "action", "type": "uint8" } + ], + "name": "ActionPaused", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, + { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, + { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, + { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, + { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, + { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "PriceError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "TooMuchRepay", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "expectedSender", "type": "address" }, + { "internalType": "address", "name": "actualSender", "type": "address" } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "enum ComptrollerStorage.Action", "name": "action", "type": "uint8" }, + { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "accountAssets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum ComptrollerStorage.Action", "name": "action", "type": "uint8" } + ], + "name": "actionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allMarkets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "approvedDelegates", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "borrowCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "contract VToken", "name": "vToken", "type": "address" } + ], + "name": "checkMembership", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], + "name": "enterMarkets", + "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], + "name": "exitMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAssetsIn", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getBorrowingPower", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "vTokenModify", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isForcedLiquidationEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "isMarketListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [ + { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "bool", "name": "isListed", "type": "bool" }, + { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "seizerContract", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, + { "internalType": "enum ComptrollerStorage.Action[]", "name": "actionsList", "type": "uint8[]" }, + { "internalType": "bool", "name": "paused", "type": "bool" } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "supplyCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "delegate", "type": "address" }, + { "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-018/abi/Prime.json b/multisig/simulations/arbitrumone/vip-018/abi/Prime.json new file mode 100644 index 000000000..0895c7575 --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-018/abi/Prime.json @@ -0,0 +1,1787 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "_wrappedNativeToken", + "type": "address" + }, + { + "internalType": "address", + "name": "_nativeMarket", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_blocksPerYear", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_stakingPeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_minimumStakedXVS", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_maximumXVSCap", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "_timeBased", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [], + "name": "AssetAlreadyExists", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "int256", + "name": "x", + "type": "int256" + } + ], + "name": "ExpTooLarge", + "type": "error" + }, + { + "inputs": [], + "name": "IneligibleToClaim", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidAddress", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidAlphaArguments", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidBlocksPerYear", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidComptroller", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidFixedPoint", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "n", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "d", + "type": "uint256" + } + ], + "name": "InvalidFraction", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidLength", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidLimit", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidTimeBasedConfiguration", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidTimestamp", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidVToken", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "int256", + "name": "x", + "type": "int256" + } + ], + "name": "LnNonRealResult", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "int256", + "name": "x", + "type": "int256" + } + ], + "name": "LnTooLarge", + "type": "error" + }, + { + "inputs": [], + "name": "MarketAlreadyExists", + "type": "error" + }, + { + "inputs": [], + "name": "MarketNotSupported", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "loopsLimit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "requiredLoops", + "type": "uint256" + } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [], + "name": "NoScoreUpdatesRequired", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "UserHasNoPrimeToken", + "type": "error" + }, + { + "inputs": [], + "name": "WaitMoreTime", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint128", + "name": "oldNumerator", + "type": "uint128" + }, + { + "indexed": true, + "internalType": "uint128", + "name": "oldDenominator", + "type": "uint128" + }, + { + "indexed": true, + "internalType": "uint128", + "name": "newNumerator", + "type": "uint128" + }, + { + "indexed": false, + "internalType": "uint128", + "name": "newDenominator", + "type": "uint128" + } + ], + "name": "AlphaUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "Burn", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "InterestClaimed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "supplyMultiplier", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "borrowMultiplier", + "type": "uint256" + } + ], + "name": "MarketAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMaxLoopsLimit", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newmaxLoopsLimit", + "type": "uint256" + } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "isIrrevocable", + "type": "bool" + } + ], + "name": "Mint", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "oldIrrevocableLimit", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "oldRevocableLimit", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "newIrrevocableLimit", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newRevocableLimit", + "type": "uint256" + } + ], + "name": "MintLimitsUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "oldSupplyMultiplier", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "oldBorrowMultiplier", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newSupplyMultiplier", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newBorrowMultiplier", + "type": "uint256" + } + ], + "name": "MultiplierUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "timestamp", + "type": "uint256" + } + ], + "name": "StakedAtUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "TokenUpgraded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "UserScoreUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "MAXIMUM_XVS_CAP", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "MINIMUM_STAKED_XVS", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_MARKET", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "STAKING_PERIOD", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "WRAPPED_NATIVE_TOKEN", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "accrueInterest", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "internalType": "address", + "name": "market", + "type": "address" + } + ], + "name": "accrueInterestAndUpdateScore", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "supplyMultiplier", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowMultiplier", + "type": "uint256" + } + ], + "name": "addMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "alphaDenominator", + "outputs": [ + { + "internalType": "uint128", + "name": "", + "type": "uint128" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "alphaNumerator", + "outputs": [ + { + "internalType": "uint128", + "name": "", + "type": "uint128" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "calculateAPR", + "outputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "supplyAPR", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAPR", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "totalScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "userScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "xvsBalanceForScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "capital", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "cappedSupply", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "cappedBorrow", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supplyCapUSD", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowCapUSD", + "type": "uint256" + } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "claim", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "claimInterest", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "claimInterest", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "claimTimeRemaining", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "comptroller", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + }, + { + "internalType": "uint256", + "name": "borrow", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supply", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "xvsStaked", + "type": "uint256" + } + ], + "name": "estimateAPR", + "outputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "supplyAPR", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowAPR", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "totalScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "userScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "xvsBalanceForScore", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "capital", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "cappedSupply", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "cappedBorrow", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supplyCapUSD", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowCapUSD", + "type": "uint256" + } + ], + "internalType": "struct IPrime.APRInfo", + "name": "aprInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [ + { + "internalType": "address[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "getInterestAccrued", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "getPendingRewards", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + }, + { + "internalType": "address", + "name": "rewardToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "internalType": "struct PrimeStorageV1.PendingReward[]", + "name": "pendingRewards", + "type": "tuple[]" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "incomeDistributionYearly", + "outputs": [ + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "xvsVault_", + "type": "address" + }, + { + "internalType": "address", + "name": "xvsVaultRewardToken_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "xvsVaultPoolId_", + "type": "uint256" + }, + { + "internalType": "uint128", + "name": "alphaNumerator_", + "type": "uint128" + }, + { + "internalType": "uint128", + "name": "alphaDenominator_", + "type": "uint128" + }, + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + }, + { + "internalType": "address", + "name": "primeLiquidityProvider_", + "type": "address" + }, + { + "internalType": "address", + "name": "comptroller_", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "loopsLimit_", + "type": "uint256" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "poolRegistry_", + "type": "address" + } + ], + "name": "initializeV2", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "interests", + "outputs": [ + { + "internalType": "uint256", + "name": "accrued", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "score", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "rewardIndex", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "irrevocableLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "isScoreUpdated", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "isUserPrimeHolder", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bool", + "name": "isIrrevocable", + "type": "bool" + }, + { + "internalType": "address[]", + "name": "users", + "type": "address[]" + } + ], + "name": "issue", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "markets", + "outputs": [ + { + "internalType": "uint256", + "name": "supplyMultiplier", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowMultiplier", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "rewardIndex", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sumOfMembersScore", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "exists", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "nextScoreUpdateRoundId", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [ + { + "internalType": "contract ResilientOracleInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingScoreUpdates", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "primeLiquidityProvider", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "revocableLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_irrevocableLimit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_revocableLimit", + "type": "uint256" + } + ], + "name": "setLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "loopsLimit", + "type": "uint256" + } + ], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "users", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "timestamps", + "type": "uint256[]" + } + ], + "name": "setStakedAt", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "stakedAt", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "togglePause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "tokens", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "internalType": "bool", + "name": "isIrrevocable", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalIrrevocable", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalRevocable", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalScoreUpdatesRequired", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "unreleasedPLPIncome", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint128", + "name": "_alphaNumerator", + "type": "uint128" + }, + { + "internalType": "uint128", + "name": "_alphaDenominator", + "type": "uint128" + } + ], + "name": "updateAlpha", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "market", + "type": "address" + }, + { + "internalType": "uint256", + "name": "supplyMultiplier", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "borrowMultiplier", + "type": "uint256" + } + ], + "name": "updateMultipliers", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "users", + "type": "address[]" + } + ], + "name": "updateScores", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "vTokenForAsset", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "xvsUpdated", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVault", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultPoolId", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVaultRewardToken", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-018/abi/PrimeLiquidityProvider.json b/multisig/simulations/arbitrumone/vip-018/abi/PrimeLiquidityProvider.json new file mode 100644 index 000000000..02ca8e0bf --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-018/abi/PrimeLiquidityProvider.json @@ -0,0 +1,385 @@ +[ + { + "inputs": [ + { "internalType": "bool", "name": "_timeBased", "type": "bool" }, + { "internalType": "uint256", "name": "_blocksPerYear", "type": "uint256" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, + { "inputs": [], "name": "FundsTransferIsPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "sweepAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "balance", "type": "uint256" } + ], + "name": "InsufficientBalance", + "type": "error" + }, + { "inputs": [], "name": "InvalidArguments", "type": "error" }, + { "inputs": [], "name": "InvalidBlocksPerYear", "type": "error" }, + { "inputs": [], "name": "InvalidCaller", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "speed", "type": "uint256" }, + { "internalType": "uint256", "name": "maxSpeed", "type": "uint256" } + ], + "name": "InvalidDistributionSpeed", + "type": "error" + }, + { "inputs": [], "name": "InvalidTimeBasedConfiguration", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenAlreadyInitialized", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "TokenNotInitialized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "MaxTokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldPrimeToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newPrimeToken", "type": "address" } + ], + "name": "PrimeTokenUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "sweepAmount", "type": "uint256" } + ], + "name": "SweepToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "token", "type": "address" }], + "name": "TokenDistributionInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldSpeed", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newSpeed", "type": "uint256" } + ], + "name": "TokenDistributionSpeedUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokenTransferredToPrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "token", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "TokensAccrued", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_MAX_DISTRIBUTION_SPEED", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "accrueTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "blocksOrSecondsPerYear", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getBlockNumberOrTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "getEffectiveDistributionSpeed", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "accessControlManager_", "type": "address" }, + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" }, + { "internalType": "uint256", "name": "loopsLimit_", "type": "uint256" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "tokens_", "type": "address[]" }], + "name": "initializeTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isTimeBased", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "lastAccruedBlock", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "lastAccruedBlockOrSecond", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "maxTokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pauseFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "releaseFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { "inputs": [], "name": "resumeFundsTransfer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "maxDistributionSpeeds_", "type": "uint256[]" } + ], + "name": "setMaxTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "prime_", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address[]", "name": "tokens_", "type": "address[]" }, + { "internalType": "uint256[]", "name": "distributionSpeeds_", "type": "uint256[]" } + ], + "name": "setTokensDistributionSpeed", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract IERC20Upgradeable", "name": "token_", "type": "address" }, + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "token_", "type": "address" }], + "name": "tokenAmountAccrued", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "tokenDistributionSpeeds", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-018/abi/SingleTokenConverter.json b/multisig/simulations/arbitrumone/vip-018/abi/SingleTokenConverter.json new file mode 100644 index 000000000..c8d0f7077 --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-018/abi/SingleTokenConverter.json @@ -0,0 +1,1381 @@ +[ + { + "inputs": [], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + } + ], + "name": "AmountInHigherThanMax", + "type": "error" + }, + { + "inputs": [], + "name": "AmountInMismatched", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + } + ], + "name": "AmountOutLowerThanMinRequired", + "type": "error" + }, + { + "inputs": [], + "name": "AmountOutMismatched", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionConfigNotEnabled", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionEnabledOnlyForPrivateConversions", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionTokensActive", + "type": "error" + }, + { + "inputs": [], + "name": "ConversionTokensPaused", + "type": "error" + }, + { + "inputs": [], + "name": "DeflationaryTokenNotSupported", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxIncentive", + "type": "uint256" + } + ], + "name": "IncentiveTooHigh", + "type": "error" + }, + { + "inputs": [], + "name": "InputLengthMisMatch", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientInputAmount", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientOutputAmount", + "type": "error" + }, + { + "inputs": [], + "name": "InsufficientPoolLiquidity", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidConverterNetwork", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidMinimumAmountToConvert", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidToAddress", + "type": "error" + }, + { + "inputs": [], + "name": "InvalidTokenConfigAddresses", + "type": "error" + }, + { + "inputs": [], + "name": "NonZeroIncentiveForPrivateConversion", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroValueNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "AssetTransferredToDestination", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldBaseAsset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newBaseAsset", + "type": "address" + } + ], + "name": "BaseAssetUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldIncentive", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newIncentive", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "oldAccess", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "newAccess", + "type": "uint8" + } + ], + "name": "ConversionConfigUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + } + ], + "name": "ConversionPaused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + } + ], + "name": "ConversionResumed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedForExactTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountIn", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountOut", + "type": "uint256" + } + ], + "name": "ConvertedForExactTokensSupportingFeeOnTransferTokens", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldConverterNetwork", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "converterNetwork", + "type": "address" + } + ], + "name": "ConverterNetworkAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldDestinationAddress", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "destinationAddress", + "type": "address" + } + ], + "name": "DestinationAddressUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "oldMinAmountToConvert", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMinAmountToConvert", + "type": "uint256" + } + ], + "name": "MinAmountToConvertUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "contract ResilientOracle", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "contract ResilientOracle", + "name": "priceOracle", + "type": "address" + } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "token", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "SweepToken", + "type": "event" + }, + { + "inputs": [], + "name": "MAX_INCENTIVE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "tokenBalance", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "baseAsset", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "conversionConfigurations", + "outputs": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "conversionPaused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertExactTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMinMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertForExactTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMaxMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + } + ], + "name": "convertForExactTokensSupportingFeeOnTransferTokens", + "outputs": [ + { + "internalType": "uint256", + "name": "actualAmountIn", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "actualAmountOut", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "converterNetwork", + "outputs": [ + { + "internalType": "contract IConverterNetwork", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "destinationAddress", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getAmountIn", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getAmountOut", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getUpdatedAmountIn", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountInMantissa", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + } + ], + "name": "getUpdatedAmountOut", + "outputs": [ + { + "internalType": "uint256", + "name": "amountConvertedMantissa", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amountOutMantissa", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + }, + { + "internalType": "contract ResilientOracle", + "name": "priceOracle_", + "type": "address" + }, + { + "internalType": "address", + "name": "destinationAddress_", + "type": "address" + }, + { + "internalType": "address", + "name": "baseAsset_", + "type": "address" + }, + { + "internalType": "uint256", + "name": "minAmountToConvert_", + "type": "uint256" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "minAmountToConvert", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pauseConversion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "priceOracle", + "outputs": [ + { + "internalType": "contract ResilientOracle", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "resumeConversion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "baseAsset_", + "type": "address" + } + ], + "name": "setBaseAsset", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address", + "name": "tokenAddressOut", + "type": "address" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig", + "name": "conversionConfig", + "type": "tuple" + } + ], + "name": "setConversionConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddressIn", + "type": "address" + }, + { + "internalType": "address[]", + "name": "tokenAddressesOut", + "type": "address[]" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "incentive", + "type": "uint256" + }, + { + "internalType": "enum IAbstractTokenConverter.ConversionAccessibility", + "name": "conversionAccess", + "type": "uint8" + } + ], + "internalType": "struct IAbstractTokenConverter.ConversionConfig[]", + "name": "conversionConfigs", + "type": "tuple[]" + } + ], + "name": "setConversionConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract IConverterNetwork", + "name": "converterNetwork_", + "type": "address" + } + ], + "name": "setConverterNetwork", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "destinationAddress_", + "type": "address" + } + ], + "name": "setDestination", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "minAmountToConvert_", + "type": "uint256" + } + ], + "name": "setMinAmountToConvert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract ResilientOracle", + "name": "priceOracle_", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "sweepToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "comptroller", + "type": "address" + }, + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetsState", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-018/abi/XVSVaultTreasury.json b/multisig/simulations/arbitrumone/vip-018/abi/XVSVaultTreasury.json new file mode 100644 index 000000000..6f6f3cf38 --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-018/abi/XVSVaultTreasury.json @@ -0,0 +1,306 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "xvsAddress_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [], + "name": "InsufficientBalance", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroValueNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "xvsStore", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amountMantissa", + "type": "uint256" + } + ], + "name": "FundsTransferredToXVSStore", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldXVSVault", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newXVSVault", + "type": "address" + } + ], + "name": "XVSVaultUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "XVS_ADDRESS", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "amountMantissa", + "type": "uint256" + } + ], + "name": "fundXVSVault", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + }, + { + "internalType": "address", + "name": "xvsVault_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "xvsVault_", + "type": "address" + } + ], + "name": "setXVSVault", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "xvsVault", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/multisig/simulations/arbitrumone/vip-018/index.ts b/multisig/simulations/arbitrumone/vip-018/index.ts new file mode 100644 index 000000000..c3e5ff7dd --- /dev/null +++ b/multisig/simulations/arbitrumone/vip-018/index.ts @@ -0,0 +1,105 @@ +/* eslint-disable @typescript-eslint/no-unused-vars */ +import { expect } from "chai"; +import { Contract } from "ethers"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { forking, pretendExecutingVip } from "src/vip-framework"; + +import vip018 from "../../../proposals/arbitrumone/vip-018"; +import { + CONVERTER_NETWORK, + PLP, + USDC, + USDT, + WBTC, + WETH, + XVS, + XVS_VAULT_TREASURY, + converters, +} from "../../../proposals/arbitrumone/vip-018/addresses"; +import CONVERTER_NETWORK_ABI from "./abi/ConverterNetwork.json"; +import COMPTROLLER_ABI from "./abi/ILComptroller.json"; +import PRIME_ABI from "./abi/Prime.json"; +import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; +import SINGLE_TOKEN_CONVERTER_ABI from "./abi/SingleTokenConverter.json"; +import XVS_VAULT_TREASURY_ABI from "./abi/XVSVaultTreasury.json"; + +const { arbitrumone } = NETWORK_ADDRESSES; + +const XVS_VAULT = "0x8b79692AAB2822Be30a6382Eb04763A74752d5B4"; +const COMPTROLLER_CORE = "0x317c1A5739F39046E20b08ac9BeEa3f10fD43326"; +const COMPTROLLER_LST = "0x52bAB1aF7Ff770551BD05b9FC2329a0Bf5E23F16"; +const PRIME = "0xFE69720424C954A2da05648a0FAC84f9bf11Ef49"; + +forking(276102872, async () => { + const provider = ethers.provider; + let converterNetwork: Contract; + let xvsVaultTreasury: Contract; + let prime: Contract; + let plp: Contract; + + describe("Post-VIP behavior", () => { + before(async () => { + converterNetwork = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); + xvsVaultTreasury = new ethers.Contract(XVS_VAULT_TREASURY, XVS_VAULT_TREASURY_ABI, provider); + prime = new ethers.Contract(PRIME, PRIME_ABI, provider); + plp = new ethers.Contract(PLP, PLP_ABI, provider); + + await pretendExecutingVip(await vip018()); + }); + + describe("Prime configuration", () => { + it("prime should have correct pool registry address", async () => { + expect(await prime.poolRegistry()).to.be.equal(arbitrumone.POOL_REGISTRY); + }); + + it("Comptroller lst and core should have correct Prime token address", async () => { + const comptrollerCore = new ethers.Contract(COMPTROLLER_CORE, COMPTROLLER_ABI, provider); + expect(await comptrollerCore.prime()).to.be.equal(PRIME); + + const comptrollerLst = new ethers.Contract(COMPTROLLER_LST, COMPTROLLER_ABI, provider); + expect(await comptrollerLst.prime()).to.be.equal(PRIME); + }); + + it("Plp should have correct tokens", async () => { + expect(await plp.lastAccruedBlockOrSecond(USDT)).to.be.gt(0); + expect(await plp.lastAccruedBlockOrSecond(USDC)).to.be.gt(0); + expect(await plp.lastAccruedBlockOrSecond(WETH)).to.be.gt(0); + expect(await plp.lastAccruedBlockOrSecond(WBTC)).to.be.gt(0); + }); + }); + + describe("Converters configuration", () => { + describe("Owner checks", () => { + it("Timelock should be the owner of all converters", async () => { + for (const converter of converters) { + const Converter = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); + expect(await Converter.owner()).to.equal(arbitrumone.GUARDIAN); + } + }); + + it("Timelock should be the owner of ConverterNetwork", async () => { + expect(await converterNetwork.owner()).to.equal(arbitrumone.GUARDIAN); + }); + + it("Timelock should be the owner of XVSVaultTreasury", async () => { + expect(await xvsVaultTreasury.owner()).to.equal(arbitrumone.GUARDIAN); + }); + }); + + describe("Generic checks", () => { + it("XVSVaultTreasury should have correct state variables", async () => { + expect(await xvsVaultTreasury.XVS_ADDRESS()).to.equal(XVS); + expect(await xvsVaultTreasury.xvsVault()).to.equal(XVS_VAULT); + }); + + it("Converters should belong to the same ConverterNetwork", async () => { + for (const converter of converters) { + const Converter = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); + expect(await Converter.converterNetwork()).to.equal(CONVERTER_NETWORK); + } + }); + }); + }); + }); +}); From 9934e412ce91891308ced0f085f20e9115092e31 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Wed, 20 Nov 2024 21:57:27 +0530 Subject: [PATCH 150/178] feat: prime and converters configurations on arbitrum one through multichain --- simulations/vip-395/arbitrumone.ts | 293 +++++++++++++++++++++++++++++ simulations/vip-395/bscmainnet.ts | 17 ++ vips/vip-395/bscmainnet.ts | 184 ++++++++++++++++++ 3 files changed, 494 insertions(+) create mode 100644 simulations/vip-395/arbitrumone.ts create mode 100644 simulations/vip-395/bscmainnet.ts create mode 100644 vips/vip-395/bscmainnet.ts diff --git a/simulations/vip-395/arbitrumone.ts b/simulations/vip-395/arbitrumone.ts new file mode 100644 index 000000000..af3e12895 --- /dev/null +++ b/simulations/vip-395/arbitrumone.ts @@ -0,0 +1,293 @@ +import { expect } from "chai"; +import { BigNumber, Contract, Signer } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { expectEvents, initMainnetUser, setMaxStalePeriod } from "src/utils"; +import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; + +import vip018 from "../../multisig/proposals/arbitrumone/vip-018"; +import { + CONVERTER_NETWORK, + USDC, + USDC_PRIME_CONVERTER, + USDT, + USDT_PRIME_CONVERTER, + XVS_VAULT_CONVERTER, + XVS_VAULT_TREASURY, + converters, +} from "../../multisig/proposals/arbitrumone/vip-018/addresses"; +import CONVERTER_NETWORK_ABI from "../../multisig/simulations/arbitrumone/vip-018/abi/ConverterNetwork.json"; +import SINGLE_TOKEN_CONVERTER_ABI from "../../multisig/simulations/arbitrumone/vip-018/abi/SingleTokenConverter.json"; +import XVS_VAULT_TREASURY_ABI from "../../multisig/simulations/arbitrumone/vip-018/abi/XVSVaultTreasury.json"; +import vip395, { + ARBITRUM_COMPTROLLER_CORE, + ARBITRUM_COMPTROLLER_LST, + ARBITRUM_PLP, + ARBITRUM_PRIME, + ARBITRUM_USDC, + ARBITRUM_USDT, + ARBITRUM_VUSDC_CORE, + ARBITRUM_VUSDT_CORE, + ARBITRUM_VWBTC_CORE, + ARBITRUM_VWETH_LST, + ARBITRUM_WBTC, + ARBITRUM_WETH, +} from "../../vips/vip-395/bscmainnet"; +import ERC20_ABI from "./abi/ERC20.json"; +import COMPTROLLER_ABI from "./abi/ILComptroller.json"; +import PRIME_ABI from "./abi/Prime.json"; +import PLP_ABI from "./abi/PrimeLiquidityProvider.json"; +import PROTOCOL_SHARE_RESERVE_ABI from "./abi/ProtocolShareReserve.json"; + +const { arbitrumone } = NETWORK_ADDRESSES; +const USDT_HOLDER = "0x3931dAb967C3E2dbb492FE12460a66d0fe4cC857"; +const USDC_HOLDER = "0x47c031236e19d024b42f8AE6780E44A573170703"; + +const ARBITRUM_PROTOCOL_SHARE_RESERVE_PROXY = "0xF9263eaF7eB50815194f26aCcAB6765820B13D41"; + +forking(276417316, async () => { + const provider = ethers.provider; + let prime: Contract; + let converterNetwork: Contract; + let xvsVaultTreasury: Contract; + let protocolShareReserve: Contract; + let usdtPrimeConverter: Contract; + let usdcPrimeConverter: Contract; + + before(async () => { + usdcPrimeConverter = new ethers.Contract(USDC_PRIME_CONVERTER, SINGLE_TOKEN_CONVERTER_ABI, provider); + usdtPrimeConverter = new ethers.Contract(USDT_PRIME_CONVERTER, SINGLE_TOKEN_CONVERTER_ABI, provider); + + converterNetwork = new ethers.Contract(CONVERTER_NETWORK, CONVERTER_NETWORK_ABI, provider); + protocolShareReserve = new ethers.Contract( + ARBITRUM_PROTOCOL_SHARE_RESERVE_PROXY, + PROTOCOL_SHARE_RESERVE_ABI, + provider, + ); + xvsVaultTreasury = new ethers.Contract(XVS_VAULT_TREASURY, XVS_VAULT_TREASURY_ABI, provider); + + await pretendExecutingVip(await vip018()); + }); + + describe("Pre-VIP behaviour", () => { + before(async () => { + prime = new ethers.Contract(ARBITRUM_PRIME, PRIME_ABI, provider); + }); + + it("Prime should have not contain number of revocable and irrevocable tokens", async () => { + expect(await prime.irrevocableLimit()).to.equal(0); + expect(await prime.revocableLimit()).to.equal(0); + }); + }); + + testForkedNetworkVipCommands("VIP 395", await vip395(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [PRIME_ABI], ["MarketAdded"], [4]); + await expectEvents(txResponse, [PRIME_ABI], ["MintLimitsUpdated"], [1]); + await expectEvents(txResponse, [PROTOCOL_SHARE_RESERVE_ABI], ["DistributionConfigAdded"], [6]); + await expectEvents(txResponse, [PROTOCOL_SHARE_RESERVE_ABI], ["DistributionConfigUpdated"], [2]); + }, + }); + + describe("Post-VIP behavior", () => { + let prime: Contract; + let plp: Contract; + + before(async () => { + prime = new ethers.Contract(ARBITRUM_PRIME, PRIME_ABI, provider); + plp = new ethers.Contract(ARBITRUM_PLP, PLP_ABI, provider); + }); + + it("prime should have correct pool registry address", async () => { + expect(await prime.poolRegistry()).to.be.equal(arbitrumone.POOL_REGISTRY); + }); + + it("Comptroller lst and core should have correct Prime token address", async () => { + const comptrollerCore = new ethers.Contract(ARBITRUM_COMPTROLLER_CORE, COMPTROLLER_ABI, provider); + expect(await comptrollerCore.prime()).to.be.equal(ARBITRUM_PRIME); + + const comptrollerLst = new ethers.Contract(ARBITRUM_COMPTROLLER_LST, COMPTROLLER_ABI, provider); + expect(await comptrollerLst.prime()).to.be.equal(ARBITRUM_PRIME); + }); + + it("Prime should contain correct markets", async () => { + expect((await prime.markets(ARBITRUM_VUSDC_CORE))[4]).to.be.equal(true); + expect((await prime.markets(ARBITRUM_VUSDT_CORE))[4]).to.be.equal(true); + expect((await prime.markets(ARBITRUM_VWBTC_CORE))[4]).to.be.equal(true); + expect((await prime.markets(ARBITRUM_VWETH_LST))[4]).to.be.equal(true); + }); + + it("Prime should have correct number of revocable and irrevocable tokens", async () => { + expect(await prime.irrevocableLimit()).to.equal(0); + expect(await prime.revocableLimit()).to.equal(500); + }); + + it("Plp should have correct tokens", async () => { + expect(await plp.lastAccruedBlockOrSecond(ARBITRUM_USDT)).to.be.gt(0); + expect(await plp.lastAccruedBlockOrSecond(ARBITRUM_USDC)).to.be.gt(0); + expect(await plp.lastAccruedBlockOrSecond(ARBITRUM_WETH)).to.be.gt(0); + expect(await plp.lastAccruedBlockOrSecond(ARBITRUM_WBTC)).to.be.gt(0); + }); + }); + + describe("Owner checks", () => { + it("Timelock should be the owner of all converters", async () => { + for (const converter of converters) { + const Converter = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); + expect(await Converter.owner()).to.equal(arbitrumone.GUARDIAN); + } + }); + + it("Timelock should be the owner of ConverterNetwork", async () => { + expect(await converterNetwork.owner()).to.equal(arbitrumone.GUARDIAN); + }); + + it("Timelock should be the owner of XVSVaultTreasury", async () => { + expect(await xvsVaultTreasury.owner()).to.equal(arbitrumone.GUARDIAN); + }); + }); + + describe("Generic checks", () => { + let usdt: Contract; + let usdc: Contract; + let user1: Signer; + let usdtHolder: Signer; + let usdcHolder: Signer; + let user1Address: string; + let resilientOracle: Contract; + + const amount = parseUnits("1000", 6); + + before(async () => { + usdt = new ethers.Contract(USDT, ERC20_ABI, provider); + usdc = new ethers.Contract(USDC, ERC20_ABI, provider); + resilientOracle = new ethers.Contract(arbitrumone.RESILIENT_ORACLE, ORACLE, provider); + + [, user1] = await ethers.getSigners(); + user1Address = await user1.getAddress(); + + usdcHolder = await initMainnetUser(USDC_HOLDER, ethers.utils.parseEther("1")); + usdtHolder = await initMainnetUser(USDT_HOLDER, ethers.utils.parseEther("1")); + + await usdt.connect(usdtHolder).transfer(user1Address, amount); + await usdc.connect(usdcHolder).transfer(user1Address, amount); + await setMaxStalePeriod(resilientOracle, usdt); + await setMaxStalePeriod(resilientOracle, usdc); + }); + + it("PSR should have correct distribution configs", async () => { + const percentageDistributionConverters = [500, 500, 300, 700, 2000]; + expect(await protocolShareReserve.totalDistributions()).to.equal(8); + + for (let i = 0; i < 5; i++) { + expect(await protocolShareReserve.getPercentageDistribution(converters[i], 0)).to.equal( + percentageDistributionConverters[i], + ); + } + + expect(await protocolShareReserve.getPercentageDistribution(arbitrumone.VTREASURY, 0)).to.equal(6000); + expect(await protocolShareReserve.getPercentageDistribution(arbitrumone.VTREASURY, 1)).to.equal(8000); + expect(await protocolShareReserve.getPercentageDistribution(XVS_VAULT_CONVERTER, 1)).to.equal(2000); + }); + + it("XVSVaultTreasury should have correct state variables", async () => { + expect(await xvsVaultTreasury.XVS_ADDRESS()).to.equal(arbitrumone.XVS); + expect(await xvsVaultTreasury.xvsVault()).to.equal(arbitrumone.XVS_VAULT_PROXY); + }); + + it("ConverterNetwork should contain all converters", async () => { + expect(await converterNetwork.getAllConverters()).to.deep.equal(converters); + }); + + it("Convert exact tokens should work correctly", async () => { + const amountInMantissa = amount.div(2); + await usdt.connect(usdtHolder).transfer(user1Address, amount); + await usdc.connect(usdtHolder).transfer(USDT_PRIME_CONVERTER, amount); + + const usdcBalanceOfUsdtPrimeConverterPrevious = await usdtPrimeConverter.balanceOf(USDC); + const usdtBalanceOfUsdtPrimePrevious = await usdt.balanceOf(ARBITRUM_PLP); + const usdtBalanceOfUserPrevious = await usdt.balanceOf(user1Address); + + const [, amountOutMantissa] = await usdtPrimeConverter + .connect(user1) + .callStatic.getUpdatedAmountOut(amountInMantissa, USDT, USDC); + + await usdt.connect(user1).approve(USDT_PRIME_CONVERTER, amountInMantissa); + await usdtPrimeConverter + .connect(user1) + .convertExactTokens(amountInMantissa, amountInMantissa.div(2), USDT, USDC, user1Address); + + expect(await usdt.balanceOf(user1Address)).to.equal(usdtBalanceOfUserPrevious.sub(amountInMantissa)); + expect(await usdtPrimeConverter.balanceOf(USDT)).to.equal(0); + expect(await usdtPrimeConverter.balanceOf(USDC)).to.equal( + usdcBalanceOfUsdtPrimeConverterPrevious.sub(amountOutMantissa), + ); + expect(await usdt.balanceOf(ARBITRUM_PLP)).to.equal( + BigNumber.from(usdtBalanceOfUsdtPrimePrevious).add(amountInMantissa), + ); + }); + + it("ConvertForExactTokens should work properly", async () => { + await usdc.connect(usdcHolder).transfer(user1Address, amount); + await usdc.connect(user1).transfer(USDT_PRIME_CONVERTER, amount); + + const amountOutMantissa = amount.div(2); + const amountInMaxMantissa = amount; + await usdt.connect(usdtHolder).transfer(user1Address, amount); + + const usdcBalanceOfUsdtPrimeConverterPrevious = await usdtPrimeConverter.balanceOf(USDC); + const usdtBalanceOfUsdtPrimePrevious = await usdt.balanceOf(ARBITRUM_PLP); + const usdtBalanceOfUserPrevious = await usdt.balanceOf(user1Address); + + const [, amountInMantissa] = await usdtPrimeConverter.connect(user1).getAmountIn(amountOutMantissa, USDT, USDC); + + await usdt.connect(user1).approve(USDT_PRIME_CONVERTER, amount); + await usdtPrimeConverter + .connect(user1) + .convertForExactTokens(amountInMaxMantissa, amountOutMantissa, USDT, USDC, user1Address); + + expect(await usdt.balanceOf(user1Address)).to.equal(usdtBalanceOfUserPrevious.sub(amountInMantissa)); + expect(await usdtPrimeConverter.balanceOf(USDT)).to.equal(0); + expect(await usdtPrimeConverter.balanceOf(USDC)).to.equal( + usdcBalanceOfUsdtPrimeConverterPrevious.sub(amountOutMantissa), + ); + expect(await usdt.balanceOf(ARBITRUM_PLP)).to.equal( + BigNumber.from(usdtBalanceOfUsdtPrimePrevious).add(amountInMantissa), + ); + }); + + it("Private conversion should occur on updateAssetsState", async () => { + const newAmount = amount.mul(2); + await usdc.connect(usdcHolder).transfer(user1Address, newAmount); + await usdt.connect(usdtHolder).transfer(user1Address, newAmount); + + const destinationAddressForUsdcConverter = await usdcPrimeConverter.destinationAddress(); + + await usdc.connect(user1).transfer(USDT_PRIME_CONVERTER, amount); + await usdtPrimeConverter.connect(user1).updateAssetsState(ARBITRUM_COMPTROLLER_CORE, USDC); + + const usdcBalanceUsdtPrimeConverterPrevious = await usdtPrimeConverter.balanceOf(USDC); + const usdtBalanceUsdtPrimePrevious = await usdt.balanceOf(ARBITRUM_PLP); + + const plpBalanceForUsdcPrevious = await usdc.balanceOf(destinationAddressForUsdcConverter); + await usdt.connect(user1).transfer(USDC_PRIME_CONVERTER, amount); + + // Private Conversion will occur + await usdcPrimeConverter.connect(user1).updateAssetsState(ARBITRUM_COMPTROLLER_CORE, USDT); + + const usdcBalanceUsdtPrimeConverterCurrent = await usdtPrimeConverter.balanceOf(USDC); + const usdtBalanceUsdtPrimeCurrent = await usdt.balanceOf(ARBITRUM_PLP); + + expect(usdtBalanceUsdtPrimeCurrent).to.equal(usdtBalanceUsdtPrimePrevious.add(amount)); + expect(usdcBalanceUsdtPrimeConverterCurrent).to.closeTo( + usdcBalanceUsdtPrimeConverterPrevious.sub(amount), + parseUnits("1", 7), + ); + expect(await usdc.balanceOf(destinationAddressForUsdcConverter)).to.closeTo( + plpBalanceForUsdcPrevious.add(amount), + parseUnits("1", 7), + ); + }); + }); +}); diff --git a/simulations/vip-395/bscmainnet.ts b/simulations/vip-395/bscmainnet.ts new file mode 100644 index 000000000..6b8cd3967 --- /dev/null +++ b/simulations/vip-395/bscmainnet.ts @@ -0,0 +1,17 @@ +import { expectEvents } from "../../src/utils"; +import { forking, testVip } from "../../src/vip-framework"; +import vip395 from "../../vips/vip-395/bscmainnet"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; + +forking(44169313, async () => { + testVip("vip395 Arbitrum one Prime configuration", await vip395(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [1, 0], + ); + }, + }); +}); diff --git a/vips/vip-395/bscmainnet.ts b/vips/vip-395/bscmainnet.ts new file mode 100644 index 000000000..8246669b1 --- /dev/null +++ b/vips/vip-395/bscmainnet.ts @@ -0,0 +1,184 @@ +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +import { + ACM, + BaseAssets, + CONVERTER_NETWORK, + USDCPrimeConverterTokenOuts, + USDC_PRIME_CONVERTER, + USDTPrimeConverterTokenOuts, + USDT_PRIME_CONVERTER, + WBTCPrimeConverterTokenOuts, + WBTC_PRIME_CONVERTER, + WETHPrimeConverterTokenOuts, + WETH_PRIME_CONVERTER, + XVSVaultConverterTokenOuts, + XVS_VAULT_CONVERTER, +} from "../../multisig/proposals/arbitrumone/vip-018/addresses"; +import { + addConverterNetworkCommands, + incentiveAndAccessibilities, +} from "../../multisig/proposals/arbitrumone/vip-018/commands"; + +const { arbitrumone } = NETWORK_ADDRESSES; + +export const ARBITRUM_COMPTROLLER_CORE = "0x317c1A5739F39046E20b08ac9BeEa3f10fD43326"; +export const ARBITRUM_COMPTROLLER_LST = "0x52bAB1aF7Ff770551BD05b9FC2329a0Bf5E23F16"; +export const ARBITRUM_PRIME = "0xFE69720424C954A2da05648a0FAC84f9bf11Ef49"; +export const ARBITRUM_PLP = "0x86bf21dB200f29F21253080942Be8af61046Ec29"; + +export const ARBITRUM_USDT = "0xfd086bc7cd5c481dcc9c85ebe478a1c0b69fcbb9"; +export const ARBITRUM_USDC = "0xaf88d065e77c8cc2239327c5edb3a432268e5831"; +export const ARBITRUM_WBTC = "0x2f2a2543b76a4166549f7aab2e75bef0aefc5b0f"; +export const ARBITRUM_WETH = "0x82af49447d8a07e3bd95bd0d56f35241523fbab1"; + +export const ARBITRUM_VUSDT_CORE = "0xB9F9117d4200dC296F9AcD1e8bE1937df834a2fD"; +export const ARBITRUM_VUSDC_CORE = "0x7D8609f8da70fF9027E9bc5229Af4F6727662707"; +export const ARBITRUM_VWBTC_CORE = "0xaDa57840B372D4c28623E87FC175dE8490792811"; +export const ARBITRUM_VWETH_LST = "0x39D6d13Ea59548637104E40e729E4aABE27FE106"; + +export const ARBITRUM_XVS_VAULT_TREASURY = "0xb076D4f15c08D7A7B89466327Ba71bc7e1311b58"; +export const ARBITRUM_PROTOCOL_SHARE_RESERVE_PROXY = "0xF9263eaF7eB50815194f26aCcAB6765820B13D41"; +export const ARBITRUM_VTREASURY = "0x8a662ceAC418daeF956Bc0e6B2dd417c80CDA631"; + +const vip395 = () => { + const meta = { + version: "v2", + title: "vip395 arbitrum Prime configuration", + description: `#### Description + This VIP will grant permission to timelocks and performs the necessary configuration of OmnichainProposalSender on BNB chain and OmnichainProposalExecutor`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + { + target: ARBITRUM_PRIME, + signature: "addMarket(address,address,uint256,uint256)", + params: [ + ARBITRUM_COMPTROLLER_CORE, + ARBITRUM_VWBTC_CORE, + ethers.utils.parseEther("2"), + ethers.utils.parseEther("4"), + ], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ARBITRUM_PRIME, + signature: "addMarket(address,address,uint256,uint256)", + params: [ + ARBITRUM_COMPTROLLER_CORE, + ARBITRUM_VUSDC_CORE, + ethers.utils.parseEther("2"), + ethers.utils.parseEther("4"), + ], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ARBITRUM_PRIME, + signature: "addMarket(address,address,uint256,uint256)", + params: [ + ARBITRUM_COMPTROLLER_CORE, + ARBITRUM_VUSDT_CORE, + ethers.utils.parseEther("2"), + ethers.utils.parseEther("4"), + ], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ARBITRUM_PRIME, + signature: "addMarket(address,address,uint256,uint256)", + params: [ + ARBITRUM_COMPTROLLER_LST, + ARBITRUM_VWETH_LST, + ethers.utils.parseEther("2"), + ethers.utils.parseEther("4"), + ], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ARBITRUM_PRIME, + signature: "setLimit(uint256,uint256)", + params: [ + 0, // irrevocable + 500, // revocable + ], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [CONVERTER_NETWORK, "addTokenConverter(address)", arbitrumone.NORMAL_TIMELOCK], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [CONVERTER_NETWORK, "removeTokenConverter(address)", arbitrumone.NORMAL_TIMELOCK], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [ARBITRUM_XVS_VAULT_TREASURY, "fundXVSVault(uint256)", arbitrumone.NORMAL_TIMELOCK], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ARBITRUM_PROTOCOL_SHARE_RESERVE_PROXY, + signature: "addOrUpdateDistributionConfigs((uint8,uint16,address)[])", + params: [ + [ + [0, 6000, ARBITRUM_VTREASURY], + [0, 2000, XVS_VAULT_CONVERTER], + [0, 500, USDC_PRIME_CONVERTER], // 25% of the Prime allocation + [0, 500, USDT_PRIME_CONVERTER], // 25% of the Prime allocation + [0, 300, WBTC_PRIME_CONVERTER], // 15% of the Prime allocation + [0, 700, WETH_PRIME_CONVERTER], // 35% of the Prime allocation + [1, 8000, ARBITRUM_VTREASURY], + [1, 2000, XVS_VAULT_CONVERTER], + ], + ], + dstChainId: LzChainId.arbitrumone, + }, + { + target: USDT_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[0], USDTPrimeConverterTokenOuts, incentiveAndAccessibilities], + dstChainId: LzChainId.arbitrumone, + }, + { + target: USDC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[1], USDCPrimeConverterTokenOuts, incentiveAndAccessibilities], + dstChainId: LzChainId.arbitrumone, + }, + { + target: WBTC_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[2], WBTCPrimeConverterTokenOuts, incentiveAndAccessibilities], + dstChainId: LzChainId.arbitrumone, + }, + { + target: WETH_PRIME_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[3], WETHPrimeConverterTokenOuts, incentiveAndAccessibilities], + dstChainId: LzChainId.arbitrumone, + }, + { + target: XVS_VAULT_CONVERTER, + signature: "setConversionConfigs(address,address[],(uint256,uint8)[])", + params: [BaseAssets[4], XVSVaultConverterTokenOuts, incentiveAndAccessibilities], + dstChainId: LzChainId.arbitrumone, + }, + ...addConverterNetworkCommands, + ], + meta, + ProposalType.REGULAR, + ); +}; + +export default vip395; From 34eadad5f5bf5704f9d6a84b73e78f5693a5c62c Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Wed, 20 Nov 2024 23:37:24 +0530 Subject: [PATCH 151/178] test: Fix oracle ABI --- simulations/vip-395/arbitrumone.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/simulations/vip-395/arbitrumone.ts b/simulations/vip-395/arbitrumone.ts index af3e12895..bfefc914e 100644 --- a/simulations/vip-395/arbitrumone.ts +++ b/simulations/vip-395/arbitrumone.ts @@ -17,6 +17,7 @@ import { XVS_VAULT_TREASURY, converters, } from "../../multisig/proposals/arbitrumone/vip-018/addresses"; +import RESILIENT_ORACLE_ABI from "../../multisig/simulations/arbitrumone/vip-001/abi/resilientOracle.json"; import CONVERTER_NETWORK_ABI from "../../multisig/simulations/arbitrumone/vip-018/abi/ConverterNetwork.json"; import SINGLE_TOKEN_CONVERTER_ABI from "../../multisig/simulations/arbitrumone/vip-018/abi/SingleTokenConverter.json"; import XVS_VAULT_TREASURY_ABI from "../../multisig/simulations/arbitrumone/vip-018/abi/XVSVaultTreasury.json"; @@ -162,7 +163,7 @@ forking(276417316, async () => { before(async () => { usdt = new ethers.Contract(USDT, ERC20_ABI, provider); usdc = new ethers.Contract(USDC, ERC20_ABI, provider); - resilientOracle = new ethers.Contract(arbitrumone.RESILIENT_ORACLE, ORACLE, provider); + resilientOracle = new ethers.Contract(arbitrumone.RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); [, user1] = await ethers.getSigners(); user1Address = await user1.getAddress(); From 34c49b89f2a271db8fa88eec3d1423bbf236191c Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Thu, 21 Nov 2024 00:15:33 +0530 Subject: [PATCH 152/178] fix: vip number 395 to 398 --- simulations/{vip-395 => vip-398}/abi/ERC20.json | 0 simulations/{vip-395 => vip-398}/abi/ILComptroller.json | 0 .../{vip-395 => vip-398}/abi/OmnichainProposalSender.json | 0 simulations/{vip-395 => vip-398}/abi/Prime.json | 0 .../{vip-395 => vip-398}/abi/PrimeLiquidityProvider.json | 0 .../{vip-395 => vip-398}/abi/ProtocolShareReserve.json | 0 simulations/{vip-395 => vip-398}/arbitrumone.ts | 6 +++--- simulations/{vip-395 => vip-398}/arbitrumsepolia.ts | 2 +- simulations/{vip-395 => vip-398}/bscmainnet.ts | 4 ++-- simulations/{vip-395 => vip-398}/bsctestnet.ts | 2 +- vips/{vip-395 => vip-398}/bscmainnet.ts | 6 +++--- vips/{vip-395 => vip-398}/bsctestnet.ts | 0 12 files changed, 10 insertions(+), 10 deletions(-) rename simulations/{vip-395 => vip-398}/abi/ERC20.json (100%) rename simulations/{vip-395 => vip-398}/abi/ILComptroller.json (100%) rename simulations/{vip-395 => vip-398}/abi/OmnichainProposalSender.json (100%) rename simulations/{vip-395 => vip-398}/abi/Prime.json (100%) rename simulations/{vip-395 => vip-398}/abi/PrimeLiquidityProvider.json (100%) rename simulations/{vip-395 => vip-398}/abi/ProtocolShareReserve.json (100%) rename simulations/{vip-395 => vip-398}/arbitrumone.ts (99%) rename simulations/{vip-395 => vip-398}/arbitrumsepolia.ts (99%) rename simulations/{vip-395 => vip-398}/bscmainnet.ts (78%) rename simulations/{vip-395 => vip-398}/bsctestnet.ts (91%) rename vips/{vip-395 => vip-398}/bscmainnet.ts (98%) rename vips/{vip-395 => vip-398}/bsctestnet.ts (100%) diff --git a/simulations/vip-395/abi/ERC20.json b/simulations/vip-398/abi/ERC20.json similarity index 100% rename from simulations/vip-395/abi/ERC20.json rename to simulations/vip-398/abi/ERC20.json diff --git a/simulations/vip-395/abi/ILComptroller.json b/simulations/vip-398/abi/ILComptroller.json similarity index 100% rename from simulations/vip-395/abi/ILComptroller.json rename to simulations/vip-398/abi/ILComptroller.json diff --git a/simulations/vip-395/abi/OmnichainProposalSender.json b/simulations/vip-398/abi/OmnichainProposalSender.json similarity index 100% rename from simulations/vip-395/abi/OmnichainProposalSender.json rename to simulations/vip-398/abi/OmnichainProposalSender.json diff --git a/simulations/vip-395/abi/Prime.json b/simulations/vip-398/abi/Prime.json similarity index 100% rename from simulations/vip-395/abi/Prime.json rename to simulations/vip-398/abi/Prime.json diff --git a/simulations/vip-395/abi/PrimeLiquidityProvider.json b/simulations/vip-398/abi/PrimeLiquidityProvider.json similarity index 100% rename from simulations/vip-395/abi/PrimeLiquidityProvider.json rename to simulations/vip-398/abi/PrimeLiquidityProvider.json diff --git a/simulations/vip-395/abi/ProtocolShareReserve.json b/simulations/vip-398/abi/ProtocolShareReserve.json similarity index 100% rename from simulations/vip-395/abi/ProtocolShareReserve.json rename to simulations/vip-398/abi/ProtocolShareReserve.json diff --git a/simulations/vip-395/arbitrumone.ts b/simulations/vip-398/arbitrumone.ts similarity index 99% rename from simulations/vip-395/arbitrumone.ts rename to simulations/vip-398/arbitrumone.ts index bfefc914e..2cb3cc331 100644 --- a/simulations/vip-395/arbitrumone.ts +++ b/simulations/vip-398/arbitrumone.ts @@ -21,7 +21,7 @@ import RESILIENT_ORACLE_ABI from "../../multisig/simulations/arbitrumone/vip-001 import CONVERTER_NETWORK_ABI from "../../multisig/simulations/arbitrumone/vip-018/abi/ConverterNetwork.json"; import SINGLE_TOKEN_CONVERTER_ABI from "../../multisig/simulations/arbitrumone/vip-018/abi/SingleTokenConverter.json"; import XVS_VAULT_TREASURY_ABI from "../../multisig/simulations/arbitrumone/vip-018/abi/XVSVaultTreasury.json"; -import vip395, { +import vip398, { ARBITRUM_COMPTROLLER_CORE, ARBITRUM_COMPTROLLER_LST, ARBITRUM_PLP, @@ -34,7 +34,7 @@ import vip395, { ARBITRUM_VWETH_LST, ARBITRUM_WBTC, ARBITRUM_WETH, -} from "../../vips/vip-395/bscmainnet"; +} from "../../vips/vip-398/bscmainnet"; import ERC20_ABI from "./abi/ERC20.json"; import COMPTROLLER_ABI from "./abi/ILComptroller.json"; import PRIME_ABI from "./abi/Prime.json"; @@ -82,7 +82,7 @@ forking(276417316, async () => { }); }); - testForkedNetworkVipCommands("VIP 395", await vip395(), { + testForkedNetworkVipCommands("VIP 398", await vip398(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [PRIME_ABI], ["MarketAdded"], [4]); await expectEvents(txResponse, [PRIME_ABI], ["MintLimitsUpdated"], [1]); diff --git a/simulations/vip-395/arbitrumsepolia.ts b/simulations/vip-398/arbitrumsepolia.ts similarity index 99% rename from simulations/vip-395/arbitrumsepolia.ts rename to simulations/vip-398/arbitrumsepolia.ts index 5e398faab..2f8fd16ec 100644 --- a/simulations/vip-395/arbitrumsepolia.ts +++ b/simulations/vip-398/arbitrumsepolia.ts @@ -31,7 +31,7 @@ import vip395, { ARBITRUM_SEPOLIA_VWETH_LST, ARBITRUM_SEPOLIA_WBTC, ARBITRUM_SEPOLIA_WETH, -} from "../../vips/vip-395/bsctestnet"; +} from "../../vips/vip-398/bsctestnet"; import ERC20_ABI from "./abi/ERC20.json"; import COMPTROLLER_ABI from "./abi/ILComptroller.json"; import PRIME_ABI from "./abi/Prime.json"; diff --git a/simulations/vip-395/bscmainnet.ts b/simulations/vip-398/bscmainnet.ts similarity index 78% rename from simulations/vip-395/bscmainnet.ts rename to simulations/vip-398/bscmainnet.ts index 6b8cd3967..caaf115ee 100644 --- a/simulations/vip-395/bscmainnet.ts +++ b/simulations/vip-398/bscmainnet.ts @@ -1,10 +1,10 @@ import { expectEvents } from "../../src/utils"; import { forking, testVip } from "../../src/vip-framework"; -import vip395 from "../../vips/vip-395/bscmainnet"; +import vip398 from "../../vips/vip-398/bscmainnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; forking(44169313, async () => { - testVip("vip395 Arbitrum one Prime configuration", await vip395(), { + testVip("vip398 Arbitrum one Prime configuration", await vip398(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-395/bsctestnet.ts b/simulations/vip-398/bsctestnet.ts similarity index 91% rename from simulations/vip-395/bsctestnet.ts rename to simulations/vip-398/bsctestnet.ts index 17e68e93a..8db5c0844 100644 --- a/simulations/vip-395/bsctestnet.ts +++ b/simulations/vip-398/bsctestnet.ts @@ -1,6 +1,6 @@ import { expectEvents } from "../../src/utils"; import { forking, testVip } from "../../src/vip-framework"; -import vip395 from "../../vips/vip-395/bsctestnet"; +import vip395 from "../../vips/vip-398/bsctestnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; forking(45736960, async () => { diff --git a/vips/vip-395/bscmainnet.ts b/vips/vip-398/bscmainnet.ts similarity index 98% rename from vips/vip-395/bscmainnet.ts rename to vips/vip-398/bscmainnet.ts index 8246669b1..21d710aab 100644 --- a/vips/vip-395/bscmainnet.ts +++ b/vips/vip-398/bscmainnet.ts @@ -44,10 +44,10 @@ export const ARBITRUM_XVS_VAULT_TREASURY = "0xb076D4f15c08D7A7B89466327Ba71bc7e1 export const ARBITRUM_PROTOCOL_SHARE_RESERVE_PROXY = "0xF9263eaF7eB50815194f26aCcAB6765820B13D41"; export const ARBITRUM_VTREASURY = "0x8a662ceAC418daeF956Bc0e6B2dd417c80CDA631"; -const vip395 = () => { +const vip398 = () => { const meta = { version: "v2", - title: "vip395 arbitrum Prime configuration", + title: "vip398 arbitrum Prime configuration", description: `#### Description This VIP will grant permission to timelocks and performs the necessary configuration of OmnichainProposalSender on BNB chain and OmnichainProposalExecutor`, forDescription: "I agree that Venus Protocol should proceed with this proposal", @@ -181,4 +181,4 @@ const vip395 = () => { ); }; -export default vip395; +export default vip398; diff --git a/vips/vip-395/bsctestnet.ts b/vips/vip-398/bsctestnet.ts similarity index 100% rename from vips/vip-395/bsctestnet.ts rename to vips/vip-398/bsctestnet.ts From 856f1b8aba949a479823ab78980b6783a77adec3 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Thu, 21 Nov 2024 15:58:57 +0100 Subject: [PATCH 153/178] feat: define the specific gas limits per network --- hardhat.config.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/hardhat.config.ts b/hardhat.config.ts index a8a42d8ac..5774773f7 100644 --- a/hardhat.config.ts +++ b/hardhat.config.ts @@ -26,11 +26,11 @@ const BLOCK_GAS_LIMIT_PER_NETWORK = { ethereum: 30000000, opbnbtestnet: 100000000, opbnbmainnet: 100000000, - arbitrumsepolia: 30000000, - arbitrumone: 30000000, - opsepolia: 30000000, - opmainnet: 30000000, - basesepolia: 30000000, + arbitrumsepolia: 32000000, + arbitrumone: 32000000, + opsepolia: 60000000, + opmainnet: 60000000, + basesepolia: 60000000, }; task("propose", "Propose proposal") From fae4fa54c9edd07aee6294b23d6c6f2b5cb76da5 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Thu, 21 Nov 2024 15:59:32 +0100 Subject: [PATCH 154/178] feat: configure the resilient oracle for base sepolia --- .../proposals/basesepolia/vip-000/index.ts | 92 ++++++++++++++ .../simulations/basesepolia/vip-000/index.ts | 119 +++++++++++++++--- 2 files changed, 191 insertions(+), 20 deletions(-) diff --git a/multisig/proposals/basesepolia/vip-000/index.ts b/multisig/proposals/basesepolia/vip-000/index.ts index 326599bbb..5f30b6ae1 100644 --- a/multisig/proposals/basesepolia/vip-000/index.ts +++ b/multisig/proposals/basesepolia/vip-000/index.ts @@ -7,6 +7,18 @@ export const TREASURY = "0x07e880DaA6572829cE8ABaaf0f5323A4eFC417A6"; export const ACM = "0x724138223D8F76b519fdE715f60124E7Ce51e051"; export const BOUND_VALIDATOR = "0xC76284488E57554A457A75a8b166fB2ADAB430dB"; +const CHAINLINK_BTC_FEED = "0x0FB99723Aee6f420beAD13e6bBB79b7E6F034298"; +const CHAINLINK_ETH_FEED = "0x4aDC67696bA383F43DD60A9e78F2C97Fbbfc7cb1"; +const CHAINLINK_USDC_FEED = "0xd30e2101a97dcbAeBCBC04F14C3f624E67A35165"; + +const cbBTC = "0x0948001047A07e38F685f9a11ea1ddB16B234af9"; +const WETH = "0x4200000000000000000000000000000000000006"; +const USDC = "0xFa264c13d657180e65245a9C3ac8d08b9F5Fc54D"; +const XVS = "0xE657EDb5579B82135a274E85187927C42E38C021"; + +const STALE_PERIOD_26H = 60 * 60 * 26; // 26 hours (pricefeeds with heartbeat of 24 hr) +const STALE_PERIOD_30M = 60 * 30; // 30 minutes (pricefeeds with heartbeat of 20 minutes) + const vip000 = () => { return makeProposal([ { @@ -84,6 +96,86 @@ const vip000 = () => { signature: "acceptOwnership()", params: [], }, + { + target: basesepolia.CHAINLINK_ORACLE, + signature: "setTokenConfig((address,address,uint256))", + params: [[cbBTC, CHAINLINK_BTC_FEED, STALE_PERIOD_30M]], + }, + { + target: basesepolia.RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [ + cbBTC, + [ + basesepolia.CHAINLINK_ORACLE, + "0x0000000000000000000000000000000000000000", + "0x0000000000000000000000000000000000000000", + ], + [true, false, false], + ], + ], + }, + { + target: basesepolia.CHAINLINK_ORACLE, + signature: "setTokenConfig((address,address,uint256))", + params: [[WETH, CHAINLINK_ETH_FEED, STALE_PERIOD_30M]], + }, + { + target: basesepolia.RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [ + WETH, + [ + basesepolia.CHAINLINK_ORACLE, + "0x0000000000000000000000000000000000000000", + "0x0000000000000000000000000000000000000000", + ], + [true, false, false], + ], + ], + }, + { + target: basesepolia.CHAINLINK_ORACLE, + signature: "setTokenConfig((address,address,uint256))", + params: [[USDC, CHAINLINK_USDC_FEED, STALE_PERIOD_26H]], + }, + { + target: basesepolia.RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [ + USDC, + [ + basesepolia.CHAINLINK_ORACLE, + "0x0000000000000000000000000000000000000000", + "0x0000000000000000000000000000000000000000", + ], + [true, false, false], + ], + ], + }, + { + target: basesepolia.REDSTONE_ORACLE, + signature: "setDirectPrice(address,uint256)", + params: [XVS, "10000000000000000000"], + }, + { + target: basesepolia.RESILIENT_ORACLE, + signature: "setTokenConfig((address,address[3],bool[3]))", + params: [ + [ + XVS, + [ + basesepolia.REDSTONE_ORACLE, + "0x0000000000000000000000000000000000000000", + "0x0000000000000000000000000000000000000000", + ], + [true, false, false], + ], + ], + }, ]); }; diff --git a/multisig/simulations/basesepolia/vip-000/index.ts b/multisig/simulations/basesepolia/vip-000/index.ts index 4f218df1d..82499270c 100644 --- a/multisig/simulations/basesepolia/vip-000/index.ts +++ b/multisig/simulations/basesepolia/vip-000/index.ts @@ -11,39 +11,118 @@ import REDSTONE_ORACLE_ABI from "./abi/chainlinkOracle.json"; import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; import TREASURY_ABI from "./abi/treasury.json"; -forking(17947005, async () => { +const { basesepolia } = NETWORK_ADDRESSES; + +const RESILIENT_ORACLE = basesepolia.RESILIENT_ORACLE; +const CHAINLINK_ORACLE = basesepolia.CHAINLINK_ORACLE; +const REDSTONE_ORACLE = basesepolia.REDSTONE_ORACLE; +const GUARDIAN = basesepolia.GUARDIAN; + +interface AssetConfig { + name: string; + address: string; + price: string; + feed: string; + oracle: string; +} +interface AssetDirectPriceConfig { + name: string; + address: string; + price: string; +} + +const assetConfigs: AssetConfig[] = [ + { + name: "USDC", + address: "0xFa264c13d657180e65245a9C3ac8d08b9F5Fc54D", + price: "999940000000000000000000000000", + feed: "0xd30e2101a97dcbAeBCBC04F14C3f624E67A35165", + oracle: "chainlink", + }, + { + name: "cbBTC", + address: "0x0948001047A07e38F685f9a11ea1ddB16B234af9", + price: "975122118780000000000000000000000", + feed: "0x0FB99723Aee6f420beAD13e6bBB79b7E6F034298", + oracle: "chainlink", + }, + { + name: "WETH", + address: "0x4200000000000000000000000000000000000006", + price: "3361650000000000000000", + feed: "0x4aDC67696bA383F43DD60A9e78F2C97Fbbfc7cb1", + oracle: "chainlink", + }, +]; + +const directAssetPriceConfig: AssetDirectPriceConfig = { + name: "XVS", + address: "0xE657EDb5579B82135a274E85187927C42E38C021", + price: "10000000000000000000", +}; + +forking(18216178, async () => { + const provider = ethers.provider; let treasury: Contract; let resilientOracle: Contract; let chainlinkOracle: Contract; let redstoneOracle: Contract; let boundValidator: Contract; - before(async () => { - treasury = await ethers.getContractAt(TREASURY_ABI, TREASURY); - resilientOracle = await ethers.getContractAt(RESILIENT_ORACLE_ABI, NETWORK_ADDRESSES.basesepolia.RESILIENT_ORACLE); - chainlinkOracle = await ethers.getContractAt(CHAINLINK_ORACLE_ABI, NETWORK_ADDRESSES.basesepolia.CHAINLINK_ORACLE); - redstoneOracle = await ethers.getContractAt(REDSTONE_ORACLE_ABI, NETWORK_ADDRESSES.basesepolia.REDSTONE_ORACLE); - boundValidator = await ethers.getContractAt(BOUND_VALIDATOR_ABI, BOUND_VALIDATOR); + describe("Pre-VIP behavior", async () => { + before(async () => { + treasury = await ethers.getContractAt(TREASURY_ABI, TREASURY); + resilientOracle = new ethers.Contract(RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); + chainlinkOracle = new ethers.Contract(CHAINLINK_ORACLE, CHAINLINK_ORACLE_ABI, provider); + redstoneOracle = new ethers.Contract(REDSTONE_ORACLE, REDSTONE_ORACLE_ABI, provider); + boundValidator = new ethers.Contract(BOUND_VALIDATOR, BOUND_VALIDATOR_ABI, provider); + }); + + it("correct pending owner", async () => { + expect(await resilientOracle.pendingOwner()).to.equal(GUARDIAN); + expect(await chainlinkOracle.pendingOwner()).to.equal(GUARDIAN); + expect(await redstoneOracle.pendingOwner()).to.equal(GUARDIAN); + expect(await boundValidator.pendingOwner()).to.equal(GUARDIAN); + }); + + it("should revert for unconfigured asset price request", async () => { + for (let i = 0; i < assetConfigs.length; i++) { + const assetConfig = assetConfigs[i]; + await expect(resilientOracle.getPrice(assetConfig.address)).to.be.revertedWith( + "invalid resilient oracle price", + ); + } - await pretendExecutingVip(await vip000()); + await expect(resilientOracle.getPrice(directAssetPriceConfig.address)).to.be.revertedWith( + "invalid resilient oracle price", + ); + }); }); - describe("Post tx checks", () => { - it("Should set owner to multisig", async () => { - let owner = await treasury.owner(); - expect(owner).equals(NETWORK_ADDRESSES.basesepolia.GUARDIAN); + describe("Post-VIP behavior", async () => { + before(async () => { + await pretendExecutingVip(await vip000()); + }); - owner = await resilientOracle.owner(); - expect(owner).equals(NETWORK_ADDRESSES.basesepolia.GUARDIAN); + it("correct owner", async () => { + expect(await treasury.owner()).to.equal(GUARDIAN); + expect(await resilientOracle.owner()).to.equal(GUARDIAN); + expect(await chainlinkOracle.owner()).to.equal(GUARDIAN); + expect(await redstoneOracle.owner()).to.equal(GUARDIAN); + expect(await boundValidator.owner()).to.equal(GUARDIAN); + }); - owner = await chainlinkOracle.owner(); - expect(owner).equals(NETWORK_ADDRESSES.basesepolia.GUARDIAN); + it("validate asset prices", async () => { + for (let i = 0; i < assetConfigs.length; i++) { + const assetConfig = assetConfigs[i]; + const price = await resilientOracle.getPrice(assetConfig.address); - owner = await boundValidator.owner(); - expect(owner).equals(NETWORK_ADDRESSES.basesepolia.GUARDIAN); + expect(price).to.be.equal(assetConfig.price); + } - owner = await redstoneOracle.owner(); - expect(owner).equals(NETWORK_ADDRESSES.basesepolia.GUARDIAN); + await expect(await resilientOracle.getPrice(directAssetPriceConfig.address)).to.be.equal( + directAssetPriceConfig.price, + ); }); }); }); From 563c701d661ec184a187dd111304ae60c8749e57 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Fri, 22 Nov 2024 10:05:53 +0530 Subject: [PATCH 155/178] refactor: description and remove console --- multisig/proposals/arbitrumone/vip-018/addresses.ts | 2 -- multisig/simulations/arbitrumone/vip-018/index.ts | 6 +++--- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/multisig/proposals/arbitrumone/vip-018/addresses.ts b/multisig/proposals/arbitrumone/vip-018/addresses.ts index d3fb77412..e83c78f49 100644 --- a/multisig/proposals/arbitrumone/vip-018/addresses.ts +++ b/multisig/proposals/arbitrumone/vip-018/addresses.ts @@ -41,5 +41,3 @@ export const USDCPrimeConverterTokenOuts = filterAssets(Assets, BaseAssets[1]); export const WBTCPrimeConverterTokenOuts = filterAssets(Assets, BaseAssets[2]); export const WETHPrimeConverterTokenOuts = filterAssets(Assets, BaseAssets[3]); export const XVSVaultConverterTokenOuts = filterAssets(Assets, BaseAssets[4]); -console.log("-------------- USDT", USDTPrimeConverterTokenOuts); -console.log("-------------- USDC", USDCPrimeConverterTokenOuts); diff --git a/multisig/simulations/arbitrumone/vip-018/index.ts b/multisig/simulations/arbitrumone/vip-018/index.ts index c3e5ff7dd..534287eea 100644 --- a/multisig/simulations/arbitrumone/vip-018/index.ts +++ b/multisig/simulations/arbitrumone/vip-018/index.ts @@ -71,18 +71,18 @@ forking(276102872, async () => { describe("Converters configuration", () => { describe("Owner checks", () => { - it("Timelock should be the owner of all converters", async () => { + it("GUARDIAN should be the owner of all converters", async () => { for (const converter of converters) { const Converter = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); expect(await Converter.owner()).to.equal(arbitrumone.GUARDIAN); } }); - it("Timelock should be the owner of ConverterNetwork", async () => { + it("GUARDIAN should be the owner of ConverterNetwork", async () => { expect(await converterNetwork.owner()).to.equal(arbitrumone.GUARDIAN); }); - it("Timelock should be the owner of XVSVaultTreasury", async () => { + it("GUARDIAN should be the owner of XVSVaultTreasury", async () => { expect(await xvsVaultTreasury.owner()).to.equal(arbitrumone.GUARDIAN); }); }); From 9eb1ca74b9aaa0abf80afb2c73270ce98384c5b7 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Fri, 22 Nov 2024 10:18:00 +0530 Subject: [PATCH 156/178] refactor: test description --- simulations/vip-398/arbitrumone.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/simulations/vip-398/arbitrumone.ts b/simulations/vip-398/arbitrumone.ts index 2cb3cc331..5596be381 100644 --- a/simulations/vip-398/arbitrumone.ts +++ b/simulations/vip-398/arbitrumone.ts @@ -133,18 +133,18 @@ forking(276417316, async () => { }); describe("Owner checks", () => { - it("Timelock should be the owner of all converters", async () => { + it("GUARDIAN should be the owner of all converters", async () => { for (const converter of converters) { const Converter = new ethers.Contract(converter, SINGLE_TOKEN_CONVERTER_ABI, provider); expect(await Converter.owner()).to.equal(arbitrumone.GUARDIAN); } }); - it("Timelock should be the owner of ConverterNetwork", async () => { + it("GUARDIAN should be the owner of ConverterNetwork", async () => { expect(await converterNetwork.owner()).to.equal(arbitrumone.GUARDIAN); }); - it("Timelock should be the owner of XVSVaultTreasury", async () => { + it("GUARDIAN should be the owner of XVSVaultTreasury", async () => { expect(await xvsVaultTreasury.owner()).to.equal(arbitrumone.GUARDIAN); }); }); From 912b448f667c3cd683166fd3d3556fd7d19fd6f7 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Fri, 22 Nov 2024 16:29:41 +0100 Subject: [PATCH 157/178] feat: VIP to increase supply cap of SolvBTC --- simulations/vip-398/abi/CoreComptroller.json | 954 +++++++++++++++++++ simulations/vip-398/bscmainnet.ts | 41 + vips/vip-398/bscmainnet.ts | 40 + 3 files changed, 1035 insertions(+) create mode 100644 simulations/vip-398/abi/CoreComptroller.json create mode 100644 simulations/vip-398/bscmainnet.ts create mode 100644 vips/vip-398/bscmainnet.ts diff --git a/simulations/vip-398/abi/CoreComptroller.json b/simulations/vip-398/abi/CoreComptroller.json new file mode 100644 index 000000000..ad25568bc --- /dev/null +++ b/simulations/vip-398/abi/CoreComptroller.json @@ -0,0 +1,954 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "poolRegistry_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "ActionPaused", + "type": "error" + }, + { "inputs": [], "name": "BorrowActionNotPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "BorrowCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "BorrowCapIsNotZero", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedLessThanOrEqualTo", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "CollateralExceedsThreshold", + "type": "error" + }, + { "inputs": [], "name": "CollateralFactorIsNotZero", "type": "error" }, + { "inputs": [], "name": "ComptrollerMismatch", "type": "error" }, + { "inputs": [], "name": "DelegationStatusUnchanged", "type": "error" }, + { "inputs": [], "name": "EnterMarketActionNotPaused", "type": "error" }, + { "inputs": [], "name": "ExitMarketActionNotPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "uint256", "name": "collateralToSeize", "type": "uint256" }, + { "internalType": "uint256", "name": "availableCollateral", "type": "uint256" } + ], + "name": "InsufficientCollateral", + "type": "error" + }, + { "inputs": [], "name": "InsufficientLiquidity", "type": "error" }, + { "inputs": [], "name": "InsufficientShortfall", "type": "error" }, + { "inputs": [], "name": "InvalidCollateralFactor", "type": "error" }, + { "inputs": [], "name": "InvalidLiquidationThreshold", "type": "error" }, + { "inputs": [], "name": "LiquidateActionNotPaused", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketAlreadyListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "MarketNotCollateral", + "type": "error" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "MarketNotListed", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopsLimit", "type": "uint256" }, + { "internalType": "uint256", "name": "requiredLoops", "type": "uint256" } + ], + "name": "MaxLoopsLimitExceeded", + "type": "error" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "expectedGreaterThan", "type": "uint256" }, + { "internalType": "uint256", "name": "actual", "type": "uint256" } + ], + "name": "MinimalCollateralViolated", + "type": "error" + }, + { "inputs": [], "name": "MintActionNotPaused", "type": "error" }, + { "inputs": [], "name": "NonzeroBorrowBalance", "type": "error" }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "PriceError", + "type": "error" + }, + { "inputs": [], "name": "RedeemActionNotPaused", "type": "error" }, + { "inputs": [], "name": "RepayActionNotPaused", "type": "error" }, + { "inputs": [], "name": "SeizeActionNotPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "user", "type": "address" } + ], + "name": "SnapshotError", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "uint256", "name": "cap", "type": "uint256" } + ], + "name": "SupplyCapExceeded", + "type": "error" + }, + { "inputs": [], "name": "SupplyCapIsNotZero", "type": "error" }, + { "inputs": [], "name": "TooMuchRepay", "type": "error" }, + { "inputs": [], "name": "TransferActionNotPaused", "type": "error" }, + { + "inputs": [ + { "internalType": "address", "name": "sender", "type": "address" }, + { "internalType": "address", "name": "calledContract", "type": "address" }, + { "internalType": "string", "name": "methodSignature", "type": "string" } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [ + { "internalType": "address", "name": "expectedSender", "type": "address" }, + { "internalType": "address", "name": "actualSender", "type": "address" } + ], + "name": "UnexpectedSender", + "type": "error" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "enum Action", "name": "action", "type": "uint8" }, + { "indexed": false, "internalType": "bool", "name": "pauseState", "type": "bool" } + ], + "name": "ActionPausedMarket", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "approver", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "DelegateUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "IsForcedLiquidationEnabledUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketEntered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "account", "type": "address" } + ], + "name": "MarketExited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "MarketSupported", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "address", "name": "vToken", "type": "address" }], + "name": "MarketUnlisted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMaxLoopsLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newmaxLoopsLimit", "type": "uint256" } + ], + "name": "MaxLoopsLimitUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newBorrowCap", "type": "uint256" } + ], + "name": "NewBorrowCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldCloseFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" } + ], + "name": "NewCloseFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldCollateralFactorMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" } + ], + "name": "NewCollateralFactor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationIncentiveMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" } + ], + "name": "NewLiquidationIncentive", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "oldLiquidationThresholdMantissa", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "NewLiquidationThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "uint256", "name": "oldMinLiquidatableCollateral", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" } + ], + "name": "NewMinLiquidatableCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "oldPriceOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "contract ResilientOracleInterface", + "name": "newPriceOracle", + "type": "address" + } + ], + "name": "NewPriceOracle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": false, "internalType": "contract IPrime", "name": "oldPrimeToken", "type": "address" }, + { "indexed": false, "internalType": "contract IPrime", "name": "newPrimeToken", "type": "address" } + ], + "name": "NewPrimeToken", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "rewardsDistributor", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "rewardToken", "type": "address" } + ], + "name": "NewRewardsDistributor", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newSupplyCap", "type": "uint256" } + ], + "name": "NewSupplyCap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "name": "accountAssets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "market", "type": "address" }, + { "internalType": "enum Action", "name": "action", "type": "uint8" } + ], + "name": "actionPaused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract RewardsDistributor", "name": "_rewardsDistributor", "type": "address" }], + "name": "addRewardsDistributor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "allMarkets", + "outputs": [{ "internalType": "contract VToken", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "approvedDelegates", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "borrowCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "borrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "contract VToken", "name": "vToken", "type": "address" } + ], + "name": "checkMembership", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "closeFactorMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address[]", "name": "vTokens", "type": "address[]" }], + "name": "enterMarkets", + "outputs": [{ "internalType": "uint256[]", "name": "", "type": "uint256[]" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vTokenAddress", "type": "address" }], + "name": "exitMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getAllMarkets", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getAssetsIn", + "outputs": [{ "internalType": "contract VToken[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "getBorrowingPower", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account", "type": "address" }, + { "internalType": "address", "name": "vTokenModify", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "getHypotheticalAccountLiquidity", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidity", "type": "uint256" }, + { "internalType": "uint256", "name": "shortfall", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRewardDistributors", + "outputs": [{ "internalType": "contract RewardsDistributor[]", "name": "", "type": "address[]" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "vToken", "type": "address" }], + "name": "getRewardsByMarket", + "outputs": [ + { + "components": [ + { "internalType": "address", "name": "rewardToken", "type": "address" }, + { "internalType": "uint256", "name": "supplySpeed", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowSpeed", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.RewardSpeeds[]", + "name": "rewardSpeeds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "healAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "loopLimit", "type": "uint256" }, + { "internalType": "address", "name": "accessControlManager", "type": "address" } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "isComptroller", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "isForcedLiquidationEnabled", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "isMarketListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "borrower", "type": "address" }, + { + "components": [ + { "internalType": "contract VToken", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "contract VToken", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" } + ], + "internalType": "struct ComptrollerStorage.LiquidationOrder[]", + "name": "orders", + "type": "tuple[]" + } + ], + "name": "liquidateAccount", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "liquidateBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" } + ], + "name": "liquidateCalculateSeizeTokens", + "outputs": [ + { "internalType": "uint256", "name": "error", "type": "uint256" }, + { "internalType": "uint256", "name": "tokensToSeize", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "liquidationIncentiveMantissa", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "markets", + "outputs": [ + { "internalType": "bool", "name": "isListed", "type": "bool" }, + { "internalType": "uint256", "name": "collateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "liquidationThresholdMantissa", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "maxLoopsLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minLiquidatableCollateral", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "actualMintAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "mintTokens", "type": "uint256" } + ], + "name": "mintVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [{ "internalType": "contract ResilientOracleInterface", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "poolRegistry", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "borrowAmount", "type": "uint256" } + ], + "name": "preBorrowHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "repayAmount", "type": "uint256" }, + { "internalType": "bool", "name": "skipLiquidityCheck", "type": "bool" } + ], + "name": "preLiquidateHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "minter", "type": "address" }, + { "internalType": "uint256", "name": "mintAmount", "type": "uint256" } + ], + "name": "preMintHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "preRedeemHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preRepayHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "seizerContract", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" } + ], + "name": "preSeizeHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "preTransferHook", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "prime", + "outputs": [{ "internalType": "contract IPrime", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "redeemer", "type": "address" }, + { "internalType": "uint256", "name": "redeemAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "redeemTokens", "type": "uint256" } + ], + "name": "redeemVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "payer", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "actualRepayAmount", "type": "uint256" }, + { "internalType": "uint256", "name": "borrowerIndex", "type": "uint256" } + ], + "name": "repayBorrowVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenCollateral", "type": "address" }, + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "address", "name": "liquidator", "type": "address" }, + { "internalType": "address", "name": "borrower", "type": "address" }, + { "internalType": "uint256", "name": "seizeTokens", "type": "uint256" } + ], + "name": "seizeVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "marketsList", "type": "address[]" }, + { "internalType": "enum Action[]", "name": "actionsList", "type": "uint8[]" }, + { "internalType": "bool", "name": "paused", "type": "bool" } + ], + "name": "setActionsPaused", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newCloseFactorMantissa", "type": "uint256" }], + "name": "setCloseFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken", "name": "vToken", "type": "address" }, + { "internalType": "uint256", "name": "newCollateralFactorMantissa", "type": "uint256" }, + { "internalType": "uint256", "name": "newLiquidationThresholdMantissa", "type": "uint256" } + ], + "name": "setCollateralFactor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vTokenBorrowed", "type": "address" }, + { "internalType": "bool", "name": "enable", "type": "bool" } + ], + "name": "setForcedLiquidation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newLiquidationIncentiveMantissa", "type": "uint256" }], + "name": "setLiquidationIncentive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newBorrowCaps", "type": "uint256[]" } + ], + "name": "setMarketBorrowCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "contract VToken[]", "name": "vTokens", "type": "address[]" }, + { "internalType": "uint256[]", "name": "newSupplyCaps", "type": "uint256[]" } + ], + "name": "setMarketSupplyCaps", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "limit", "type": "uint256" }], + "name": "setMaxLoopsLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "newMinLiquidatableCollateral", "type": "uint256" }], + "name": "setMinLiquidatableCollateral", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract ResilientOracleInterface", "name": "newOracle", "type": "address" }], + "name": "setPriceOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract IPrime", "name": "_prime", "type": "address" }], + "name": "setPrimeToken", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "supplyCaps", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "contract VToken", "name": "vToken", "type": "address" }], + "name": "supportMarket", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "vToken", "type": "address" }, + { "internalType": "address", "name": "src", "type": "address" }, + { "internalType": "address", "name": "dst", "type": "address" }, + { "internalType": "uint256", "name": "transferTokens", "type": "uint256" } + ], + "name": "transferVerify", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "market", "type": "address" }], + "name": "unlistMarket", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "delegate", "type": "address" }, + { "internalType": "bool", "name": "approved", "type": "bool" } + ], + "name": "updateDelegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "updatePrices", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-398/bscmainnet.ts b/simulations/vip-398/bscmainnet.ts new file mode 100644 index 000000000..27aa375cf --- /dev/null +++ b/simulations/vip-398/bscmainnet.ts @@ -0,0 +1,41 @@ +import { expect } from "chai"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { expectEvents } from "src/utils"; +import { forking, testVip } from "src/vip-framework"; + +import { CORE_COMPTROLLER, vSOLVBTC_CORE, vSOLVBTC_CORE_SUPPLY_CAP, vip398 } from "../../vips/vip-398/bscmainnet"; +import CORE_COMPTROLLER_ABI from "./abi/CoreComptroller.json"; + +const vSOLVBTC_CORE_SUPPLY_CAP_PREV = parseUnits("100", 18); + +forking(44235928, async () => { + const provider = ethers.provider; + const coreComptroller = new ethers.Contract(CORE_COMPTROLLER, CORE_COMPTROLLER_ABI, provider); + + describe("Pre-VIP behavior", async () => { + describe("CORE pool checks", () => { + it("check supply cap for SOLVBTC", async () => { + const supplyCap = await coreComptroller.supplyCaps(vSOLVBTC_CORE); + + expect(supplyCap).to.eq(vSOLVBTC_CORE_SUPPLY_CAP_PREV); + }); + }); + }); + + testVip("VIP-398", await vip398(), { + callbackAfterExecution: async txResponse => { + await expectEvents(txResponse, [CORE_COMPTROLLER_ABI], ["NewSupplyCap"], [1]); + }, + }); + + describe("Post-VIP behavior", async () => { + describe("CORE pool checks", () => { + it("check supply cap for SOLVBTC", async () => { + const supplyCap = await coreComptroller.supplyCaps(vSOLVBTC_CORE); + + expect(supplyCap).to.eq(vSOLVBTC_CORE_SUPPLY_CAP); + }); + }); + }); +}); diff --git a/vips/vip-398/bscmainnet.ts b/vips/vip-398/bscmainnet.ts new file mode 100644 index 000000000..174473bcf --- /dev/null +++ b/vips/vip-398/bscmainnet.ts @@ -0,0 +1,40 @@ +import { parseUnits } from "ethers/lib/utils"; +import { ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +export const CORE_COMPTROLLER = "0xfD36E2c2a6789Db23113685031d7F16329158384"; +export const vSOLVBTC_CORE = "0xf841cb62c19fCd4fF5CD0AaB5939f3140BaaC3Ea"; + +export const vSOLVBTC_CORE_SUPPLY_CAP = parseUnits("200", 18); + +export const vip398 = () => { + const meta = { + version: "v2", + title: "VIP-398 [BNB Chain] Risk Parameters Adjustments (SolvBTC)", + description: `If passed, this VIP will perform the following actions as per Chaos Labs’ latest recommendations in this Venus community forum publication: [Chaos Labs - Risk Parameter Updates - 11/05/24](https://community.venus.io/t/chaos-labs-risk-parameter-updates-11-05-24/4708) + +- [SolvBTC (Core pool)](https://bscscan.com/address/0xf841cb62c19fCd4fF5CD0AaB5939f3140BaaC3Ea): + - Increase supply cap, from 100 SolvBTC to 200 SolvBTC + +Complete analysis and details of these recommendations are available in the above publications. + +VIP simulation: [https://github.com/VenusProtocol/vips/pull/430](https://github.com/VenusProtocol/vips/pull/430)`, + forDescription: "Execute this proposal", + againstDescription: "Do not execute this proposal", + abstainDescription: "Indifferent to execution", + }; + + return makeProposal( + [ + { + target: CORE_COMPTROLLER, + signature: "_setMarketSupplyCaps(address[],uint256[])", + params: [[vSOLVBTC_CORE], [vSOLVBTC_CORE_SUPPLY_CAP]], + }, + ], + meta, + ProposalType.FAST_TRACK, + ); +}; + +export default vip398; From 572a1daba7d02b13b1e24d3db3bd1171548f2e23 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Mon, 25 Nov 2024 15:36:17 +0530 Subject: [PATCH 158/178] test: add tests to claim prime --- simulations/vip-398/arbitrumone.ts | 34 ++++++++++++++++++++++++++++-- 1 file changed, 32 insertions(+), 2 deletions(-) diff --git a/simulations/vip-398/arbitrumone.ts b/simulations/vip-398/arbitrumone.ts index 5596be381..c70e0a561 100644 --- a/simulations/vip-398/arbitrumone.ts +++ b/simulations/vip-398/arbitrumone.ts @@ -1,7 +1,7 @@ import { expect } from "chai"; import { BigNumber, Contract, Signer } from "ethers"; import { parseUnits } from "ethers/lib/utils"; -import { ethers } from "hardhat"; +import { ethers, network } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents, initMainnetUser, setMaxStalePeriod } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; @@ -13,6 +13,9 @@ import { USDC_PRIME_CONVERTER, USDT, USDT_PRIME_CONVERTER, + WBTC_PRIME_CONVERTER, + WETH_PRIME_CONVERTER, + XVS, XVS_VAULT_CONVERTER, XVS_VAULT_TREASURY, converters, @@ -44,10 +47,11 @@ import PROTOCOL_SHARE_RESERVE_ABI from "./abi/ProtocolShareReserve.json"; const { arbitrumone } = NETWORK_ADDRESSES; const USDT_HOLDER = "0x3931dAb967C3E2dbb492FE12460a66d0fe4cC857"; const USDC_HOLDER = "0x47c031236e19d024b42f8AE6780E44A573170703"; +const XVS_USER = "0xf805cEf7E0125811d0E64c597A66aE55cFc54143"; const ARBITRUM_PROTOCOL_SHARE_RESERVE_PROXY = "0xF9263eaF7eB50815194f26aCcAB6765820B13D41"; -forking(276417316, async () => { +forking(278099102, async () => { const provider = ethers.provider; let prime: Contract; let converterNetwork: Contract; @@ -157,12 +161,15 @@ forking(276417316, async () => { let usdcHolder: Signer; let user1Address: string; let resilientOracle: Contract; + let xvs: Contract; const amount = parseUnits("1000", 6); before(async () => { usdt = new ethers.Contract(USDT, ERC20_ABI, provider); usdc = new ethers.Contract(USDC, ERC20_ABI, provider); + xvs = new ethers.Contract(XVS, ERC20_ABI, provider); + resilientOracle = new ethers.Contract(arbitrumone.RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); [, user1] = await ethers.getSigners(); @@ -175,6 +182,7 @@ forking(276417316, async () => { await usdc.connect(usdcHolder).transfer(user1Address, amount); await setMaxStalePeriod(resilientOracle, usdt); await setMaxStalePeriod(resilientOracle, usdc); + await setMaxStalePeriod(resilientOracle, xvs); }); it("PSR should have correct distribution configs", async () => { @@ -290,5 +298,27 @@ forking(276417316, async () => { parseUnits("1", 7), ); }); + + it("claim prime token", async () => { + await network.provider.send("hardhat_setCode", [XVS_USER, "0x"]); + const xvsUserSigner = await initMainnetUser(XVS_USER, parseUnits("1")); + + await expect(prime.connect(xvsUserSigner).claim()).to.be.revertedWithCustomError(prime, "Unauthorized"); + + let interestAccrued = await prime.callStatic.getInterestAccrued(USDT_PRIME_CONVERTER, XVS_USER); + expect(interestAccrued).to.be.equal(0); + + interestAccrued = await prime.callStatic.getInterestAccrued(USDC_PRIME_CONVERTER, XVS_USER); + expect(interestAccrued).to.be.equal(0); + + interestAccrued = await prime.callStatic.getInterestAccrued(WBTC_PRIME_CONVERTER, XVS_USER); + expect(interestAccrued).to.be.equal(0); + + interestAccrued = await prime.callStatic.getInterestAccrued(WETH_PRIME_CONVERTER, XVS_USER); + expect(interestAccrued).to.be.equal(0); + + interestAccrued = await prime.callStatic.getInterestAccrued(XVS_VAULT_CONVERTER, XVS_USER); + expect(interestAccrued).to.be.equal(0); + }); }); }); From fadcdc0b09be4ca6b55256feccd52dc972d36c9b Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Fri, 22 Nov 2024 19:10:28 +0100 Subject: [PATCH 159/178] feat: set ID and description for the VIP 399 --- hardhat.config.zksync.ts | 2 +- .../{vip-010 => vip-016}/index.ts | 4 +- .../abi/AccessControlManagerAbi.json | 0 .../{vip-010 => vip-016}/index.ts | 4 +- simulations/vip-395/abi/ACMAggregator.json | 242 -------- .../vip-395/abi/AccessControlManager_ABI.json | 157 ----- .../abi/OmnichainExecutorOwner_ABI.json | 145 ----- .../abi/OmnichainGovernanceExecutor_ABI.json | 539 ------------------ .../vip-395/abi/OmnichainProposalSender.json | 314 ---------- .../abi/ACMAggregator.json | 0 .../abi/AccessControlManager_ABI.json | 0 .../abi/OmnichainExecutorOwner_ABI.json | 0 .../abi/OmnichainGovernanceExecutor_ABI.json | 0 .../abi/OmnichainProposalSender.json | 0 .../{vip-395 => vip-399}/bscmainnet.ts | 4 +- .../bsctestnet-opsepolia.ts} | 4 +- .../bsctestnet-zksyncsepolia.ts} | 4 +- simulations/{vip-395 => vip-399}/opmainnet.ts | 6 +- simulations/{vip-389 => vip-399}/opsepolia.ts | 8 +- .../{vip-395 => vip-399}/zksyncmainnet.ts | 6 +- .../{vip-395 => vip-399}/zksyncsepolia.ts | 10 +- vips/vip-395/bscmainnet.ts | 112 ---- vips/vip-399/bscmainnet.ts | 198 +++++++ .../bsctestnet-opsepolia.ts} | 6 +- .../bsctestnet-zksyncsepolia.ts} | 6 +- 25 files changed, 230 insertions(+), 1541 deletions(-) rename multisig/proposals/zksyncsepolia/{vip-010 => vip-016}/index.ts (90%) rename multisig/simulations/zksyncsepolia/{vip-010 => vip-016}/abi/AccessControlManagerAbi.json (100%) rename multisig/simulations/zksyncsepolia/{vip-010 => vip-016}/index.ts (86%) delete mode 100644 simulations/vip-395/abi/ACMAggregator.json delete mode 100644 simulations/vip-395/abi/AccessControlManager_ABI.json delete mode 100644 simulations/vip-395/abi/OmnichainExecutorOwner_ABI.json delete mode 100644 simulations/vip-395/abi/OmnichainGovernanceExecutor_ABI.json delete mode 100644 simulations/vip-395/abi/OmnichainProposalSender.json rename simulations/{vip-389 => vip-399}/abi/ACMAggregator.json (100%) rename simulations/{vip-389 => vip-399}/abi/AccessControlManager_ABI.json (100%) rename simulations/{vip-389 => vip-399}/abi/OmnichainExecutorOwner_ABI.json (100%) rename simulations/{vip-389 => vip-399}/abi/OmnichainGovernanceExecutor_ABI.json (100%) rename simulations/{vip-389 => vip-399}/abi/OmnichainProposalSender.json (100%) rename simulations/{vip-395 => vip-399}/bscmainnet.ts (93%) rename simulations/{vip-389/bsctestnet.ts => vip-399/bsctestnet-opsepolia.ts} (91%) rename simulations/{vip-395/bsctestnet.ts => vip-399/bsctestnet-zksyncsepolia.ts} (91%) rename simulations/{vip-395 => vip-399}/opmainnet.ts (98%) rename simulations/{vip-389 => vip-399}/opsepolia.ts (98%) rename simulations/{vip-395 => vip-399}/zksyncmainnet.ts (98%) rename simulations/{vip-395 => vip-399}/zksyncsepolia.ts (96%) delete mode 100644 vips/vip-395/bscmainnet.ts create mode 100644 vips/vip-399/bscmainnet.ts rename vips/{vip-389/bsctestnet.ts => vip-399/bsctestnet-opsepolia.ts} (95%) rename vips/{vip-395/bsctestnet.ts => vip-399/bsctestnet-zksyncsepolia.ts} (95%) diff --git a/hardhat.config.zksync.ts b/hardhat.config.zksync.ts index 891d648f3..751ad7ed7 100644 --- a/hardhat.config.zksync.ts +++ b/hardhat.config.zksync.ts @@ -149,7 +149,7 @@ const config: HardhatUserConfig = { }, zksynctestnode: { url: process.env.ZKSYNC_ERA_LOCAL_TEST_NODE || "http://localhost:8011", - chainId: 324, // change it to 300 for zksyncsepolia + chainId: 300, // change it to 300 for zksyncsepolia accounts: DEPLOYER_PRIVATE_KEY ? [`0x${DEPLOYER_PRIVATE_KEY}`] : [], blockGasLimit: BLOCK_GAS_LIMIT_PER_NETWORK.zksyncsepolia, timeout: 2000000000, diff --git a/multisig/proposals/zksyncsepolia/vip-010/index.ts b/multisig/proposals/zksyncsepolia/vip-016/index.ts similarity index 90% rename from multisig/proposals/zksyncsepolia/vip-010/index.ts rename to multisig/proposals/zksyncsepolia/vip-016/index.ts index f0fea6d62..ea0e059fb 100644 --- a/multisig/proposals/zksyncsepolia/vip-010/index.ts +++ b/multisig/proposals/zksyncsepolia/vip-016/index.ts @@ -4,7 +4,7 @@ export const ZKSYNCSEPOLIA_ACM = "0xD07f543d47c3a8997D6079958308e981AC14CD01"; export const ZKSYNCSEPOLIA_NORMAL_TIMELOCK = "0x1730527a0f0930269313D77A317361b42971a67E"; const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; -export const vip010 = () => { +export const vip016 = () => { return makeProposal([ { target: ZKSYNCSEPOLIA_ACM, @@ -13,4 +13,4 @@ export const vip010 = () => { }, ]); }; -export default vip010; +export default vip016; diff --git a/multisig/simulations/zksyncsepolia/vip-010/abi/AccessControlManagerAbi.json b/multisig/simulations/zksyncsepolia/vip-016/abi/AccessControlManagerAbi.json similarity index 100% rename from multisig/simulations/zksyncsepolia/vip-010/abi/AccessControlManagerAbi.json rename to multisig/simulations/zksyncsepolia/vip-016/abi/AccessControlManagerAbi.json diff --git a/multisig/simulations/zksyncsepolia/vip-010/index.ts b/multisig/simulations/zksyncsepolia/vip-016/index.ts similarity index 86% rename from multisig/simulations/zksyncsepolia/vip-010/index.ts rename to multisig/simulations/zksyncsepolia/vip-016/index.ts index 11d0dee9b..e79b91809 100644 --- a/multisig/simulations/zksyncsepolia/vip-010/index.ts +++ b/multisig/simulations/zksyncsepolia/vip-016/index.ts @@ -3,7 +3,7 @@ import { Contract } from "ethers"; import { ethers } from "hardhat"; import { forking, pretendExecutingVip } from "src/vip-framework"; -import vip010, { ZKSYNCSEPOLIA_ACM, ZKSYNCSEPOLIA_NORMAL_TIMELOCK } from "../../../proposals/zksyncsepolia/vip-010"; +import vip016, { ZKSYNCSEPOLIA_ACM, ZKSYNCSEPOLIA_NORMAL_TIMELOCK } from "../../../proposals/zksyncsepolia/vip-016"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManagerAbi.json"; forking(3771669, async () => { @@ -21,7 +21,7 @@ forking(3771669, async () => { }); describe("Post-VIP behavior", async () => { before(async () => { - await pretendExecutingVip(await vip010()); + await pretendExecutingVip(await vip016()); }); it("Normal Timelock has default admin role", async () => { const hasRole = await acm.hasRole(defaultAdminRole, ZKSYNCSEPOLIA_NORMAL_TIMELOCK); diff --git a/simulations/vip-395/abi/ACMAggregator.json b/simulations/vip-395/abi/ACMAggregator.json deleted file mode 100644 index 6650a3f3c..000000000 --- a/simulations/vip-395/abi/ACMAggregator.json +++ /dev/null @@ -1,242 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "_acm", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [], - "name": "EmptyPermissions", - "type": "error" - }, - { - "inputs": [], - "name": "ZeroAddressNotAllowed", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "GrantPermissionsAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "GrantPermissionsExecuted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "RevokePermissionsAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "RevokePermissionsExecuted", - "type": "event" - }, - { - "inputs": [], - "name": "ACM", - "outputs": [ - { - "internalType": "contract IAccessControlManagerV8", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "contractAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "functionSig", - "type": "string" - }, - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "internalType": "struct ACMCommandsAggregator.Permission[]", - "name": "_permissions", - "type": "tuple[]" - } - ], - "name": "addGrantPermissions", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "contractAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "functionSig", - "type": "string" - }, - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "internalType": "struct ACMCommandsAggregator.Permission[]", - "name": "_permissions", - "type": "tuple[]" - } - ], - "name": "addRevokePermissions", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "executeGrantPermissions", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "index", - "type": "uint256" - } - ], - "name": "executeRevokePermissions", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "name": "grantPermissions", - "outputs": [ - { - "internalType": "address", - "name": "contractAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "functionSig", - "type": "string" - }, - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "name": "revokePermissions", - "outputs": [ - { - "internalType": "address", - "name": "contractAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "functionSig", - "type": "string" - }, - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-395/abi/AccessControlManager_ABI.json b/simulations/vip-395/abi/AccessControlManager_ABI.json deleted file mode 100644 index 2ef119947..000000000 --- a/simulations/vip-395/abi/AccessControlManager_ABI.json +++ /dev/null @@ -1,157 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, - { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "PermissionGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "contractAddress", "type": "address" }, - { "indexed": false, "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "PermissionRevoked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, - { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } - ], - "name": "RoleAdminChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } - ], - "name": "RoleGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } - ], - "name": "RoleRevoked", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_ADMIN_ROLE", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], - "name": "getRoleAdmin", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" }, - { "internalType": "address", "name": "accountToPermit", "type": "address" } - ], - "name": "giveCallPermission", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "grantRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "hasPermission", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "hasRole", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "isAllowedToCall", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "renounceRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" }, - { "internalType": "address", "name": "accountToRevoke", "type": "address" } - ], - "name": "revokeCallPermission", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "revokeRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], - "name": "supportsInterface", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/simulations/vip-395/abi/OmnichainExecutorOwner_ABI.json b/simulations/vip-395/abi/OmnichainExecutorOwner_ABI.json deleted file mode 100644 index f75834e6c..000000000 --- a/simulations/vip-395/abi/OmnichainExecutorOwner_ABI.json +++ /dev/null @@ -1,145 +0,0 @@ -[ - { - "inputs": [{ "internalType": "address", "name": "omnichainGovernanceExecutor_", "type": "address" }], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { "internalType": "address", "name": "sender", "type": "address" }, - { "internalType": "address", "name": "calledContract", "type": "address" }, - { "internalType": "string", "name": "methodSignature", "type": "string" } - ], - "name": "Unauthorized", - "type": "error" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "string", "name": "signature", "type": "string" }, - { "indexed": false, "internalType": "bool", "name": "active", "type": "bool" } - ], - "name": "FunctionRegistryChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "uint8", "name": "version", "type": "uint8" }], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": false, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferStarted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { "stateMutability": "nonpayable", "type": "fallback" }, - { - "inputs": [], - "name": "OMNICHAIN_GOVERNANCE_EXECUTOR", - "outputs": [{ "internalType": "contract IOmnichainGovernanceExecutor", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "contract IAccessControlManagerV8", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "bytes4", "name": "", "type": "bytes4" }], - "name": "functionRegistry", - "outputs": [{ "internalType": "string", "name": "", "type": "string" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "pendingOwner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "srcAddress_", "type": "bytes" } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner_", "type": "address" }], - "name": "transferBridgeOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "string[]", "name": "signatures_", "type": "string[]" }, - { "internalType": "bool[]", "name": "active_", "type": "bool[]" } - ], - "name": "upsertSignature", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/simulations/vip-395/abi/OmnichainGovernanceExecutor_ABI.json b/simulations/vip-395/abi/OmnichainGovernanceExecutor_ABI.json deleted file mode 100644 index b40c3cf44..000000000 --- a/simulations/vip-395/abi/OmnichainGovernanceExecutor_ABI.json +++ /dev/null @@ -1,539 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "address", "name": "endpoint_", "type": "address" }, - { "internalType": "address", "name": "guardian_", "type": "address" }, - { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "InvalidProposalId", "type": "error" }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "indexed": false, "internalType": "bytes", "name": "_payload", "type": "bytes" }, - { "indexed": false, "internalType": "bytes", "name": "_reason", "type": "bytes" } - ], - "name": "MessageFailed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldGuardian", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newGuardian", "type": "address" } - ], - "name": "NewGuardian", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "uint256", "name": "id", "type": "uint256" }], - "name": "ProposalCanceled", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "uint256", "name": "id", "type": "uint256" }], - "name": "ProposalExecuted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "id", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "eta", "type": "uint256" } - ], - "name": "ProposalQueued", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": false, "internalType": "address[]", "name": "targets", "type": "address[]" }, - { "indexed": false, "internalType": "uint256[]", "name": "values", "type": "uint256[]" }, - { "indexed": false, "internalType": "string[]", "name": "signatures", "type": "string[]" }, - { "indexed": false, "internalType": "bytes[]", "name": "calldatas", "type": "bytes[]" }, - { "indexed": false, "internalType": "uint8", "name": "proposalType", "type": "uint8" } - ], - "name": "ProposalReceived", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "srcChainId", "type": "uint16" }, - { "indexed": true, "internalType": "bytes", "name": "srcAddress", "type": "bytes" }, - { "indexed": false, "internalType": "uint64", "name": "nonce", "type": "uint64" }, - { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } - ], - "name": "ReceivePayloadFailed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "indexed": false, "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "indexed": false, "internalType": "bytes32", "name": "_payloadHash", "type": "bytes32" } - ], - "name": "RetryMessageSuccess", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } - ], - "name": "SetMaxDailyReceiveLimit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint16", "name": "_type", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "_minDstGas", "type": "uint256" } - ], - "name": "SetMinDstGas", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "precrime", "type": "address" }], - "name": "SetPrecrime", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "oldSrcChainId", "type": "uint16" }, - { "indexed": true, "internalType": "uint16", "name": "newSrcChainId", "type": "uint16" } - ], - "name": "SetSrcChainId", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "address", "name": "", "type": "address" }, - { "indexed": false, "internalType": "uint8", "name": "", "type": "uint8" } - ], - "name": "SetTimelockPendingAdmin", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_path", "type": "bytes" } - ], - "name": "SetTrustedRemote", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } - ], - "name": "SetTrustedRemoteAddress", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": false, "internalType": "uint8", "name": "routeType", "type": "uint8" }, - { "indexed": true, "internalType": "address", "name": "oldTimelock", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newTimelock", "type": "address" } - ], - "name": "TimelockAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_PAYLOAD_SIZE_LIMIT", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "contract ITimelock[]", "name": "timelocks_", "type": "address[]" }], - "name": "addTimelocks", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "proposalId_", "type": "uint256" }], - "name": "cancel", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "proposalId_", "type": "uint256" }], - "name": "execute", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "", "type": "uint16" }, - { "internalType": "bytes", "name": "", "type": "bytes" }, - { "internalType": "uint64", "name": "", "type": "uint64" } - ], - "name": "failedMessages", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } - ], - "name": "forceResumeReceive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_version", "type": "uint16" }, - { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, - { "internalType": "address", "name": "", "type": "address" }, - { "internalType": "uint256", "name": "_configType", "type": "uint256" } - ], - "name": "getConfig", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }], - "name": "getTrustedRemoteAddress", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "guardian", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" } - ], - "name": "isTrustedRemote", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "last24HourCommandsReceived", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "last24HourReceiveWindowStart", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "lastProposalReceived", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "lzEndpoint", - "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "internalType": "bytes", "name": "_payload", "type": "bytes" } - ], - "name": "lzReceive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "maxDailyReceiveLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "", "type": "uint16" }, - { "internalType": "uint16", "name": "", "type": "uint16" } - ], - "name": "minDstGasLookup", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_srcChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_srcAddress", "type": "bytes" }, - { "internalType": "uint64", "name": "_nonce", "type": "uint64" }, - { "internalType": "bytes", "name": "_payload", "type": "bytes" } - ], - "name": "nonblockingLzReceive", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "payloadSizeLimitLookup", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "precrime", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "proposalTimelocks", - "outputs": [{ "internalType": "contract ITimelock", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "proposals", - "outputs": [ - { "internalType": "uint256", "name": "id", "type": "uint256" }, - { "internalType": "uint256", "name": "eta", "type": "uint256" }, - { "internalType": "bool", "name": "canceled", "type": "bool" }, - { "internalType": "bool", "name": "executed", "type": "bool" }, - { "internalType": "uint8", "name": "proposalType", "type": "uint8" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "queued", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "srcAddress_", "type": "bytes" }, - { "internalType": "uint64", "name": "nonce_", "type": "uint64" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" } - ], - "name": "retryMessage", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_version", "type": "uint16" }, - { "internalType": "uint16", "name": "_chainId", "type": "uint16" }, - { "internalType": "uint256", "name": "_configType", "type": "uint256" }, - { "internalType": "bytes", "name": "_config", "type": "bytes" } - ], - "name": "setConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newGuardian", "type": "address" }], - "name": "setGuardian", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "limit_", "type": "uint256" }], - "name": "setMaxDailyReceiveLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "internalType": "uint16", "name": "_packetType", "type": "uint16" }, - { "internalType": "uint256", "name": "_minGas", "type": "uint256" } - ], - "name": "setMinDstGas", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_dstChainId", "type": "uint16" }, - { "internalType": "uint256", "name": "_size", "type": "uint256" } - ], - "name": "setPayloadSizeLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "_precrime", "type": "address" }], - "name": "setPrecrime", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], - "name": "setReceiveVersion", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "_version", "type": "uint16" }], - "name": "setSendVersion", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "srcChainId_", "type": "uint16" }], - "name": "setSrcChainId", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "pendingAdmin_", "type": "address" }, - { "internalType": "uint8", "name": "proposalType_", "type": "uint8" } - ], - "name": "setTimelockPendingAdmin", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_path", "type": "bytes" } - ], - "name": "setTrustedRemote", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "_remoteChainId", "type": "uint16" }, - { "internalType": "bytes", "name": "_remoteAddress", "type": "bytes" } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "srcChainId", - "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "proposalId_", "type": "uint256" }], - "name": "state", - "outputs": [{ "internalType": "enum OmnichainGovernanceExecutor.ProposalState", "name": "", "type": "uint8" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "trustedRemoteLookup", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } -] diff --git a/simulations/vip-395/abi/OmnichainProposalSender.json b/simulations/vip-395/abi/OmnichainProposalSender.json deleted file mode 100644 index 66fd4df02..000000000 --- a/simulations/vip-395/abi/OmnichainProposalSender.json +++ /dev/null @@ -1,314 +0,0 @@ -[ - { - "inputs": [ - { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, - { "internalType": "address", "name": "accessControlManager_", "type": "address" } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } - ], - "name": "ClearPayload", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } - ], - "name": "ExecuteRemoteProposal", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, - { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } - ], - "name": "FallbackWithdraw", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } - ], - "name": "NewAccessControlManager", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Paused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, - { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, - { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } - ], - "name": "SetMaxDailyLimit", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, - { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } - ], - "name": "SetTrustedRemoteAddress", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, - { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, - { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, - { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, - { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, - { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } - ], - "name": "StorePayload", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], - "name": "TrustedRemoteRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], - "name": "Unpaused", - "type": "event" - }, - { - "inputs": [], - "name": "LZ_ENDPOINT", - "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "accessControlManager", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourCommandsSent", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLast24HourWindowStart", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToLastProposalSentTimestamp", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "chainIdToMaxDailyLimit", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bool", "name": "useZro_", "type": "bool" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } - ], - "name": "estimateFees", - "outputs": [ - { "internalType": "uint256", "name": "", "type": "uint256" }, - { "internalType": "uint256", "name": "", "type": "uint256" } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, - { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } - ], - "name": "execute", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "to_", "type": "address" }, - { "internalType": "uint256", "name": "pId_", "type": "uint256" }, - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, - { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } - ], - "name": "fallbackWithdraw", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "version_", "type": "uint16" }, - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "configType_", "type": "uint256" } - ], - "name": "getConfig", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [{ "internalType": "address", "name": "", "type": "address" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [], - "name": "paused", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "proposalCount", - "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], - "name": "removeTrustedRemote", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, - { - "inputs": [ - { "internalType": "uint256", "name": "pId_", "type": "uint256" }, - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "payload_", "type": "bytes" }, - { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, - { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, - { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } - ], - "name": "retryExecute", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], - "name": "setAccessControlManager", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "version_", "type": "uint16" }, - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "configType_", "type": "uint256" }, - { "internalType": "bytes", "name": "config_", "type": "bytes" } - ], - "name": "setConfig", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, - { "internalType": "uint256", "name": "limit_", "type": "uint256" } - ], - "name": "setMaxDailyLimit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], - "name": "setSendVersion", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, - { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } - ], - "name": "setTrustedRemoteAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], - "name": "storedExecutionHashes", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], - "name": "trustedRemoteLookup", - "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], - "stateMutability": "view", - "type": "function" - }, - { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } -] diff --git a/simulations/vip-389/abi/ACMAggregator.json b/simulations/vip-399/abi/ACMAggregator.json similarity index 100% rename from simulations/vip-389/abi/ACMAggregator.json rename to simulations/vip-399/abi/ACMAggregator.json diff --git a/simulations/vip-389/abi/AccessControlManager_ABI.json b/simulations/vip-399/abi/AccessControlManager_ABI.json similarity index 100% rename from simulations/vip-389/abi/AccessControlManager_ABI.json rename to simulations/vip-399/abi/AccessControlManager_ABI.json diff --git a/simulations/vip-389/abi/OmnichainExecutorOwner_ABI.json b/simulations/vip-399/abi/OmnichainExecutorOwner_ABI.json similarity index 100% rename from simulations/vip-389/abi/OmnichainExecutorOwner_ABI.json rename to simulations/vip-399/abi/OmnichainExecutorOwner_ABI.json diff --git a/simulations/vip-389/abi/OmnichainGovernanceExecutor_ABI.json b/simulations/vip-399/abi/OmnichainGovernanceExecutor_ABI.json similarity index 100% rename from simulations/vip-389/abi/OmnichainGovernanceExecutor_ABI.json rename to simulations/vip-399/abi/OmnichainGovernanceExecutor_ABI.json diff --git a/simulations/vip-389/abi/OmnichainProposalSender.json b/simulations/vip-399/abi/OmnichainProposalSender.json similarity index 100% rename from simulations/vip-389/abi/OmnichainProposalSender.json rename to simulations/vip-399/abi/OmnichainProposalSender.json diff --git a/simulations/vip-395/bscmainnet.ts b/simulations/vip-399/bscmainnet.ts similarity index 93% rename from simulations/vip-395/bscmainnet.ts rename to simulations/vip-399/bscmainnet.ts index a6de6586b..b461483df 100644 --- a/simulations/vip-395/bscmainnet.ts +++ b/simulations/vip-399/bscmainnet.ts @@ -5,7 +5,7 @@ import { LzChainId } from "src/types"; import { expectEvents } from "src/utils"; import { forking, testVip } from "src/vip-framework"; -import vip395, { MAX_DAILY_LIMIT, OMNICHAIN_PROPOSAL_SENDER } from "../../vips/vip-395/bscmainnet"; +import vip399, { MAX_DAILY_LIMIT, OMNICHAIN_PROPOSAL_SENDER } from "../../vips/vip-399/bscmainnet"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; @@ -28,7 +28,7 @@ forking(43770901, async () => { }); }); - testVip("vip395 give permissions to timelock", await vip395(), { + testVip("vip399 give permissions to timelock", await vip399(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-389/bsctestnet.ts b/simulations/vip-399/bsctestnet-opsepolia.ts similarity index 91% rename from simulations/vip-389/bsctestnet.ts rename to simulations/vip-399/bsctestnet-opsepolia.ts index 2b40b3f10..7281bb55d 100644 --- a/simulations/vip-389/bsctestnet.ts +++ b/simulations/vip-399/bsctestnet-opsepolia.ts @@ -5,7 +5,7 @@ import { LzChainId } from "src/types"; import { expectEvents } from "src/utils"; import { forking, testVip } from "src/vip-framework"; -import vip389, { MAX_DAILY_LIMIT, OMNICHAIN_PROPOSAL_SENDER } from "../../vips/vip-389/bsctestnet"; +import vip399, { MAX_DAILY_LIMIT, OMNICHAIN_PROPOSAL_SENDER } from "../../vips/vip-399/bsctestnet-opsepolia"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; @@ -27,7 +27,7 @@ forking(44927774, async () => { }); }); - testVip("vip389 give permissions to timelock", await vip389(), { + testVip("vip399 give permissions to timelock", await vip399(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-395/bsctestnet.ts b/simulations/vip-399/bsctestnet-zksyncsepolia.ts similarity index 91% rename from simulations/vip-395/bsctestnet.ts rename to simulations/vip-399/bsctestnet-zksyncsepolia.ts index 0cf61ebb2..74584c260 100644 --- a/simulations/vip-395/bsctestnet.ts +++ b/simulations/vip-399/bsctestnet-zksyncsepolia.ts @@ -5,7 +5,7 @@ import { LzChainId } from "src/types"; import { expectEvents } from "src/utils"; import { forking, testVip } from "src/vip-framework"; -import vip365, { MAX_DAILY_LIMIT, OMNICHAIN_PROPOSAL_SENDER } from "../../vips/vip-395/bsctestnet"; +import vip399, { MAX_DAILY_LIMIT, OMNICHAIN_PROPOSAL_SENDER } from "../../vips/vip-399/bsctestnet-zksyncsepolia"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; @@ -27,7 +27,7 @@ forking(43836268, async () => { }); }); - testVip("vip365 give permissions to timelock", await vip365(), { + testVip("vip399 give permissions to timelock", await vip399(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-395/opmainnet.ts b/simulations/vip-399/opmainnet.ts similarity index 98% rename from simulations/vip-395/opmainnet.ts rename to simulations/vip-399/opmainnet.ts index 3965f4796..92aec8c93 100644 --- a/simulations/vip-395/opmainnet.ts +++ b/simulations/vip-399/opmainnet.ts @@ -7,12 +7,12 @@ import { expectEvents, getOmnichainProposalSenderAddress } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; import vip006 from "../../multisig/proposals/opmainnet/vip-006"; -import vip395, { +import vip399, { DEFAULT_ADMIN_ROLE, OP_MAINNET_ACM, OP_MAINNET_ACM_AGGREGATOR, OP_MAINNET_OMNICHAIN_EXECUTOR_OWNER, -} from "../../vips/vip-395/bscmainnet"; +} from "../../vips/vip-399/bscmainnet"; import ACMAggregator_ABI from "./abi/ACMAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_EXECUTOR_OWNER_ABI from "./abi/OmnichainExecutorOwner_ABI.json"; @@ -47,7 +47,7 @@ forking(127735654, async () => { }); }); - testForkedNetworkVipCommands("vip395 configures bridge", await vip395(), { + testForkedNetworkVipCommands("vip399 configures bridge", await vip399(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [39]); await expectEvents(txResponse, [ACMAggregator_ABI], ["GrantPermissionsExecuted"], [1]); diff --git a/simulations/vip-389/opsepolia.ts b/simulations/vip-399/opsepolia.ts similarity index 98% rename from simulations/vip-389/opsepolia.ts rename to simulations/vip-399/opsepolia.ts index 5eecb837a..1377b596b 100644 --- a/simulations/vip-389/opsepolia.ts +++ b/simulations/vip-399/opsepolia.ts @@ -7,12 +7,12 @@ import { expectEvents, getOmnichainProposalSenderAddress } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; import vip007 from "../../multisig/proposals/opsepolia/vip-007"; -import vip389, { +import vip399, { DEFAULT_ADMIN_ROLE, OPSEPOLIA_ACM, OPSEPOLIA_ACM_AGGREGATOR, OPSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, -} from "../../vips/vip-389/bsctestnet"; +} from "../../vips/vip-399/bsctestnet-opsepolia"; import ACMAggregator_ABI from "./abi/ACMAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_EXECUTOR_OWNER_ABI from "./abi/OmnichainExecutorOwner_ABI.json"; @@ -22,7 +22,7 @@ const { opsepolia } = NETWORK_ADDRESSES; const FAST_TRACK_TIMELOCK = "0xe0Fa35b6279dd802C382ae54c50C8B16deaC0885"; const CRITICAL_TIMELOCK = "0x45d2263c6E0dbF84eBffB1Ee0b80aC740607990B"; -forking(18889503, async () => { +forking(20247804, async () => { const provider = ethers.provider; let lastProposalReceived: BigNumber; let executor: Contract; @@ -47,7 +47,7 @@ forking(18889503, async () => { }); }); - testForkedNetworkVipCommands("vip389 configures bridge", await vip389(), { + testForkedNetworkVipCommands("vip399 configures bridge", await vip399(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [39]); await expectEvents(txResponse, [ACMAggregator_ABI], ["GrantPermissionsExecuted"], [1]); diff --git a/simulations/vip-395/zksyncmainnet.ts b/simulations/vip-399/zksyncmainnet.ts similarity index 98% rename from simulations/vip-395/zksyncmainnet.ts rename to simulations/vip-399/zksyncmainnet.ts index 117672d8e..2bde12961 100644 --- a/simulations/vip-395/zksyncmainnet.ts +++ b/simulations/vip-399/zksyncmainnet.ts @@ -7,12 +7,12 @@ import { expectEvents, getOmnichainProposalSenderAddress } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; import vip016 from "../../multisig/proposals/zksyncmainnet/vip-016"; -import vip395, { +import vip399, { DEFAULT_ADMIN_ROLE, ZKSYNCMAINNET_ACM, ZKSYNCMAINNET_ACM_AGGREGATOR, ZKSYNCMAINNET_OMNICHAIN_EXECUTOR_OWNER, -} from "../../vips/vip-395/bscmainnet"; +} from "../../vips/vip-399/bscmainnet"; import ACMAggregator_ABI from "./abi/ACMAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_EXECUTOR_OWNER_ABI from "./abi/OmnichainExecutorOwner_ABI.json"; @@ -47,7 +47,7 @@ forking(48280698, async () => { }); }); - testForkedNetworkVipCommands("vip395 configures bridge", await vip395(), { + testForkedNetworkVipCommands("vip399 configures bridge", await vip399(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [39]); await expectEvents(txResponse, [ACMAggregator_ABI], ["GrantPermissionsExecuted"], [1]); diff --git a/simulations/vip-395/zksyncsepolia.ts b/simulations/vip-399/zksyncsepolia.ts similarity index 96% rename from simulations/vip-395/zksyncsepolia.ts rename to simulations/vip-399/zksyncsepolia.ts index eb0678b01..4e8dac6da 100644 --- a/simulations/vip-395/zksyncsepolia.ts +++ b/simulations/vip-399/zksyncsepolia.ts @@ -6,13 +6,13 @@ import { LzChainId } from "src/types"; import { expectEvents, getOmnichainProposalSenderAddress } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; -import vip010 from "../../multisig/proposals/zksyncsepolia/vip-010"; -import vip365, { +import vip016 from "../../multisig/proposals/zksyncsepolia/vip-016"; +import vip399, { DEFAULT_ADMIN_ROLE, ZKSYNCSEPOLIA_ACM, ZKSYNCSEPOLIA_ACM_AGGREGATOR, ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, -} from "../../vips/vip-395/bsctestnet"; +} from "../../vips/vip-399/bsctestnet-zksyncsepolia"; import ACMAggregator_ABI from "./abi/ACMAggregator.json"; import ACCESS_CONTROL_MANAGER_ABI from "./abi/AccessControlManager_ABI.json"; import OMNICHAIN_EXECUTOR_OWNER_ABI from "./abi/OmnichainExecutorOwner_ABI.json"; @@ -36,7 +36,7 @@ forking(3884819, async () => { ); executorOwner = new ethers.Contract(ZKSYNCSEPOLIA_OMNICHAIN_EXECUTOR_OWNER, OMNICHAIN_EXECUTOR_OWNER_ABI, provider); lastProposalReceived = await executor.lastProposalReceived(); - await pretendExecutingVip(await vip010()); + await pretendExecutingVip(await vip016()); }); describe("Pre-VIP behaviour", async () => { @@ -47,7 +47,7 @@ forking(3884819, async () => { }); }); - testForkedNetworkVipCommands("vip365 configures bridge", await vip365(), { + testForkedNetworkVipCommands("vip399 configures bridge", await vip399(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [ACCESS_CONTROL_MANAGER_ABI], ["PermissionGranted"], [39]); await expectEvents(txResponse, [ACMAggregator_ABI], ["GrantPermissionsExecuted"], [1]); diff --git a/vips/vip-395/bscmainnet.ts b/vips/vip-395/bscmainnet.ts deleted file mode 100644 index fde05b82a..000000000 --- a/vips/vip-395/bscmainnet.ts +++ /dev/null @@ -1,112 +0,0 @@ -import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { LzChainId, ProposalType } from "src/types"; -import { makeProposal } from "src/utils"; - -const { zksyncmainnet, opmainnet } = NETWORK_ADDRESSES; -export const OMNICHAIN_PROPOSAL_SENDER = "0x36a69dE601381be7b0DcAc5D5dD058825505F8f6"; -export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; - -export const ZKSYNCMAINNET_OMNICHAIN_EXECUTOR_OWNER = "0xdfaed3E5d9707629Ed5c225b4fB980c064286771"; -export const ZKSYNCMAINNET_ACM = "0x526159A92A82afE5327d37Ef446b68FD9a5cA914"; -export const ZKSYNCMAINNET_ACM_AGGREGATOR = "0x88B1452e512c8fcf83889DdCfe54dF37D561Db82"; - -export const OP_MAINNET_OMNICHAIN_EXECUTOR_OWNER = "0xe6d9Eb3A07a1dc4496fc71417D7A7b9d5666BaA3"; -export const OP_MAINNET_ACM = "0xD71b1F33f6B0259683f11174EE4Ddc2bb9cE4eD6"; -export const OP_MAINNET_ACM_AGGREGATOR = "0xbbEBaF646e7a3E4064a899e68565B1b439eFdf70"; - -export const MAX_DAILY_LIMIT = 100; - -const vip395 = () => { - const meta = { - version: "v2", - title: "VIP-395 Enable Multichain Governance on zksync mainnet", - description: `### Summary`, - forDescription: "I agree that Venus Protocol should proceed with this proposal", - againstDescription: "I do not think that Venus Protocol should proceed with this proposal", - abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", - }; - return makeProposal( - [ - // Omnichain sender configuration for zksync - { - target: OMNICHAIN_PROPOSAL_SENDER, - signature: "setMaxDailyLimit(uint16,uint256)", - params: [LzChainId.zksyncmainnet, MAX_DAILY_LIMIT], - }, - { - target: OMNICHAIN_PROPOSAL_SENDER, - signature: "setTrustedRemoteAddress(uint16,bytes)", - params: [LzChainId.zksyncmainnet, zksyncmainnet.OMNICHAIN_GOVERNANCE_EXECUTOR], - }, - - // Remote commands for zksync - - { - target: ZKSYNCMAINNET_OMNICHAIN_EXECUTOR_OWNER, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.zksyncmainnet, - }, - { - target: ZKSYNCMAINNET_ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, ZKSYNCMAINNET_ACM_AGGREGATOR], - dstChainId: LzChainId.zksyncmainnet, - }, - { - target: ZKSYNCMAINNET_ACM_AGGREGATOR, - signature: "executeGrantPermissions(uint256)", - params: [0], - dstChainId: LzChainId.zksyncmainnet, - }, - { - target: ZKSYNCMAINNET_ACM, - signature: "revokeRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, ZKSYNCMAINNET_ACM_AGGREGATOR], - dstChainId: LzChainId.zksyncmainnet, - }, - - // Omnichain sender configuration for op mainnet - { - target: OMNICHAIN_PROPOSAL_SENDER, - signature: "setMaxDailyLimit(uint16,uint256)", - params: [LzChainId.opmainnet, MAX_DAILY_LIMIT], - }, - { - target: OMNICHAIN_PROPOSAL_SENDER, - signature: "setTrustedRemoteAddress(uint16,bytes)", - params: [LzChainId.opmainnet, opmainnet.OMNICHAIN_GOVERNANCE_EXECUTOR], - }, - - // Remote commands for op mainnet - - { - target: OP_MAINNET_OMNICHAIN_EXECUTOR_OWNER, - signature: "acceptOwnership()", - params: [], - dstChainId: LzChainId.opmainnet, - }, - { - target: OP_MAINNET_ACM, - signature: "grantRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, OP_MAINNET_ACM_AGGREGATOR], - dstChainId: LzChainId.opmainnet, - }, - { - target: OP_MAINNET_ACM_AGGREGATOR, - signature: "executeGrantPermissions(uint256)", - params: [0], - dstChainId: LzChainId.opmainnet, - }, - { - target: OP_MAINNET_ACM, - signature: "revokeRole(bytes32,address)", - params: [DEFAULT_ADMIN_ROLE, OP_MAINNET_ACM_AGGREGATOR], - dstChainId: LzChainId.opmainnet, - }, - ], - meta, - ProposalType.REGULAR, - ); -}; -export default vip395; diff --git a/vips/vip-399/bscmainnet.ts b/vips/vip-399/bscmainnet.ts new file mode 100644 index 000000000..291206c25 --- /dev/null +++ b/vips/vip-399/bscmainnet.ts @@ -0,0 +1,198 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +const { zksyncmainnet, opmainnet } = NETWORK_ADDRESSES; +export const OMNICHAIN_PROPOSAL_SENDER = "0x36a69dE601381be7b0DcAc5D5dD058825505F8f6"; +export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000000000000000000000000"; + +export const ZKSYNCMAINNET_OMNICHAIN_EXECUTOR_OWNER = "0xdfaed3E5d9707629Ed5c225b4fB980c064286771"; +export const ZKSYNCMAINNET_ACM = "0x526159A92A82afE5327d37Ef446b68FD9a5cA914"; +export const ZKSYNCMAINNET_ACM_AGGREGATOR = "0x88B1452e512c8fcf83889DdCfe54dF37D561Db82"; + +export const OP_MAINNET_OMNICHAIN_EXECUTOR_OWNER = "0xe6d9Eb3A07a1dc4496fc71417D7A7b9d5666BaA3"; +export const OP_MAINNET_ACM = "0xD71b1F33f6B0259683f11174EE4Ddc2bb9cE4eD6"; +export const OP_MAINNET_ACM_AGGREGATOR = "0xbbEBaF646e7a3E4064a899e68565B1b439eFdf70"; + +export const MAX_DAILY_LIMIT = 100; + +const vip399 = () => { + const meta = { + version: "v2", + title: "VIP-399 Enable Omnichain Governance on zkSync and Optimism (1/2)", + description: `#### Summary + +If passed, following the Community proposal “[Venus Upgrade - Omnichain Money Markets](https://community.venus.io/t/venus-upgrade-omnichain-money-markets/3027/9)” and [the associated snapshot](https://snapshot.org/#/venus-xvs.eth/proposal/0x62440d98cb7513d4873662203b7a27f9441880afa73105c55a733005de7ac9a1), this VIP enables the Omnichain Governance system on the Venus protocol, for zkSync Era and Optimism. Omnichain Governance will allow the Venus Community to propose VIP’s on BNB Chain including commands to be executed on the mentioned networks. + +#### Description + +[VIP-330](https://app.venus.io/#/governance/proposal/394?chainId=56) executed similar commands for Ethereum, Arbitrum one and opBNB. Review that VIP for a detailed explanation. + +#### Commands on the this VIP + +This VIP will grant permissions to Normal, Fast-track and Critical timelocks on BNB chain to create remote VIP’s. It also performs the necessary configuration of OmnichainProposalSender on BNB Chain and OmnichainProposalExecutor on zkSync Era and Optimism (set the trustworthiness relationships, configure limits, accept ownerships). + +Moreover, this VIP will authorise the Guardian wallets on [zkSync Era](https://explorer.zksync.io/address/0x751Aa759cfBB6CE71A43b48e40e1cCcFC66Ba4aa) and [Optimism](https://optimistic.etherscan.io/address/0x2e94dd14E81999CdBF5deDE31938beD7308354b3) to execute the privilege commands on the OmnichainExecutorOwner contracts. This is a safety measure, to guarantee it will be possible to execute remote VIP’s. These permissions will be removed in the future. These authorizations will be granted using the [ACMCommandsAggregator](https://github.com/VenusProtocol/governance-contracts/blob/develop/contracts/Utils/ACMCommandsAggregator.sol) contract, previously used in [VIP-391](https://app.venus.io/#/governance/proposal/391?chainId=56). + +The Default Role in the AccessControlManager contract will be assigned to the Normal Timelock contracts on zkSync Era and Optimism with multisig transactions ([this](https://app.safe.global/transactions/tx?safe=zksync:0x751Aa759cfBB6CE71A43b48e40e1cCcFC66Ba4aa&id=multisig_0x751Aa759cfBB6CE71A43b48e40e1cCcFC66Ba4aa_0x4959666396bbe77d6b756d522bd749788f5595834bbc159c8df04158f24ad77b) and [this](https://app.safe.global/transactions/tx?safe=oeth:0x2e94dd14E81999CdBF5deDE31938beD7308354b3&id=multisig_0x2e94dd14E81999CdBF5deDE31938beD7308354b3_0x1cbbe6e257d58ca0ff94d5017cc68d7a6cffbba2482bf61da1179a6768a60d26)), that will be executed only if this VIP passes. Otherwise, they will be rejected. + +#### Next steps + +New VIP’s will be proposed soon to complete the configuration + +- Authorise Normal, Fast-track and Critical timelocks to execute the different privilege commands on the destination networks +- Reduce the permissions granted to the Guardian wallets on the destination networks (nowadays, the Guardian wallets can execute any privilege command on those networks) +- Transfer the ownership of the contracts, from the Guardian wallets to the Normal timelocks on each destination network (including Ethereum, Arbitrum one and opBNB) +- Synchronise the voting power. With this feature, the XVS staked on the different networks will be taken into account during the VIP’s votes on BNB Chain + +#### Security and additional considerations + +We applied the following security procedures for this upgrade: + +- **Audits**: [OpenZeppelin](https://www.openzeppelin.com/), [Quantstamp](https://quantstamp.com/), [Cantina](https://cantina.xyz/) and [Certik](https://www.certik.com/) have audited the Omnichain Governance contracts. +- **VIP execution simulation**: in a simulation environment, validating the expected configuration on every network +- **Deployment on testnet**: the same contracts have been deployed to the supported testnets, and used in the Venus Protocol testnet deployment + +#### Audit reports + +- [Openzepplin audit report - 2024/01/19](https://github.com/VenusProtocol/governance-contracts/blob/feat/ven-1918/audits/084_multichainGovernance_openzeppelin_20240119.pdf) +- [Quantstamp audit report - 2024/04/29](https://github.com/VenusProtocol/governance-contracts/blob/feat/ven-1918/audits/106_multichainGovernance_quantstamp_20240429.pdf) +- [Cantina audit report - 2024/04/25](https://github.com/VenusProtocol/governance-contracts/blob/feat/ven-1918/audits/105_multichainGovernance_cantina_20240425.pdf) +- [Certik audit report - 2024/02/26](https://github.com/VenusProtocol/governance-contracts/blob/feat/ven-1918/audits/085_multichainGovernance_certik_20240226.pdf) + +#### Deployed contracts + +Mainnet: + +- BNB Chain: + - OmniChainProposalSender: [0x36a69dE601381be7b0DcAc5D5dD058825505F8f6](https://bscscan.com/address/0x36a69dE601381be7b0DcAc5D5dD058825505F8f6) +- zkSync Era: + - Normal Timelock: [0x093565Bc20AA326F4209eBaF3a26089272627613](https://explorer.zksync.io/address/0x093565Bc20AA326F4209eBaF3a26089272627613) + - FastTrack Timelock: [0x32f71c95BC8F9d996f89c642f1a84d06B2484AE9](https://explorer.zksync.io/address/0x32f71c95BC8F9d996f89c642f1a84d06B2484AE9) + - Critical Timelock: [0xbfbc79D4198963e4a66270F3EfB1fdA0F382E49c](https://explorer.zksync.io/address/0xbfbc79D4198963e4a66270F3EfB1fdA0F382E49c) + - Omnichain Governance Executor: [0xA1b56f19CA5E5b15EF29d38238930Ce9f0235312](https://explorer.zksync.io/address/0xA1b56f19CA5E5b15EF29d38238930Ce9f0235312) + - Omnichain Executor Owner Proxy: [0xdfaed3E5d9707629Ed5c225b4fB980c064286771](https://explorer.zksync.io/address/0xdfaed3E5d9707629Ed5c225b4fB980c064286771) + - ACMCommandsAggregator: [0x88B1452e512c8fcf83889DdCfe54dF37D561Db82](https://explorer.zksync.io/address/0x88B1452e512c8fcf83889DdCfe54dF37D561Db82) +- Optimism: + - Normal Timelock: [0x0C6f1E6B4fDa846f63A0d5a8a73EB811E0e0C04b](https://optimistic.etherscan.io/address/0x0C6f1E6B4fDa846f63A0d5a8a73EB811E0e0C04b) + - FastTrack Timelock: [0x508bD9C31E8d6760De04c70fe6c2b24B3cDea7E7](https://optimistic.etherscan.io/address/0x508bD9C31E8d6760De04c70fe6c2b24B3cDea7E7) + - Critical Timelock: [0xB82479bc345CAA7326D7d21306972033226fC185](https://optimistic.etherscan.io/address/0xB82479bc345CAA7326D7d21306972033226fC185) + - Omnichain Governance Executor: [0x09b11b1CAdC08E239970A8993783f0f8EeC60ABf](https://optimistic.etherscan.io/address/0x09b11b1CAdC08E239970A8993783f0f8EeC60ABf) + - Omnichain Executor Owner Proxy: [0xe6d9Eb3A07a1dc4496fc71417D7A7b9d5666BaA3](https://optimistic.etherscan.io/address/0xe6d9Eb3A07a1dc4496fc71417D7A7b9d5666BaA3) + - ACMCommandsAggregator: [0xbbEBaF646e7a3E4064a899e68565B1b439eFdf70](https://optimistic.etherscan.io/address/0xbbEBaF646e7a3E4064a899e68565B1b439eFdf70) + +Testnets: + +- BNB Chain: + - Omnichain Proposal Sender: [0xCfD34AEB46b1CB4779c945854d405E91D27A1899](https://testnet.bscscan.com/address/0xCfD34AEB46b1CB4779c945854d405E91D27A1899) +- zkSync Era sepolia: + - Normal Timelock: [0xdDe31d7eEEAD7Cf9790F833C4FF4c6e61404402a](https://sepolia-optimism.etherscan.io/address/0xdDe31d7eEEAD7Cf9790F833C4FF4c6e61404402a) + - FastTrack Timelock: [0xe0Fa35b6279dd802C382ae54c50C8B16deaC0885](https://sepolia-optimism.etherscan.io/address/0xe0Fa35b6279dd802C382ae54c50C8B16deaC0885) + - Critical Timelock: [0x45d2263c6E0dbF84eBffB1Ee0b80aC740607990B](https://sepolia-optimism.etherscan.io/address/0x45d2263c6E0dbF84eBffB1Ee0b80aC740607990B) + - Omnichain Governance Executor: [0xC7D6D33adcdBfccD416C3aAB1878360ea8b79ac6](https://sepolia-optimism.etherscan.io/address/0xC7D6D33adcdBfccD416C3aAB1878360ea8b79ac6) + - Omnichain Executor Owner Proxy: [0xE92E31df479BC1031B866063F65CF71B6bAC4FC6](https://sepolia-optimism.etherscan.io/address/0xE92E31df479BC1031B866063F65CF71B6bAC4FC6) + - ACMCommandsAggregator: [0xEEeF13364fD22b8eA6932A9ed337e2638f8E0eD6](https://sepolia-optimism.etherscan.io/address/0xEEeF13364fD22b8eA6932A9ed337e2638f8E0eD6) +- Optimism sepolia: + - Normal Timelock: [0x1730527a0f0930269313D77A317361b42971a67E](https://sepolia.explorer.zksync.io/address/0x1730527a0f0930269313D77A317361b42971a67E) + - FastTrack Timelock: [0xb055e028b27d53a455a6c040a6952e44E9E615c4](https://sepolia.explorer.zksync.io/address/0xb055e028b27d53a455a6c040a6952e44E9E615c4) + - Critical Timelock: [0x0E6138bE0FA1915efC73670a20A10EFd720a6Cc8](https://sepolia.explorer.zksync.io/address/0x0E6138bE0FA1915efC73670a20A10EFd720a6Cc8) + - Omnichain Governance Executor: [0x83F79CfbaEee738173c0dfd866796743F4E25C9e](https://sepolia.explorer.zksync.io/address/0x83F79CfbaEee738173c0dfd866796743F4E25C9e) + - Omnichain Executor Owner Proxy: [0xa34607D58146FA02aF5f920f29C3D916acAb0bC5](https://sepolia.explorer.zksync.io/address/0xa34607D58146FA02aF5f920f29C3D916acAb0bC5) + - ACMCommandsAggregator: [0x920Bb18c4bd4D7bc41Bf39933BCAa3D078641502](https://sepolia.explorer.zksync.io/address/0x920Bb18c4bd4D7bc41Bf39933BCAa3D078641502) + +#### References + +- [VIP simulation](https://github.com/VenusProtocol/vips/pull/384) +- [Code of Omnichain Governance](https://github.com/VenusProtocol/governance-contracts/pull/21) +- [Documentation - Technical article with more details of the Omnichain Governance feature](https://docs-v4.venus.io/technical-reference/reference-technical-articles/multichain-governance) +- [Transaction on zkSync Era pre-loading the permissions to be granted in this VIP](https://explorer.zksync.io/tx/0xdad5433e73ea0488ea1ca96c96e6617f97b57ce78b1a681361393a8d11b283eb) +- [Transaction on Optimism pre-loading the permissions to be granted in this VIP](https://optimistic.etherscan.io/tx/0xb05e1dc0cf6ed5d5b59dbab32aa870f8147e0c0d0bcf6cab138aa1abaea0c772)`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + // Omnichain sender configuration for zksync + { + target: OMNICHAIN_PROPOSAL_SENDER, + signature: "setMaxDailyLimit(uint16,uint256)", + params: [LzChainId.zksyncmainnet, MAX_DAILY_LIMIT], + }, + { + target: OMNICHAIN_PROPOSAL_SENDER, + signature: "setTrustedRemoteAddress(uint16,bytes)", + params: [LzChainId.zksyncmainnet, zksyncmainnet.OMNICHAIN_GOVERNANCE_EXECUTOR], + }, + + // Remote commands for zksync + + { + target: ZKSYNCMAINNET_OMNICHAIN_EXECUTOR_OWNER, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.zksyncmainnet, + }, + { + target: ZKSYNCMAINNET_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ZKSYNCMAINNET_ACM_AGGREGATOR], + dstChainId: LzChainId.zksyncmainnet, + }, + { + target: ZKSYNCMAINNET_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.zksyncmainnet, + }, + { + target: ZKSYNCMAINNET_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, ZKSYNCMAINNET_ACM_AGGREGATOR], + dstChainId: LzChainId.zksyncmainnet, + }, + + // Omnichain sender configuration for op mainnet + { + target: OMNICHAIN_PROPOSAL_SENDER, + signature: "setMaxDailyLimit(uint16,uint256)", + params: [LzChainId.opmainnet, MAX_DAILY_LIMIT], + }, + { + target: OMNICHAIN_PROPOSAL_SENDER, + signature: "setTrustedRemoteAddress(uint16,bytes)", + params: [LzChainId.opmainnet, opmainnet.OMNICHAIN_GOVERNANCE_EXECUTOR], + }, + + // Remote commands for op mainnet + + { + target: OP_MAINNET_OMNICHAIN_EXECUTOR_OWNER, + signature: "acceptOwnership()", + params: [], + dstChainId: LzChainId.opmainnet, + }, + { + target: OP_MAINNET_ACM, + signature: "grantRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OP_MAINNET_ACM_AGGREGATOR], + dstChainId: LzChainId.opmainnet, + }, + { + target: OP_MAINNET_ACM_AGGREGATOR, + signature: "executeGrantPermissions(uint256)", + params: [0], + dstChainId: LzChainId.opmainnet, + }, + { + target: OP_MAINNET_ACM, + signature: "revokeRole(bytes32,address)", + params: [DEFAULT_ADMIN_ROLE, OP_MAINNET_ACM_AGGREGATOR], + dstChainId: LzChainId.opmainnet, + }, + ], + meta, + ProposalType.REGULAR, + ); +}; +export default vip399; diff --git a/vips/vip-389/bsctestnet.ts b/vips/vip-399/bsctestnet-opsepolia.ts similarity index 95% rename from vips/vip-389/bsctestnet.ts rename to vips/vip-399/bsctestnet-opsepolia.ts index c906452a2..f443f406f 100644 --- a/vips/vip-389/bsctestnet.ts +++ b/vips/vip-399/bsctestnet-opsepolia.ts @@ -11,10 +11,10 @@ export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000 export const OPSEPOLIA_ACM_AGGREGATOR = "0xEEeF13364fD22b8eA6932A9ed337e2638f8E0eD6"; export const MAX_DAILY_LIMIT = 100; -const vip389 = () => { +const vip399 = () => { const meta = { version: "v2", - title: "VIP-389 Enable Multichain Governance on op sepolia", + title: "VIP-399 Enable Multichain Governance on op sepolia", description: `### Summary`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", @@ -61,4 +61,4 @@ const vip389 = () => { ProposalType.REGULAR, ); }; -export default vip389; +export default vip399; diff --git a/vips/vip-395/bsctestnet.ts b/vips/vip-399/bsctestnet-zksyncsepolia.ts similarity index 95% rename from vips/vip-395/bsctestnet.ts rename to vips/vip-399/bsctestnet-zksyncsepolia.ts index f13e10157..5c2ca8cc1 100644 --- a/vips/vip-395/bsctestnet.ts +++ b/vips/vip-399/bsctestnet-zksyncsepolia.ts @@ -11,10 +11,10 @@ export const DEFAULT_ADMIN_ROLE = "0x0000000000000000000000000000000000000000000 export const ZKSYNCSEPOLIA_ACM_AGGREGATOR = "0x920Bb18c4bd4D7bc41Bf39933BCAa3D078641502"; export const MAX_DAILY_LIMIT = 100; -const vip365 = () => { +const vip399 = () => { const meta = { version: "v2", - title: "VIP-365 Enable Multichain Governance on zksync sepolia", + title: "VIP-399 Enable Multichain Governance on zksync sepolia", description: `### Summary`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", @@ -61,4 +61,4 @@ const vip365 = () => { ProposalType.REGULAR, ); }; -export default vip365; +export default vip399; From e708bb893ff30a949cdc8013f9d9bd7464ebf705 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Mon, 25 Nov 2024 13:58:55 +0100 Subject: [PATCH 160/178] chore: simplify the definition of remote network type --- src/types.ts | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/src/types.ts b/src/types.ts index 584960031..dd5d08ce7 100644 --- a/src/types.ts +++ b/src/types.ts @@ -12,17 +12,7 @@ export type SUPPORTED_NETWORKS = | "opsepolia" | "opmainnet"; -export type REMOTE_NETWORKS = - | "sepolia" - | "ethereum" - | "opbnbtestnet" - | "opbnbmainnet" - | "arbitrumsepolia" - | "arbitrumone" - | "zksyncsepolia" - | "zksyncmainnet" - | "opsepolia" - | "opmainnet"; +export type REMOTE_NETWORKS = Exclude; export const REMOTE_TESTNET_NETWORKS = ["sepolia", "opbnbtestnet", "arbitrumsepolia", "zksyncsepolia", "opsepolia"]; export const REMOTE_MAINNET_NETWORKS = ["ethereum", "opbnbmainnet", "arbitrumone", "zksyncmainnet", "opmainnet"]; From 15ad12dd51c48a0499e77f474284031e02037019 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Mon, 25 Nov 2024 21:37:18 +0530 Subject: [PATCH 161/178] feat: add missed access right to guardian --- multisig/proposals/arbitrumone/vip-018/index.ts | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/multisig/proposals/arbitrumone/vip-018/index.ts b/multisig/proposals/arbitrumone/vip-018/index.ts index bd22a85b9..d0b05ca1e 100644 --- a/multisig/proposals/arbitrumone/vip-018/index.ts +++ b/multisig/proposals/arbitrumone/vip-018/index.ts @@ -1,12 +1,15 @@ import { makeProposal } from "src/utils"; -import { CONVERTER_NETWORK, PLP, USDC, USDT, WBTC, WETH, XVS_VAULT_TREASURY } from "./addresses"; +import { CONVERTER_NETWORK, PLP, USDC, USDT, WBTC, WETH, XVS_VAULT_TREASURY, ACM } from "./addresses"; import { acceptOwnershipCommandsAllConverters, callPermissionCommandsAllConverter, setConverterNetworkCommands, } from "./commands"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; + +const { arbitrumone } = NETWORK_ADDRESSES; const vip018 = () => { return makeProposal([ { @@ -25,6 +28,11 @@ const vip018 = () => { signature: "acceptOwnership()", params: [], }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [arbitrumone.REDSTONE_ORACLE, "setTokenConfig(TokenConfig)", arbitrumone.GUARDIAN], + }, ...callPermissionCommandsAllConverter, ...setConverterNetworkCommands, ]); From d83a7e6868577e29b79b27ef9a7b4a712aeaf6b4 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Mon, 25 Nov 2024 21:37:37 +0530 Subject: [PATCH 162/178] test: prime claim --- simulations/vip-398/arbitrumone.ts | 27 ++++----------------------- 1 file changed, 4 insertions(+), 23 deletions(-) diff --git a/simulations/vip-398/arbitrumone.ts b/simulations/vip-398/arbitrumone.ts index c70e0a561..1aaa6a2f6 100644 --- a/simulations/vip-398/arbitrumone.ts +++ b/simulations/vip-398/arbitrumone.ts @@ -13,8 +13,6 @@ import { USDC_PRIME_CONVERTER, USDT, USDT_PRIME_CONVERTER, - WBTC_PRIME_CONVERTER, - WETH_PRIME_CONVERTER, XVS, XVS_VAULT_CONVERTER, XVS_VAULT_TREASURY, @@ -47,7 +45,7 @@ import PROTOCOL_SHARE_RESERVE_ABI from "./abi/ProtocolShareReserve.json"; const { arbitrumone } = NETWORK_ADDRESSES; const USDT_HOLDER = "0x3931dAb967C3E2dbb492FE12460a66d0fe4cC857"; const USDC_HOLDER = "0x47c031236e19d024b42f8AE6780E44A573170703"; -const XVS_USER = "0xf805cEf7E0125811d0E64c597A66aE55cFc54143"; +const XVS_USER = "0xC469eCb73159b88957965758002bBE1807532814"; const ARBITRUM_PROTOCOL_SHARE_RESERVE_PROXY = "0xF9263eaF7eB50815194f26aCcAB6765820B13D41"; @@ -182,7 +180,6 @@ forking(278099102, async () => { await usdc.connect(usdcHolder).transfer(user1Address, amount); await setMaxStalePeriod(resilientOracle, usdt); await setMaxStalePeriod(resilientOracle, usdc); - await setMaxStalePeriod(resilientOracle, xvs); }); it("PSR should have correct distribution configs", async () => { @@ -300,25 +297,9 @@ forking(278099102, async () => { }); it("claim prime token", async () => { - await network.provider.send("hardhat_setCode", [XVS_USER, "0x"]); - const xvsUserSigner = await initMainnetUser(XVS_USER, parseUnits("1")); - - await expect(prime.connect(xvsUserSigner).claim()).to.be.revertedWithCustomError(prime, "Unauthorized"); - - let interestAccrued = await prime.callStatic.getInterestAccrued(USDT_PRIME_CONVERTER, XVS_USER); - expect(interestAccrued).to.be.equal(0); - - interestAccrued = await prime.callStatic.getInterestAccrued(USDC_PRIME_CONVERTER, XVS_USER); - expect(interestAccrued).to.be.equal(0); - - interestAccrued = await prime.callStatic.getInterestAccrued(WBTC_PRIME_CONVERTER, XVS_USER); - expect(interestAccrued).to.be.equal(0); - - interestAccrued = await prime.callStatic.getInterestAccrued(WETH_PRIME_CONVERTER, XVS_USER); - expect(interestAccrued).to.be.equal(0); - - interestAccrued = await prime.callStatic.getInterestAccrued(XVS_VAULT_CONVERTER, XVS_USER); - expect(interestAccrued).to.be.equal(0); + const xvsUserSigner = await initMainnetUser(XVS_USER, parseUnits("10")); + await setMaxStalePeriod(resilientOracle, xvs); + await expect(prime.connect(xvsUserSigner).claim()).not.to.be.reverted; }); }); }); From c3441dc8d11b970e9a3809ed912da6a7a8638ddf Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Mon, 25 Nov 2024 21:38:07 +0530 Subject: [PATCH 163/178] chore: vscode setting --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 9abab3eda..ae6f2fae7 100644 --- a/.gitignore +++ b/.gitignore @@ -36,3 +36,4 @@ gnosisTXBuilder.json **/.DS_Store .cache +.vscode/settings.json From 072925d34620484d9a9f7fec63e7401d7ba1fca2 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Mon, 25 Nov 2024 22:06:41 +0530 Subject: [PATCH 164/178] update: setMaxStalePeriod support for arbitrum, ethereum, opbnbmainnet --- src/utils.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/utils.ts b/src/utils.ts index c6cbe9867..b0fcef462 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -363,7 +363,11 @@ export const setMaxStalePeriod = async ( } const normalTimelock = - FORKED_NETWORK == "bscmainnet" || FORKED_NETWORK == "bsctestnet" + FORKED_NETWORK == "bscmainnet" || FORKED_NETWORK == "bsctestnet" + || FORKED_NETWORK == "arbitrumone" || FORKED_NETWORK == "arbitrumsepolia" + || FORKED_NETWORK == "ethereum" || FORKED_NETWORK == "sepolia" + || FORKED_NETWORK == "opbnbmainnet" || FORKED_NETWORK == "opbnbtestnet" + ? getForkedNetworkAddress("NORMAL_TIMELOCK") : getForkedNetworkAddress("GUARDIAN"); const tokenConfig: TokenConfig = await resilientOracle.getTokenConfig(underlyingAsset.address); From 86310f0a7b603149fa796de5cc618167c77d6274 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Mon, 25 Nov 2024 22:13:30 +0530 Subject: [PATCH 165/178] refactor: prettier --- multisig/proposals/arbitrumone/vip-018/index.ts | 5 ++--- simulations/vip-398/arbitrumone.ts | 2 +- src/utils.ts | 13 ++++++++----- 3 files changed, 11 insertions(+), 9 deletions(-) diff --git a/multisig/proposals/arbitrumone/vip-018/index.ts b/multisig/proposals/arbitrumone/vip-018/index.ts index d0b05ca1e..4c969068d 100644 --- a/multisig/proposals/arbitrumone/vip-018/index.ts +++ b/multisig/proposals/arbitrumone/vip-018/index.ts @@ -1,14 +1,13 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { makeProposal } from "src/utils"; -import { CONVERTER_NETWORK, PLP, USDC, USDT, WBTC, WETH, XVS_VAULT_TREASURY, ACM } from "./addresses"; +import { ACM, CONVERTER_NETWORK, PLP, USDC, USDT, WBTC, WETH, XVS_VAULT_TREASURY } from "./addresses"; import { acceptOwnershipCommandsAllConverters, callPermissionCommandsAllConverter, setConverterNetworkCommands, } from "./commands"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; - const { arbitrumone } = NETWORK_ADDRESSES; const vip018 = () => { return makeProposal([ diff --git a/simulations/vip-398/arbitrumone.ts b/simulations/vip-398/arbitrumone.ts index 1aaa6a2f6..48bec66c7 100644 --- a/simulations/vip-398/arbitrumone.ts +++ b/simulations/vip-398/arbitrumone.ts @@ -1,7 +1,7 @@ import { expect } from "chai"; import { BigNumber, Contract, Signer } from "ethers"; import { parseUnits } from "ethers/lib/utils"; -import { ethers, network } from "hardhat"; +import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { expectEvents, initMainnetUser, setMaxStalePeriod } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; diff --git a/src/utils.ts b/src/utils.ts index b0fcef462..58b4b828a 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -363,11 +363,14 @@ export const setMaxStalePeriod = async ( } const normalTimelock = - FORKED_NETWORK == "bscmainnet" || FORKED_NETWORK == "bsctestnet" - || FORKED_NETWORK == "arbitrumone" || FORKED_NETWORK == "arbitrumsepolia" - || FORKED_NETWORK == "ethereum" || FORKED_NETWORK == "sepolia" - || FORKED_NETWORK == "opbnbmainnet" || FORKED_NETWORK == "opbnbtestnet" - + FORKED_NETWORK == "bscmainnet" || + FORKED_NETWORK == "bsctestnet" || + FORKED_NETWORK == "arbitrumone" || + FORKED_NETWORK == "arbitrumsepolia" || + FORKED_NETWORK == "ethereum" || + FORKED_NETWORK == "sepolia" || + FORKED_NETWORK == "opbnbmainnet" || + FORKED_NETWORK == "opbnbtestnet" ? getForkedNetworkAddress("NORMAL_TIMELOCK") : getForkedNetworkAddress("GUARDIAN"); const tokenConfig: TokenConfig = await resilientOracle.getTokenConfig(underlyingAsset.address); From 7fd015454610b96d5688703a48bc64ae33695a09 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Mon, 25 Nov 2024 22:34:58 +0530 Subject: [PATCH 166/178] add: setMaxStalePeriodForAllAssets --- src/utils.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/utils.ts b/src/utils.ts index 58b4b828a..5d41d647b 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -402,6 +402,12 @@ export const setMaxStalePeriod = async ( await mine(100); }; +export const setMaxStalePeriodForAllAssets = async (resilientOracle: Contract, assets: Contract[]): Promise => { + for (const asset of assets) { + await setMaxStalePeriod(resilientOracle, asset); + } +}; + export const expectEvents = async ( txResponse: TransactionResponse, abis: (string | JsonFragment[])[], From 7c7baa1defabd4b994592d906d1d78ab88e73ea1 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Mon, 25 Nov 2024 22:35:14 +0530 Subject: [PATCH 167/178] fix: test prime --- simulations/vip-398/arbitrumone.ts | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/simulations/vip-398/arbitrumone.ts b/simulations/vip-398/arbitrumone.ts index 48bec66c7..4f04f3559 100644 --- a/simulations/vip-398/arbitrumone.ts +++ b/simulations/vip-398/arbitrumone.ts @@ -3,7 +3,7 @@ import { BigNumber, Contract, Signer } from "ethers"; import { parseUnits } from "ethers/lib/utils"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; -import { expectEvents, initMainnetUser, setMaxStalePeriod } from "src/utils"; +import { expectEvents, initMainnetUser, setMaxStalePeriodForAllAssets } from "src/utils"; import { forking, pretendExecutingVip, testForkedNetworkVipCommands } from "src/vip-framework"; import vip018 from "../../multisig/proposals/arbitrumone/vip-018"; @@ -13,6 +13,8 @@ import { USDC_PRIME_CONVERTER, USDT, USDT_PRIME_CONVERTER, + WBTC, + WETH, XVS, XVS_VAULT_CONVERTER, XVS_VAULT_TREASURY, @@ -160,6 +162,8 @@ forking(278099102, async () => { let user1Address: string; let resilientOracle: Contract; let xvs: Contract; + let weth: Contract; + let wbtc: Contract; const amount = parseUnits("1000", 6); @@ -167,6 +171,9 @@ forking(278099102, async () => { usdt = new ethers.Contract(USDT, ERC20_ABI, provider); usdc = new ethers.Contract(USDC, ERC20_ABI, provider); xvs = new ethers.Contract(XVS, ERC20_ABI, provider); + weth = new ethers.Contract(WETH, ERC20_ABI, provider); + xvs = new ethers.Contract(XVS, ERC20_ABI, provider); + wbtc = new ethers.Contract(WBTC, ERC20_ABI, provider); resilientOracle = new ethers.Contract(arbitrumone.RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); @@ -178,8 +185,7 @@ forking(278099102, async () => { await usdt.connect(usdtHolder).transfer(user1Address, amount); await usdc.connect(usdcHolder).transfer(user1Address, amount); - await setMaxStalePeriod(resilientOracle, usdt); - await setMaxStalePeriod(resilientOracle, usdc); + await setMaxStalePeriodForAllAssets(resilientOracle, [usdt, usdc, weth, wbtc, xvs]); }); it("PSR should have correct distribution configs", async () => { @@ -298,7 +304,6 @@ forking(278099102, async () => { it("claim prime token", async () => { const xvsUserSigner = await initMainnetUser(XVS_USER, parseUnits("10")); - await setMaxStalePeriod(resilientOracle, xvs); await expect(prime.connect(xvsUserSigner).claim()).not.to.be.reverted; }); }); From 7d180132f016527819793a9dfa7a772ddf955ba3 Mon Sep 17 00:00:00 2001 From: Debugger022 Date: Mon, 25 Nov 2024 22:57:20 +0530 Subject: [PATCH 168/178] fix: vip number 398 to 400 --- multisig/simulations/arbitrumone/vip-018/index.ts | 2 +- simulations/{vip-398 => vip-400}/abi/ERC20.json | 0 simulations/{vip-398 => vip-400}/abi/ILComptroller.json | 0 .../{vip-398 => vip-400}/abi/OmnichainProposalSender.json | 0 simulations/{vip-398 => vip-400}/abi/Prime.json | 0 .../{vip-398 => vip-400}/abi/PrimeLiquidityProvider.json | 0 .../{vip-398 => vip-400}/abi/ProtocolShareReserve.json | 0 simulations/{vip-398 => vip-400}/arbitrumone.ts | 8 ++++---- simulations/{vip-398 => vip-400}/arbitrumsepolia.ts | 2 +- simulations/{vip-398 => vip-400}/bscmainnet.ts | 6 +++--- simulations/{vip-398 => vip-400}/bsctestnet.ts | 4 ++-- vips/{vip-398 => vip-400}/bscmainnet.ts | 6 +++--- vips/{vip-398 => vip-400}/bsctestnet.ts | 0 13 files changed, 14 insertions(+), 14 deletions(-) rename simulations/{vip-398 => vip-400}/abi/ERC20.json (100%) rename simulations/{vip-398 => vip-400}/abi/ILComptroller.json (100%) rename simulations/{vip-398 => vip-400}/abi/OmnichainProposalSender.json (100%) rename simulations/{vip-398 => vip-400}/abi/Prime.json (100%) rename simulations/{vip-398 => vip-400}/abi/PrimeLiquidityProvider.json (100%) rename simulations/{vip-398 => vip-400}/abi/ProtocolShareReserve.json (100%) rename simulations/{vip-398 => vip-400}/arbitrumone.ts (98%) rename simulations/{vip-398 => vip-400}/arbitrumsepolia.ts (99%) rename simulations/{vip-398 => vip-400}/bscmainnet.ts (72%) rename simulations/{vip-398 => vip-400}/bsctestnet.ts (85%) rename vips/{vip-398 => vip-400}/bscmainnet.ts (98%) rename vips/{vip-398 => vip-400}/bsctestnet.ts (100%) diff --git a/multisig/simulations/arbitrumone/vip-018/index.ts b/multisig/simulations/arbitrumone/vip-018/index.ts index 534287eea..c57d2a78c 100644 --- a/multisig/simulations/arbitrumone/vip-018/index.ts +++ b/multisig/simulations/arbitrumone/vip-018/index.ts @@ -31,7 +31,7 @@ const COMPTROLLER_CORE = "0x317c1A5739F39046E20b08ac9BeEa3f10fD43326"; const COMPTROLLER_LST = "0x52bAB1aF7Ff770551BD05b9FC2329a0Bf5E23F16"; const PRIME = "0xFE69720424C954A2da05648a0FAC84f9bf11Ef49"; -forking(276102872, async () => { +forking(278226922, async () => { const provider = ethers.provider; let converterNetwork: Contract; let xvsVaultTreasury: Contract; diff --git a/simulations/vip-398/abi/ERC20.json b/simulations/vip-400/abi/ERC20.json similarity index 100% rename from simulations/vip-398/abi/ERC20.json rename to simulations/vip-400/abi/ERC20.json diff --git a/simulations/vip-398/abi/ILComptroller.json b/simulations/vip-400/abi/ILComptroller.json similarity index 100% rename from simulations/vip-398/abi/ILComptroller.json rename to simulations/vip-400/abi/ILComptroller.json diff --git a/simulations/vip-398/abi/OmnichainProposalSender.json b/simulations/vip-400/abi/OmnichainProposalSender.json similarity index 100% rename from simulations/vip-398/abi/OmnichainProposalSender.json rename to simulations/vip-400/abi/OmnichainProposalSender.json diff --git a/simulations/vip-398/abi/Prime.json b/simulations/vip-400/abi/Prime.json similarity index 100% rename from simulations/vip-398/abi/Prime.json rename to simulations/vip-400/abi/Prime.json diff --git a/simulations/vip-398/abi/PrimeLiquidityProvider.json b/simulations/vip-400/abi/PrimeLiquidityProvider.json similarity index 100% rename from simulations/vip-398/abi/PrimeLiquidityProvider.json rename to simulations/vip-400/abi/PrimeLiquidityProvider.json diff --git a/simulations/vip-398/abi/ProtocolShareReserve.json b/simulations/vip-400/abi/ProtocolShareReserve.json similarity index 100% rename from simulations/vip-398/abi/ProtocolShareReserve.json rename to simulations/vip-400/abi/ProtocolShareReserve.json diff --git a/simulations/vip-398/arbitrumone.ts b/simulations/vip-400/arbitrumone.ts similarity index 98% rename from simulations/vip-398/arbitrumone.ts rename to simulations/vip-400/arbitrumone.ts index 4f04f3559..f79076ee2 100644 --- a/simulations/vip-398/arbitrumone.ts +++ b/simulations/vip-400/arbitrumone.ts @@ -24,7 +24,7 @@ import RESILIENT_ORACLE_ABI from "../../multisig/simulations/arbitrumone/vip-001 import CONVERTER_NETWORK_ABI from "../../multisig/simulations/arbitrumone/vip-018/abi/ConverterNetwork.json"; import SINGLE_TOKEN_CONVERTER_ABI from "../../multisig/simulations/arbitrumone/vip-018/abi/SingleTokenConverter.json"; import XVS_VAULT_TREASURY_ABI from "../../multisig/simulations/arbitrumone/vip-018/abi/XVSVaultTreasury.json"; -import vip398, { +import vip400, { ARBITRUM_COMPTROLLER_CORE, ARBITRUM_COMPTROLLER_LST, ARBITRUM_PLP, @@ -37,7 +37,7 @@ import vip398, { ARBITRUM_VWETH_LST, ARBITRUM_WBTC, ARBITRUM_WETH, -} from "../../vips/vip-398/bscmainnet"; +} from "../../vips/vip-400/bscmainnet"; import ERC20_ABI from "./abi/ERC20.json"; import COMPTROLLER_ABI from "./abi/ILComptroller.json"; import PRIME_ABI from "./abi/Prime.json"; @@ -51,7 +51,7 @@ const XVS_USER = "0xC469eCb73159b88957965758002bBE1807532814"; const ARBITRUM_PROTOCOL_SHARE_RESERVE_PROXY = "0xF9263eaF7eB50815194f26aCcAB6765820B13D41"; -forking(278099102, async () => { +forking(278226922, async () => { const provider = ethers.provider; let prime: Contract; let converterNetwork: Contract; @@ -86,7 +86,7 @@ forking(278099102, async () => { }); }); - testForkedNetworkVipCommands("VIP 398", await vip398(), { + testForkedNetworkVipCommands("VIP 400", await vip400(), { callbackAfterExecution: async txResponse => { await expectEvents(txResponse, [PRIME_ABI], ["MarketAdded"], [4]); await expectEvents(txResponse, [PRIME_ABI], ["MintLimitsUpdated"], [1]); diff --git a/simulations/vip-398/arbitrumsepolia.ts b/simulations/vip-400/arbitrumsepolia.ts similarity index 99% rename from simulations/vip-398/arbitrumsepolia.ts rename to simulations/vip-400/arbitrumsepolia.ts index 2f8fd16ec..b9834fcc6 100644 --- a/simulations/vip-398/arbitrumsepolia.ts +++ b/simulations/vip-400/arbitrumsepolia.ts @@ -31,7 +31,7 @@ import vip395, { ARBITRUM_SEPOLIA_VWETH_LST, ARBITRUM_SEPOLIA_WBTC, ARBITRUM_SEPOLIA_WETH, -} from "../../vips/vip-398/bsctestnet"; +} from "../../vips/vip-400/bsctestnet"; import ERC20_ABI from "./abi/ERC20.json"; import COMPTROLLER_ABI from "./abi/ILComptroller.json"; import PRIME_ABI from "./abi/Prime.json"; diff --git a/simulations/vip-398/bscmainnet.ts b/simulations/vip-400/bscmainnet.ts similarity index 72% rename from simulations/vip-398/bscmainnet.ts rename to simulations/vip-400/bscmainnet.ts index caaf115ee..f8ba694bd 100644 --- a/simulations/vip-398/bscmainnet.ts +++ b/simulations/vip-400/bscmainnet.ts @@ -1,10 +1,10 @@ import { expectEvents } from "../../src/utils"; import { forking, testVip } from "../../src/vip-framework"; -import vip398 from "../../vips/vip-398/bscmainnet"; +import vip400 from "../../vips/vip-400/bscmainnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; -forking(44169313, async () => { - testVip("vip398 Arbitrum one Prime configuration", await vip398(), { +forking(44324800, async () => { + testVip("vip400 Arbitrum one Prime configuration", await vip400(), { callbackAfterExecution: async txResponse => { await expectEvents( txResponse, diff --git a/simulations/vip-398/bsctestnet.ts b/simulations/vip-400/bsctestnet.ts similarity index 85% rename from simulations/vip-398/bsctestnet.ts rename to simulations/vip-400/bsctestnet.ts index 8db5c0844..915b22913 100644 --- a/simulations/vip-398/bsctestnet.ts +++ b/simulations/vip-400/bsctestnet.ts @@ -1,9 +1,9 @@ import { expectEvents } from "../../src/utils"; import { forking, testVip } from "../../src/vip-framework"; -import vip395 from "../../vips/vip-398/bsctestnet"; +import vip395 from "../../vips/vip-400/bsctestnet"; import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; -forking(45736960, async () => { +forking(44324800, async () => { testVip("vip395 arbitrum sepolia Prime configuration", await vip395(), { callbackAfterExecution: async txResponse => { await expectEvents( diff --git a/vips/vip-398/bscmainnet.ts b/vips/vip-400/bscmainnet.ts similarity index 98% rename from vips/vip-398/bscmainnet.ts rename to vips/vip-400/bscmainnet.ts index 21d710aab..c34464a02 100644 --- a/vips/vip-398/bscmainnet.ts +++ b/vips/vip-400/bscmainnet.ts @@ -44,10 +44,10 @@ export const ARBITRUM_XVS_VAULT_TREASURY = "0xb076D4f15c08D7A7B89466327Ba71bc7e1 export const ARBITRUM_PROTOCOL_SHARE_RESERVE_PROXY = "0xF9263eaF7eB50815194f26aCcAB6765820B13D41"; export const ARBITRUM_VTREASURY = "0x8a662ceAC418daeF956Bc0e6B2dd417c80CDA631"; -const vip398 = () => { +const vip400 = () => { const meta = { version: "v2", - title: "vip398 arbitrum Prime configuration", + title: "vip400 arbitrum Prime configuration", description: `#### Description This VIP will grant permission to timelocks and performs the necessary configuration of OmnichainProposalSender on BNB chain and OmnichainProposalExecutor`, forDescription: "I agree that Venus Protocol should proceed with this proposal", @@ -181,4 +181,4 @@ const vip398 = () => { ); }; -export default vip398; +export default vip400; diff --git a/vips/vip-398/bsctestnet.ts b/vips/vip-400/bsctestnet.ts similarity index 100% rename from vips/vip-398/bsctestnet.ts rename to vips/vip-400/bsctestnet.ts From 61a7f6fe6187c0dca945f029779a38cbc6589c00 Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Tue, 26 Nov 2024 16:54:13 +0300 Subject: [PATCH 169/178] feat: grant permissions to timelocks and guardian --- .../proposals/arbitrumone/vip-018/commands.ts | 39 +++++++---------- src/networkAddresses.ts | 2 + vips/vip-400/bscmainnet.ts | 42 +++++++++++-------- 3 files changed, 41 insertions(+), 42 deletions(-) diff --git a/multisig/proposals/arbitrumone/vip-018/commands.ts b/multisig/proposals/arbitrumone/vip-018/commands.ts index 43eb6e441..12fba5ae5 100644 --- a/multisig/proposals/arbitrumone/vip-018/commands.ts +++ b/multisig/proposals/arbitrumone/vip-018/commands.ts @@ -5,6 +5,9 @@ import { ACM, Assets, CONVERTER_NETWORK, converters } from "./addresses"; const { arbitrumone } = NETWORK_ADDRESSES; +const { NORMAL_TIMELOCK, FAST_TRACK_TIMELOCK, CRITICAL_TIMELOCK, GUARDIAN } = arbitrumone; +const timelocks = [NORMAL_TIMELOCK, FAST_TRACK_TIMELOCK, CRITICAL_TIMELOCK]; + type IncentiveAndAccessibility = [number, number]; interface AcceptOwnership { @@ -64,32 +67,20 @@ const generateAddConverterNetworkCommands = () => { })); }; -function generateCallPermissionCommands(ConvertersArray: string[]): CallPermission[] { - const callPermissionCommandsArray: CallPermission[] = []; - - for (const converter of ConvertersArray) { - const config1 = grant( - converter, - "setConversionConfig(address,address,ConversionConfig)", - arbitrumone.NORMAL_TIMELOCK, - ); - const config2 = grant(converter, "pauseConversion()", arbitrumone.NORMAL_TIMELOCK); - const config3 = grant(converter, "resumeConversion()", arbitrumone.NORMAL_TIMELOCK); - const config4 = grant(converter, "setMinAmountToConvert(uint256)", arbitrumone.NORMAL_TIMELOCK); - - callPermissionCommandsArray.push(config1); - callPermissionCommandsArray.push(config2); - callPermissionCommandsArray.push(config3); - callPermissionCommandsArray.push(config4); - } - return callPermissionCommandsArray; +function generateCallPermissionCommands(convertersArray: string[]): CallPermission[] { + return convertersArray.flatMap(converter => [ + ...timelocks.flatMap(timelock => [ + grant(converter, "setConversionConfig(address,address,ConversionConfig)", timelock), + grant(converter, "pauseConversion()", timelock), + grant(converter, "resumeConversion()", timelock), + grant(converter, "setMinAmountToConvert(uint256)", timelock), + ]), + grant(converter, "pauseConversion()", GUARDIAN), + grant(converter, "resumeConversion()", GUARDIAN), + ]); } -export const incentiveAndAccessibilities: IncentiveAndAccessibility[] = []; - -for (let i = 0; i < Assets.length - 1; i++) { - incentiveAndAccessibilities.push(incentiveAndAccessibility); -} +export const incentiveAndAccessibilities = new Array(Assets.length - 1).fill(incentiveAndAccessibility); export const acceptOwnershipCommandsAllConverters: AcceptOwnership[] = generateAcceptOwnershipCommands(converters); diff --git a/src/networkAddresses.ts b/src/networkAddresses.ts index 6aac7b716..878176bcb 100644 --- a/src/networkAddresses.ts +++ b/src/networkAddresses.ts @@ -152,6 +152,8 @@ export const NETWORK_ADDRESSES = { }, arbitrumone: { NORMAL_TIMELOCK: "0x4b94589Cc23F618687790036726f744D602c4017", + FAST_TRACK_TIMELOCK: "0x2286a9B2a5246218f2fC1F380383f45BDfCE3E04", + CRITICAL_TIMELOCK: "0x181E4f8F21D087bF02Ea2F64D5e550849FBca674", GUARDIAN: "0x14e0E151b33f9802b3e75b621c1457afc44DcAA0", CHAINLINK_ORACLE: "0x9cd9Fcc7E3dEDA360de7c080590AaD377ac9F113", REDSTONE_ORACLE: "0xF792C4D3BdeF534D6d1dcC305056D00C95453dD6", diff --git a/vips/vip-400/bscmainnet.ts b/vips/vip-400/bscmainnet.ts index c34464a02..f4b318617 100644 --- a/vips/vip-400/bscmainnet.ts +++ b/vips/vip-400/bscmainnet.ts @@ -25,6 +25,8 @@ import { const { arbitrumone } = NETWORK_ADDRESSES; +const { NORMAL_TIMELOCK, FAST_TRACK_TIMELOCK, CRITICAL_TIMELOCK } = arbitrumone; + export const ARBITRUM_COMPTROLLER_CORE = "0x317c1A5739F39046E20b08ac9BeEa3f10fD43326"; export const ARBITRUM_COMPTROLLER_LST = "0x52bAB1aF7Ff770551BD05b9FC2329a0Bf5E23F16"; export const ARBITRUM_PRIME = "0xFE69720424C954A2da05648a0FAC84f9bf11Ef49"; @@ -44,6 +46,8 @@ export const ARBITRUM_XVS_VAULT_TREASURY = "0xb076D4f15c08D7A7B89466327Ba71bc7e1 export const ARBITRUM_PROTOCOL_SHARE_RESERVE_PROXY = "0xF9263eaF7eB50815194f26aCcAB6765820B13D41"; export const ARBITRUM_VTREASURY = "0x8a662ceAC418daeF956Bc0e6B2dd417c80CDA631"; +const timelocks = [NORMAL_TIMELOCK, FAST_TRACK_TIMELOCK, CRITICAL_TIMELOCK]; + const vip400 = () => { const meta = { version: "v2", @@ -109,24 +113,26 @@ const vip400 = () => { ], dstChainId: LzChainId.arbitrumone, }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [CONVERTER_NETWORK, "addTokenConverter(address)", arbitrumone.NORMAL_TIMELOCK], - dstChainId: LzChainId.arbitrumone, - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [CONVERTER_NETWORK, "removeTokenConverter(address)", arbitrumone.NORMAL_TIMELOCK], - dstChainId: LzChainId.arbitrumone, - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [ARBITRUM_XVS_VAULT_TREASURY, "fundXVSVault(uint256)", arbitrumone.NORMAL_TIMELOCK], - dstChainId: LzChainId.arbitrumone, - }, + ...timelocks.flatMap(timelock => [ + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [CONVERTER_NETWORK, "addTokenConverter(address)", timelock], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [CONVERTER_NETWORK, "removeTokenConverter(address)", timelock], + dstChainId: LzChainId.arbitrumone, + }, + { + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [ARBITRUM_XVS_VAULT_TREASURY, "fundXVSVault(uint256)", timelock], + dstChainId: LzChainId.arbitrumone, + }, + ]), { target: ARBITRUM_PROTOCOL_SHARE_RESERVE_PROXY, signature: "addOrUpdateDistributionConfigs((uint8,uint16,address)[])", From 55ef2eea431e14d8d159aabf2adb4c59f6c4d792 Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Tue, 26 Nov 2024 17:13:32 +0300 Subject: [PATCH 170/178] fix: add arbitrumone to supported forked networks --- type-extensions.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/type-extensions.ts b/type-extensions.ts index 9518fe4aa..8c2f37155 100644 --- a/type-extensions.ts +++ b/type-extensions.ts @@ -10,6 +10,7 @@ declare module "hardhat/types/runtime" { | "ethereum" | "opbnbtestnet" | "opbnbmainnet" + | "arbitrumone" | "arbitrumsepolia" | "zksyncsepolia" | "zksyncmainnet"; From adb9e28ee7e6a236ba7a3f89aaf97dc8663c3af0 Mon Sep 17 00:00:00 2001 From: Kirill Kuvshinov Date: Tue, 26 Nov 2024 19:06:22 +0300 Subject: [PATCH 171/178] feat: grant permissions to timelocks on arbitrumsepolia --- src/networkAddresses.ts | 2 + vips/vip-400/bsctestnet-addendum.ts | 67 +++++++++++++++++++++++++++++ 2 files changed, 69 insertions(+) create mode 100644 vips/vip-400/bsctestnet-addendum.ts diff --git a/src/networkAddresses.ts b/src/networkAddresses.ts index 878176bcb..9dbab1464 100644 --- a/src/networkAddresses.ts +++ b/src/networkAddresses.ts @@ -137,6 +137,8 @@ export const NETWORK_ADDRESSES = { }, arbitrumsepolia: { NORMAL_TIMELOCK: "0x794BCA78E606f3a462C31e5Aba98653Efc1322F8", + FAST_TRACK_TIMELOCK: "0x14642991184F989F45505585Da52ca6A6a7dD4c8", + CRITICAL_TIMELOCK: "0x0b32Be083f7041608E023007e7802430396a2123", GUARDIAN: "0x1426A5Ae009c4443188DA8793751024E358A61C2", CHAINLINK_ORACLE: "0xeDd02c7FfA31490b4107e8f2c25e9198a04F9E45", RESILIENT_ORACLE: "0x6708bAd042916B47311c8078b29d7f432342102F", diff --git a/vips/vip-400/bsctestnet-addendum.ts b/vips/vip-400/bsctestnet-addendum.ts new file mode 100644 index 000000000..d2e7b8981 --- /dev/null +++ b/vips/vip-400/bsctestnet-addendum.ts @@ -0,0 +1,67 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { Command, LzChainId, ProposalType } from "src/types"; +import { makeProposal } from "src/utils"; + +import { + ACM, + CONVERTER_NETWORK, + USDC_PRIME_CONVERTER, + USDT_PRIME_CONVERTER, + WBTC_PRIME_CONVERTER, + WETH_PRIME_CONVERTER, + XVS_VAULT_CONVERTER, +} from "../../multisig/proposals/arbitrumsepolia/vip-019/Addresses"; + +const { arbitrumsepolia } = NETWORK_ADDRESSES; +const { FAST_TRACK_TIMELOCK, CRITICAL_TIMELOCK, GUARDIAN } = arbitrumsepolia; + +export const ARBITRUM_SEPOLIA_XVS_VAULT_TREASURY = "0x309b71a417dA9CfA8aC47e6038000B1739d9A3A6"; + +const grant = (target: string, signature: string, caller: string): Command => ({ + target: ACM, + signature: "giveCallPermission(address,string,address)", + params: [target, signature, caller], + dstChainId: LzChainId.arbitrumsepolia, +}); + +const converters = [ + USDC_PRIME_CONVERTER, + USDT_PRIME_CONVERTER, + WBTC_PRIME_CONVERTER, + WETH_PRIME_CONVERTER, + XVS_VAULT_CONVERTER, +]; + +const vip400Addendum = () => { + const meta = { + version: "v2", + title: "vip400 addendum - arbitrum sepolia Prime configuration", + description: `Extend permissions to FAST_TRACK and CRITICAL timelocks on the privilege commands of Converters, ConverterNetwork and XVSVaultTreasury`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + return makeProposal( + [ + ...[FAST_TRACK_TIMELOCK, CRITICAL_TIMELOCK].flatMap(timelock => [ + grant(CONVERTER_NETWORK, "addTokenConverter(address)", timelock), + grant(CONVERTER_NETWORK, "removeTokenConverter(address)", timelock), + grant(ARBITRUM_SEPOLIA_XVS_VAULT_TREASURY, "fundXVSVault(uint256)", timelock), + ]), + ...converters.flatMap(converter => [ + ...[FAST_TRACK_TIMELOCK, CRITICAL_TIMELOCK].flatMap(timelock => [ + grant(converter, "setConversionConfig(address,address,ConversionConfig)", timelock), + grant(converter, "pauseConversion()", timelock), + grant(converter, "resumeConversion()", timelock), + grant(converter, "setMinAmountToConvert(uint256)", timelock), + ]), + grant(converter, "pauseConversion()", GUARDIAN), + grant(converter, "resumeConversion()", GUARDIAN), + ]), + ], + meta, + ProposalType.REGULAR, + ); +}; + +export default vip400Addendum; From 9def09dc60d63437d0b9a579d8b68b815d41b2d4 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Tue, 26 Nov 2024 19:25:00 +0100 Subject: [PATCH 172/178] fix: use checksummed addresses --- multisig/proposals/arbitrumone/vip-018/addresses.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/multisig/proposals/arbitrumone/vip-018/addresses.ts b/multisig/proposals/arbitrumone/vip-018/addresses.ts index e83c78f49..7e02b45b5 100644 --- a/multisig/proposals/arbitrumone/vip-018/addresses.ts +++ b/multisig/proposals/arbitrumone/vip-018/addresses.ts @@ -1,7 +1,7 @@ -export const USDT = "0xfd086bc7cd5c481dcc9c85ebe478a1c0b69fcbb9"; -export const USDC = "0xaf88d065e77c8cc2239327c5edb3a432268e5831"; -export const WBTC = "0x2f2a2543b76a4166549f7aab2e75bef0aefc5b0f"; -export const WETH = "0x82af49447d8a07e3bd95bd0d56f35241523fbab1"; +export const USDT = "0xFd086bC7CD5C481DCC9C85ebE478A1C0b69FCbb9"; +export const USDC = "0xaf88d065e77c8cC2239327C5EDb3A432268e5831"; +export const WBTC = "0x2f2a2543B76A4166549F7aaB2e75Bef0aefC5B0f"; +export const WETH = "0x82aF49447D8a07e3bd95BD0d56f35241523fBab1"; export const PLP = "0x86bf21dB200f29F21253080942Be8af61046Ec29"; export const XVS = "0xc1Eb7689147C81aC840d4FF0D298489fc7986d52"; export const XVS_VAULT_TREASURY = "0xb076D4f15c08D7A7B89466327Ba71bc7e1311b58"; From 5008d01a122f9e387dc04fa239bf9fbab77065ec Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Tue, 26 Nov 2024 20:11:06 +0100 Subject: [PATCH 173/178] feat: move the config of permissions to the TX to avoid exceeding the LZ payload limit --- .../proposals/arbitrumone/vip-018/commands.ts | 17 ++- .../proposals/arbitrumone/vip-018/index.ts | 8 +- vips/vip-400/bscmainnet.ts | 122 ++++++++++++------ 3 files changed, 101 insertions(+), 46 deletions(-) diff --git a/multisig/proposals/arbitrumone/vip-018/commands.ts b/multisig/proposals/arbitrumone/vip-018/commands.ts index 12fba5ae5..f2844f2ab 100644 --- a/multisig/proposals/arbitrumone/vip-018/commands.ts +++ b/multisig/proposals/arbitrumone/vip-018/commands.ts @@ -1,7 +1,7 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { LzChainId } from "src/types"; -import { ACM, Assets, CONVERTER_NETWORK, converters } from "./addresses"; +import { ACM, Assets, CONVERTER_NETWORK, XVS_VAULT_TREASURY, converters } from "./addresses"; const { arbitrumone } = NETWORK_ADDRESSES; @@ -67,7 +67,7 @@ const generateAddConverterNetworkCommands = () => { })); }; -function generateCallPermissionCommands(convertersArray: string[]): CallPermission[] { +function generateCallPermissionCommandsOnConverters(convertersArray: string[]): CallPermission[] { return convertersArray.flatMap(converter => [ ...timelocks.flatMap(timelock => [ grant(converter, "setConversionConfig(address,address,ConversionConfig)", timelock), @@ -80,6 +80,14 @@ function generateCallPermissionCommands(convertersArray: string[]): CallPermissi ]); } +function generateCallPermissionCommandsOnMisc(): CallPermission[] { + return timelocks.flatMap(timelock => [ + grant(CONVERTER_NETWORK, "addTokenConverter(address)", timelock), + grant(CONVERTER_NETWORK, "removeTokenConverter(address)", timelock), + grant(XVS_VAULT_TREASURY, "fundXVSVault(uint256)", timelock), + ]); +} + export const incentiveAndAccessibilities = new Array(Assets.length - 1).fill(incentiveAndAccessibility); export const acceptOwnershipCommandsAllConverters: AcceptOwnership[] = generateAcceptOwnershipCommands(converters); @@ -88,4 +96,7 @@ export const setConverterNetworkCommands = generateSetConverterNetworkCommands() export const addConverterNetworkCommands = generateAddConverterNetworkCommands(); -export const callPermissionCommandsAllConverter: CallPermission[] = generateCallPermissionCommands(converters); +export const callPermissionCommands: CallPermission[] = [ + ...generateCallPermissionCommandsOnConverters(converters), + ...generateCallPermissionCommandsOnMisc(), +]; diff --git a/multisig/proposals/arbitrumone/vip-018/index.ts b/multisig/proposals/arbitrumone/vip-018/index.ts index 4c969068d..3aeea684b 100644 --- a/multisig/proposals/arbitrumone/vip-018/index.ts +++ b/multisig/proposals/arbitrumone/vip-018/index.ts @@ -2,11 +2,7 @@ import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { makeProposal } from "src/utils"; import { ACM, CONVERTER_NETWORK, PLP, USDC, USDT, WBTC, WETH, XVS_VAULT_TREASURY } from "./addresses"; -import { - acceptOwnershipCommandsAllConverters, - callPermissionCommandsAllConverter, - setConverterNetworkCommands, -} from "./commands"; +import { acceptOwnershipCommandsAllConverters, callPermissionCommands, setConverterNetworkCommands } from "./commands"; const { arbitrumone } = NETWORK_ADDRESSES; const vip018 = () => { @@ -32,7 +28,7 @@ const vip018 = () => { signature: "giveCallPermission(address,string,address)", params: [arbitrumone.REDSTONE_ORACLE, "setTokenConfig(TokenConfig)", arbitrumone.GUARDIAN], }, - ...callPermissionCommandsAllConverter, + ...callPermissionCommands, ...setConverterNetworkCommands, ]); }; diff --git a/vips/vip-400/bscmainnet.ts b/vips/vip-400/bscmainnet.ts index f4b318617..08e677992 100644 --- a/vips/vip-400/bscmainnet.ts +++ b/vips/vip-400/bscmainnet.ts @@ -1,12 +1,9 @@ import { ethers } from "hardhat"; -import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { LzChainId, ProposalType } from "src/types"; import { makeProposal } from "src/utils"; import { - ACM, BaseAssets, - CONVERTER_NETWORK, USDCPrimeConverterTokenOuts, USDC_PRIME_CONVERTER, USDTPrimeConverterTokenOuts, @@ -23,37 +20,108 @@ import { incentiveAndAccessibilities, } from "../../multisig/proposals/arbitrumone/vip-018/commands"; -const { arbitrumone } = NETWORK_ADDRESSES; - -const { NORMAL_TIMELOCK, FAST_TRACK_TIMELOCK, CRITICAL_TIMELOCK } = arbitrumone; - export const ARBITRUM_COMPTROLLER_CORE = "0x317c1A5739F39046E20b08ac9BeEa3f10fD43326"; export const ARBITRUM_COMPTROLLER_LST = "0x52bAB1aF7Ff770551BD05b9FC2329a0Bf5E23F16"; export const ARBITRUM_PRIME = "0xFE69720424C954A2da05648a0FAC84f9bf11Ef49"; export const ARBITRUM_PLP = "0x86bf21dB200f29F21253080942Be8af61046Ec29"; -export const ARBITRUM_USDT = "0xfd086bc7cd5c481dcc9c85ebe478a1c0b69fcbb9"; -export const ARBITRUM_USDC = "0xaf88d065e77c8cc2239327c5edb3a432268e5831"; -export const ARBITRUM_WBTC = "0x2f2a2543b76a4166549f7aab2e75bef0aefc5b0f"; -export const ARBITRUM_WETH = "0x82af49447d8a07e3bd95bd0d56f35241523fbab1"; +export const ARBITRUM_USDT = "0xFd086bC7CD5C481DCC9C85ebE478A1C0b69FCbb9"; +export const ARBITRUM_USDC = "0xaf88d065e77c8cC2239327C5EDb3A432268e5831"; +export const ARBITRUM_WBTC = "0x2f2a2543B76A4166549F7aaB2e75Bef0aefC5B0f"; +export const ARBITRUM_WETH = "0x82aF49447D8a07e3bd95BD0d56f35241523fBab1"; export const ARBITRUM_VUSDT_CORE = "0xB9F9117d4200dC296F9AcD1e8bE1937df834a2fD"; export const ARBITRUM_VUSDC_CORE = "0x7D8609f8da70fF9027E9bc5229Af4F6727662707"; export const ARBITRUM_VWBTC_CORE = "0xaDa57840B372D4c28623E87FC175dE8490792811"; export const ARBITRUM_VWETH_LST = "0x39D6d13Ea59548637104E40e729E4aABE27FE106"; -export const ARBITRUM_XVS_VAULT_TREASURY = "0xb076D4f15c08D7A7B89466327Ba71bc7e1311b58"; export const ARBITRUM_PROTOCOL_SHARE_RESERVE_PROXY = "0xF9263eaF7eB50815194f26aCcAB6765820B13D41"; export const ARBITRUM_VTREASURY = "0x8a662ceAC418daeF956Bc0e6B2dd417c80CDA631"; -const timelocks = [NORMAL_TIMELOCK, FAST_TRACK_TIMELOCK, CRITICAL_TIMELOCK]; - const vip400 = () => { const meta = { version: "v2", - title: "vip400 arbitrum Prime configuration", - description: `#### Description - This VIP will grant permission to timelocks and performs the necessary configuration of OmnichainProposalSender on BNB chain and OmnichainProposalExecutor`, + title: "VIP-400 [Arbitrum] Enable Venus Prime (stage 1/2)", + description: `#### Summary + +If passed, following the Community post “[Venus Prime Deployment Proposal for Arbitrum](https://community.venus.io/t/venus-prime-deployment-proposal-for-arbitrum/4696)” and the associated [snapshot](https://snapshot.org/#/venus-xvs.eth/proposal/0x38c03ac9f3a4c71671162219af33a9b322270ecd57349e174d0d98ee03003ecb), this VIP will: + +- Enable claiming the Prime tokens on Arbitrum one. Eligible users will be able to claim their Prime tokens as soon as this VIP is executed +- Configure the [Token Converters](https://docs-v4.venus.io/technical-reference/reference-technical-articles/token-converters) contracts, to automatically convert the protocol income allocated to Prime into the expected tokens +- Configure the distribution rules in the [ProtocolShareReserve contract](https://arbiscan.io/address/0xF9263eaF7eB50815194f26aCcAB6765820B13D41), following the percentages proposed by the community + +#### Details + +This Prime parameters are similar to the configuration on the Ethereum and BNB Chain: + +- Markets: + - Core pool: + - USDT, USDC, WBTC + - Liquid Staked ETH + - WETH +- Minimum XVS to qualify: 1,000 XVS +- Maximum XVS cap: 100,000 XVS +- Number of days staking XVS to qualify: 90 +- Limit to the number of Prime holders: 500 revocable tokens, 0 irrevocable tokens +- Alpha: 0.5 (staked XVS and borrowed/supplied amounts have the same weight calculating the Prime user score) +- Supply multiplier: 2 (for the 4 markets) +- Borrow multiplier: 4 (for the 4 markets) + +Following the [Tokenomics](https://docs-v4.venus.io/governance/tokenomics), 20% of the protocol reserves are allocated to Prime. This VIP configures the distribution rules in the ProtocolShareReserve contract to distribute this 20% among the Prime markets, considering the [community proposal](https://community.venus.io/t/venus-prime-deployment-proposal-for-arbitrum/4696): + +- USDT (Core pool): 25% +- USDC (Core pool): 25% +- WBTC (Core pool): 15% +- WETH (Liquid Staked ETH pool): 35% + +No rewards are configured in this VIP. They would be configured in the future, with a different VIP. + +#### Security and additional considerations + +We applied the following security procedures for this upgrade: + +- **Configuration post VIP**: in a simulation environment, validating the ownerships of the contracts are the expected ones after the VIP, and conversions can be performed. +- **Deployment on testnet**: the same contracts were deployed and configured to testnet, and used in the Venus Protocol testnet deployment +- **Audit**: OpenZeppelin, Certik, Peckshield and Fairyproof have audited the deployed code. Additionally, OpenZeppelin and Certik audited the private conversions feature. + +Ownership of the contracts will be transferred to the [Guardian wallet](https://arbiscan.io/address/0x14e0E151b33f9802b3e75b621c1457afc44DcAA0). Ownership will be transferred to Governance after fully enabling the [Multichain Governance](https://docs-v4.venus.io/technical-reference/reference-technical-articles/multichain-governance) contracts. If this VIP passes, [this](https://app.safe.global/transactions/tx?safe=arb1:0x14e0E151b33f9802b3e75b621c1457afc44DcAA0&id=multisig_0x14e0E151b33f9802b3e75b621c1457afc44DcAA0_0x0dd00b537e67face5454e3c9595d7ec8ccdf5f05969d78e9c4dccabb36128321) multisig transaction will be executed. Otherwise, it will be rejected. + +#### Audit reports + +- Token converters + - [OpenZeppelin audit report (2023/10/10)](https://github.com/VenusProtocol/protocol-reserve/blob/f31dc8bb433f1cff6c2124d27742004d82b24c32/audits/066_tokenConverter_openzeppelin_20231010.pdf) + - [Certik audit audit report (2023/11/07)](https://github.com/VenusProtocol/protocol-reserve/blob/f31dc8bb433f1cff6c2124d27742004d82b24c32/audits/074_tokenConverter_certik_20231107.pdf) + - [Peckshield audit report (2023/09/27)](https://github.com/VenusProtocol/protocol-reserve/blob/f31dc8bb433f1cff6c2124d27742004d82b24c32/audits/068_tokenConverter_peckshield_20230927.pdf) + - [Fairyproof audit report (2023/08/28)](https://github.com/VenusProtocol/protocol-reserve/blob/f31dc8bb433f1cff6c2124d27742004d82b24c32/audits/067_tokenConverter_fairyproof_20230828.pdf) +- Private conversions + - [Certik audit report (2023/11/27)](https://github.com/VenusProtocol/protocol-reserve/blob/f31dc8bb433f1cff6c2124d27742004d82b24c32/audits/081_privateConversions_certik_20231127.pdf) + - [OpenZeppelin report (2024/01/09)](https://github.com/VenusProtocol/protocol-reserve/blob/f31dc8bb433f1cff6c2124d27742004d82b24c32/audits/082_privateConversions_openzeppelin_20240109.pdf) +- Prime + - [OpenZeppelin audit report (2023/10/03)](https://github.com/VenusProtocol/venus-protocol/blob/e02832bb2716bc0a178d910f6698877bf1b191e1/audits/065_prime_openzeppelin_20231003.pdf) + - [Certik audit audit report (2023/11/13)](https://github.com/VenusProtocol/venus-protocol/blob/2425501070d28c36a73861d9cf6970f641403735/audits/060_prime_certik_20231113.pdf) + - [Peckshield audit report (2023/08/26)](https://github.com/VenusProtocol/venus-protocol/blob/e02832bb2716bc0a178d910f6698877bf1b191e1/audits/055_prime_peckshield_20230826.pdf) + - [Fairyproof audit report (2023/09/10)](https://github.com/VenusProtocol/venus-protocol/blob/e02832bb2716bc0a178d910f6698877bf1b191e1/audits/056_prime_fairyproof_20230910.pdf) + - [Code4rena contest (2023/09/28)](https://code4rena.com/contests/2023-09-venus-prime) + +#### Deployed contracts to main net + +- [XVSVaultTreasury](https://arbiscan.io/address/0xb076D4f15c08D7A7B89466327Ba71bc7e1311b58) +- [SingleTokenConverterBeacon](https://arbiscan.io/address/0x993900Ab4ef4092e5B76d4781D09A2732086F0F0) +- [USDTPrimeConverter](https://arbiscan.io/address/0x435Fac1B002d5D31f374E07c0177A1D709d5DC2D) +- [USDCPrimeConverter](https://arbiscan.io/address/0x6553C9f9E131191d4fECb6F0E73bE13E229065C6) +- [WBTCPrimeConverter](https://arbiscan.io/address/0xF91369009c37f029aa28AF89709a352375E5A162) +- [WETHPrimeConverter](https://arbiscan.io/address/0x4aCB90ddD6df24dC6b0D50df84C94e72012026d0) +- [XVSVaultConverter](https://arbiscan.io/address/0x9c5A7aB705EA40876c1B292630a3ff2e0c213DB1) +- [ConverterNetwork](https://arbiscan.io/address/0x2F6672C9A0988748b0172D97961BecfD9DC6D6d5) + +#### References + +- [VIP simulation](https://github.com/VenusProtocol/vips/pull/429) +- [Tokenomics](https://docs-v4.venus.io/governance/tokenomics) +- Community post [Venus Prime Deployment Proposal for Arbitrum](https://community.venus.io/t/venus-prime-deployment-proposal-for-arbitrum/4696) +- Snapshot “[Deploy Venus Prime on Arbitrum](https://snapshot.org/#/venus-xvs.eth/proposal/0x38c03ac9f3a4c71671162219af33a9b322270ecd57349e174d0d98ee03003ecb)” +- [Source code of Prime contracts](https://github.com/VenusProtocol/venus-protocol/tree/main/contracts/Tokens/Prime) +- [Source code of Token Converters](https://github.com/VenusProtocol/protocol-reserve/tree/main/contracts/TokenConverter)`, forDescription: "I agree that Venus Protocol should proceed with this proposal", againstDescription: "I do not think that Venus Protocol should proceed with this proposal", abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", @@ -113,26 +181,6 @@ const vip400 = () => { ], dstChainId: LzChainId.arbitrumone, }, - ...timelocks.flatMap(timelock => [ - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [CONVERTER_NETWORK, "addTokenConverter(address)", timelock], - dstChainId: LzChainId.arbitrumone, - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [CONVERTER_NETWORK, "removeTokenConverter(address)", timelock], - dstChainId: LzChainId.arbitrumone, - }, - { - target: ACM, - signature: "giveCallPermission(address,string,address)", - params: [ARBITRUM_XVS_VAULT_TREASURY, "fundXVSVault(uint256)", timelock], - dstChainId: LzChainId.arbitrumone, - }, - ]), { target: ARBITRUM_PROTOCOL_SHARE_RESERVE_PROXY, signature: "addOrUpdateDistributionConfigs((uint8,uint16,address)[])", From f56cffc295877771c065ec3e1c0159e61243ea45 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Thu, 21 Nov 2024 20:12:23 +0100 Subject: [PATCH 174/178] feat: add remote commands to configure the bridge with Base --- hardhat.config.zksync.ts | 8 +- package.json | 2 +- .../vip-500/abi/OmnichainProposalSender.json | 314 ++++ simulations/vip-500/abi/XVS.json | 318 ++++ simulations/vip-500/abi/XVSBridgeAdmin.json | 287 +++ simulations/vip-500/abi/XVSProxyOFTSrc.json | 1616 +++++++++++++++++ simulations/vip-500/abi/resilientOracle.json | 640 +++++++ simulations/vip-500/arbitrumsepolia.ts | 19 + simulations/vip-500/bsctestnet.ts | 189 ++ simulations/vip-500/checkXVSBridge.ts | 192 ++ simulations/vip-500/opbnbtestnet.ts | 19 + simulations/vip-500/opsepolia.ts | 19 + simulations/vip-500/sepolia.ts | 19 + simulations/vip-500/zksyncsepolia.ts | 19 + src/networkAddresses.ts | 22 +- src/types.ts | 15 +- vips/vip-500/bsctestnet.ts | 122 ++ vips/vip-500/types.ts | 20 + 18 files changed, 3828 insertions(+), 12 deletions(-) create mode 100644 simulations/vip-500/abi/OmnichainProposalSender.json create mode 100644 simulations/vip-500/abi/XVS.json create mode 100644 simulations/vip-500/abi/XVSBridgeAdmin.json create mode 100644 simulations/vip-500/abi/XVSProxyOFTSrc.json create mode 100644 simulations/vip-500/abi/resilientOracle.json create mode 100644 simulations/vip-500/arbitrumsepolia.ts create mode 100644 simulations/vip-500/bsctestnet.ts create mode 100644 simulations/vip-500/checkXVSBridge.ts create mode 100644 simulations/vip-500/opbnbtestnet.ts create mode 100644 simulations/vip-500/opsepolia.ts create mode 100644 simulations/vip-500/sepolia.ts create mode 100644 simulations/vip-500/zksyncsepolia.ts create mode 100644 vips/vip-500/bsctestnet.ts create mode 100644 vips/vip-500/types.ts diff --git a/hardhat.config.zksync.ts b/hardhat.config.zksync.ts index be1385f8d..f681ac050 100644 --- a/hardhat.config.zksync.ts +++ b/hardhat.config.zksync.ts @@ -50,7 +50,7 @@ task("test", "Update fork config") .setAction(async function (taskArguments, hre, runSuper) { const { fork } = taskArguments; - if (hre.network.name === "zkSyncTestNode") { + if (hre.network.name === "zksynctestnode") { if (!process.env["ZKSYNC_ERA_LOCAL_TEST_NODE"]) { throw new Error("ZKSYNC_ERA_LOCAL_TEST_NODE env variable is not set"); } @@ -71,7 +71,7 @@ task("test", "Update fork config") allowUnlimitedContractSize: false, loggingEnabled: false, forking: - hre.network.name === "zkSyncTestNode" + hre.network.name === "zksynctestnode" ? { enabled: false, url: process.env["ZKSYNC_ERA_LOCAL_TEST_NODE"] as string, @@ -147,9 +147,9 @@ const config: HardhatUserConfig = { blockGasLimit: BLOCK_GAS_LIMIT_PER_NETWORK.zksyncmainnet, zksync: true, }, - zkSyncTestNode: { + zksynctestnode: { url: process.env.ZKSYNC_ERA_LOCAL_TEST_NODE || "http://localhost:8011", - chainId: 260, + chainId: 300, accounts: DEPLOYER_PRIVATE_KEY ? [`0x${DEPLOYER_PRIVATE_KEY}`] : [], blockGasLimit: BLOCK_GAS_LIMIT_PER_NETWORK.zksyncsepolia, timeout: 2000000000, diff --git a/package.json b/package.json index ac47f1e33..e5c2912c8 100644 --- a/package.json +++ b/package.json @@ -15,7 +15,7 @@ "docgen": "hardhat docgen", "clean": "hardhat clean && hardhat clean --config hardhat.config.zksync.ts", "local-test-node:zksyncmainnet": "hardhat node-zksync --fork https://mainnet.era.zksync.io --config hardhat.config.zksync.ts", - "local-test-node:zksyncsepolia": "hardhat node-zksync --fork https://sepolia.era.zksync.dev --config hardhat.config.zksync.ts" + "local-test-node:zksyncsepolia": "hardhat node-zksync --fork https://sepolia.era.zksync.dev --config hardhat.config.zksync.ts --tag 0.1.0-alpha.31" }, "dependencies": { "@morpho-labs/gnosis-tx-builder": "^1.3.1", diff --git a/simulations/vip-500/abi/OmnichainProposalSender.json b/simulations/vip-500/abi/OmnichainProposalSender.json new file mode 100644 index 000000000..66fd4df02 --- /dev/null +++ b/simulations/vip-500/abi/OmnichainProposalSender.json @@ -0,0 +1,314 @@ +[ + { + "inputs": [ + { "internalType": "contract ILayerZeroEndpoint", "name": "lzEndpoint_", "type": "address" }, + { "internalType": "address", "name": "accessControlManager_", "type": "address" } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes32", "name": "executionHash", "type": "bytes32" } + ], + "name": "ClearPayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" } + ], + "name": "ExecuteRemoteProposal", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "receiver", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "FallbackWithdraw", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }, + { "indexed": false, "internalType": "uint256", "name": "oldMaxLimit", "type": "uint256" }, + { "indexed": false, "internalType": "uint256", "name": "newMaxLimit", "type": "uint256" } + ], + "name": "SetMaxDailyLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "oldRemoteAddress", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "newRemoteAddress", "type": "bytes" } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "uint256", "name": "proposalId", "type": "uint256" }, + { "indexed": true, "internalType": "uint16", "name": "remoteChainId", "type": "uint16" }, + { "indexed": false, "internalType": "bytes", "name": "payload", "type": "bytes" }, + { "indexed": false, "internalType": "bytes", "name": "adapterParams", "type": "bytes" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }, + { "indexed": false, "internalType": "bytes", "name": "reason", "type": "bytes" } + ], + "name": "StorePayload", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": true, "internalType": "uint16", "name": "chainId", "type": "uint16" }], + "name": "TrustedRemoteRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "LZ_ENDPOINT", + "outputs": [{ "internalType": "contract ILayerZeroEndpoint", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourCommandsSent", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLast24HourWindowStart", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToLastProposalSentTimestamp", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "chainIdToMaxDailyLimit", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bool", "name": "useZro_", "type": "bool" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" } + ], + "name": "estimateFees", + "outputs": [ + { "internalType": "uint256", "name": "", "type": "uint256" }, + { "internalType": "uint256", "name": "", "type": "uint256" } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" } + ], + "name": "execute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to_", "type": "address" }, + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "fallbackWithdraw", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" } + ], + "name": "getConfig", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "proposalCount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }], + "name": "removeTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "uint256", "name": "pId_", "type": "uint256" }, + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "payload_", "type": "bytes" }, + { "internalType": "bytes", "name": "adapterParams_", "type": "bytes" }, + { "internalType": "address", "name": "zroPaymentAddress_", "type": "address" }, + { "internalType": "uint256", "name": "originalValue_", "type": "uint256" } + ], + "name": "retryExecute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "version_", "type": "uint16" }, + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "configType_", "type": "uint256" }, + { "internalType": "bytes", "name": "config_", "type": "bytes" } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "chainId_", "type": "uint16" }, + { "internalType": "uint256", "name": "limit_", "type": "uint256" } + ], + "name": "setMaxDailyLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "version_", "type": "uint16" }], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint16", "name": "remoteChainId_", "type": "uint16" }, + { "internalType": "bytes", "name": "newRemoteAddress_", "type": "bytes" } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "name": "storedExecutionHashes", + "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }], + "name": "trustedRemoteLookup", + "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" } +] diff --git a/simulations/vip-500/abi/XVS.json b/simulations/vip-500/abi/XVS.json new file mode 100644 index 000000000..0835d2fe4 --- /dev/null +++ b/simulations/vip-500/abi/XVS.json @@ -0,0 +1,318 @@ +[ + { + "inputs": [{ "internalType": "address", "name": "accessControlManager_", "type": "address" }], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [{ "internalType": "address", "name": "user", "type": "address" }], + "name": "AccountBlacklisted", + "type": "error" + }, + { "inputs": [], "name": "AddressesMustDiffer", "type": "error" }, + { "inputs": [], "name": "MintLimitExceed", "type": "error" }, + { "inputs": [], "name": "MintedAmountExceed", "type": "error" }, + { "inputs": [], "name": "NewCapNotGreaterThanMintedTokens", "type": "error" }, + { "inputs": [], "name": "Unauthorized", "type": "error" }, + { "inputs": [], "name": "ZeroAddressNotAllowed", "type": "error" }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, + { "indexed": false, "internalType": "bool", "name": "value", "type": "bool" } + ], + "name": "BlacklistUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "MintCapChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newLimit", "type": "uint256" } + ], + "name": "MintLimitDecreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "minter", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "newLimit", "type": "uint256" } + ], + "name": "MintLimitIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "source", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "destination", "type": "address" } + ], + "name": "MintedTokensMigrated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "oldAccessControlManager", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newAccessControlManager", "type": "address" } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, + { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, + { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "owner", "type": "address" }, + { "internalType": "address", "name": "spender", "type": "address" } + ], + "name": "allowance", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "approve", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], + "name": "balanceOf", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "subtractedValue", "type": "uint256" } + ], + "name": "decreaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "spender", "type": "address" }, + { "internalType": "uint256", "name": "addedValue", "type": "uint256" } + ], + "name": "increaseAllowance", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "user_", "type": "address" }], + "name": "isBlackListed", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "source_", "type": "address" }, + { "internalType": "address", "name": "destination_", "type": "address" } + ], + "name": "migrateMinterTokens", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "account_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "minterToCap", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "", "type": "address" }], + "name": "minterToMintedAmount", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [], + "name": "paused", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [{ "internalType": "address", "name": "newAccessControlAddress_", "type": "address" }], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "minter_", "type": "address" }, + { "internalType": "uint256", "name": "amount_", "type": "uint256" } + ], + "name": "setMintCap", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transfer", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "from", "type": "address" }, + { "internalType": "address", "name": "to", "type": "address" }, + { "internalType": "uint256", "name": "amount", "type": "uint256" } + ], + "name": "transferFrom", + "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { "internalType": "address", "name": "user_", "type": "address" }, + { "internalType": "bool", "name": "value_", "type": "bool" } + ], + "name": "updateBlacklist", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-500/abi/XVSBridgeAdmin.json b/simulations/vip-500/abi/XVSBridgeAdmin.json new file mode 100644 index 000000000..36158eeba --- /dev/null +++ b/simulations/vip-500/abi/XVSBridgeAdmin.json @@ -0,0 +1,287 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "XVSBridge_", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "string", + "name": "signature", + "type": "string" + }, + { + "indexed": false, + "internalType": "bool", + "name": "isRemoved", + "type": "bool" + } + ], + "name": "FunctionRegistryChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "inputs": [], + "name": "XVSBridge", + "outputs": [ + { + "internalType": "contract IXVSProxyOFT", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "", + "type": "bytes4" + } + ], + "name": "functionRegistry", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner_", + "type": "address" + } + ], + "name": "transferBridgeOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "string[]", + "name": "signatures_", + "type": "string[]" + }, + { + "internalType": "bool[]", + "name": "remove_", + "type": "bool[]" + } + ], + "name": "upsertSignature", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/simulations/vip-500/abi/XVSProxyOFTSrc.json b/simulations/vip-500/abi/XVSProxyOFTSrc.json new file mode 100644 index 000000000..e88302d59 --- /dev/null +++ b/simulations/vip-500/abi/XVSProxyOFTSrc.json @@ -0,0 +1,1616 @@ +[ + { + "inputs": [], + "name": "ZeroAddressNotAllowed", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint16", + "name": "_srcChainId", + "type": "uint16" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "_srcAddress", + "type": "bytes" + }, + { + "indexed": false, + "internalType": "uint64", + "name": "_nonce", + "type": "uint64" + }, + { + "indexed": false, + "internalType": "bytes32", + "name": "_hash", + "type": "bytes32" + } + ], + "name": "CallOFTReceivedSuccess", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint16", + "name": "_srcChainId", + "type": "uint16" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "_srcAddress", + "type": "bytes" + }, + { + "indexed": false, + "internalType": "uint64", + "name": "_nonce", + "type": "uint64" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "_payload", + "type": "bytes" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "_reason", + "type": "bytes" + } + ], + "name": "MessageFailed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "_address", + "type": "address" + } + ], + "name": "NonContractAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "oldOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOracle", + "type": "address" + } + ], + "name": "OracleChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint16", + "name": "_srcChainId", + "type": "uint16" + }, + { + "indexed": true, + "internalType": "address", + "name": "_to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "_amount", + "type": "uint256" + } + ], + "name": "ReceiveFromChain", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint16", + "name": "_srcChainId", + "type": "uint16" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "_srcAddress", + "type": "bytes" + }, + { + "indexed": false, + "internalType": "uint64", + "name": "_nonce", + "type": "uint64" + }, + { + "indexed": false, + "internalType": "bytes32", + "name": "_payloadHash", + "type": "bytes32" + } + ], + "name": "RetryMessageSuccess", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint16", + "name": "_dstChainId", + "type": "uint16" + }, + { + "indexed": true, + "internalType": "address", + "name": "_from", + "type": "address" + }, + { + "indexed": true, + "internalType": "bytes32", + "name": "_toAddress", + "type": "bytes32" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "_amount", + "type": "uint256" + } + ], + "name": "SendToChain", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint16", + "name": "chainId", + "type": "uint16" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldMaxLimit", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMaxLimit", + "type": "uint256" + } + ], + "name": "SetMaxDailyLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint16", + "name": "chainId", + "type": "uint16" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldMaxLimit", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMaxLimit", + "type": "uint256" + } + ], + "name": "SetMaxDailyReceiveLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint16", + "name": "chainId", + "type": "uint16" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldMaxLimit", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMaxLimit", + "type": "uint256" + } + ], + "name": "SetMaxSingleReceiveTransactionLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint16", + "name": "chainId", + "type": "uint16" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "oldMaxLimit", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newMaxLimit", + "type": "uint256" + } + ], + "name": "SetMaxSingleTransactionLimit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint16", + "name": "_dstChainId", + "type": "uint16" + }, + { + "indexed": false, + "internalType": "uint16", + "name": "_type", + "type": "uint16" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "_minDstGas", + "type": "uint256" + } + ], + "name": "SetMinDstGas", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "precrime", + "type": "address" + } + ], + "name": "SetPrecrime", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint16", + "name": "_remoteChainId", + "type": "uint16" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "_path", + "type": "bytes" + } + ], + "name": "SetTrustedRemote", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint16", + "name": "_remoteChainId", + "type": "uint16" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "_remoteAddress", + "type": "bytes" + } + ], + "name": "SetTrustedRemoteAddress", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "addr", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "isWhitelist", + "type": "bool" + } + ], + "name": "SetWhitelist", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_PAYLOAD_SIZE_LIMIT", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NO_EXTRA_GAS", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "PT_SEND", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "PT_SEND_AND_CALL", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_srcChainId", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "_srcAddress", + "type": "bytes" + }, + { + "internalType": "uint64", + "name": "_nonce", + "type": "uint64" + }, + { + "internalType": "bytes32", + "name": "_from", + "type": "bytes32" + }, + { + "internalType": "address", + "name": "_to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_amount", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "_payload", + "type": "bytes" + }, + { + "internalType": "uint256", + "name": "_gasForCall", + "type": "uint256" + } + ], + "name": "callOnOFTReceived", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "", + "type": "uint16" + } + ], + "name": "chainIdToLast24HourReceiveWindowStart", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "", + "type": "uint16" + } + ], + "name": "chainIdToLast24HourReceived", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "", + "type": "uint16" + } + ], + "name": "chainIdToLast24HourTransferred", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "", + "type": "uint16" + } + ], + "name": "chainIdToLast24HourWindowStart", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "", + "type": "uint16" + } + ], + "name": "chainIdToMaxDailyLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "", + "type": "uint16" + } + ], + "name": "chainIdToMaxDailyReceiveLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "", + "type": "uint16" + } + ], + "name": "chainIdToMaxSingleReceiveTransactionLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "", + "type": "uint16" + } + ], + "name": "chainIdToMaxSingleTransactionLimit", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "circulatingSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "", + "type": "bytes" + }, + { + "internalType": "uint64", + "name": "", + "type": "uint64" + } + ], + "name": "creditedPackets", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_dstChainId", + "type": "uint16" + }, + { + "internalType": "bytes32", + "name": "_toAddress", + "type": "bytes32" + }, + { + "internalType": "uint256", + "name": "_amount", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "_payload", + "type": "bytes" + }, + { + "internalType": "uint64", + "name": "_dstGasForCall", + "type": "uint64" + }, + { + "internalType": "bool", + "name": "_useZro", + "type": "bool" + }, + { + "internalType": "bytes", + "name": "_adapterParams", + "type": "bytes" + } + ], + "name": "estimateSendAndCallFee", + "outputs": [ + { + "internalType": "uint256", + "name": "nativeFee", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "zroFee", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_dstChainId", + "type": "uint16" + }, + { + "internalType": "bytes32", + "name": "_toAddress", + "type": "bytes32" + }, + { + "internalType": "uint256", + "name": "_amount", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "_useZro", + "type": "bool" + }, + { + "internalType": "bytes", + "name": "_adapterParams", + "type": "bytes" + } + ], + "name": "estimateSendFee", + "outputs": [ + { + "internalType": "uint256", + "name": "nativeFee", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "zroFee", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "", + "type": "bytes" + }, + { + "internalType": "uint64", + "name": "", + "type": "uint64" + } + ], + "name": "failedMessages", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_srcChainId", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "_srcAddress", + "type": "bytes" + } + ], + "name": "forceResumeReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_version", + "type": "uint16" + }, + { + "internalType": "uint16", + "name": "_chainId", + "type": "uint16" + }, + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_configType", + "type": "uint256" + } + ], + "name": "getConfig", + "outputs": [ + { + "internalType": "bytes", + "name": "", + "type": "bytes" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_remoteChainId", + "type": "uint16" + } + ], + "name": "getTrustedRemoteAddress", + "outputs": [ + { + "internalType": "bytes", + "name": "", + "type": "bytes" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_srcChainId", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "_srcAddress", + "type": "bytes" + } + ], + "name": "isTrustedRemote", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "lzEndpoint", + "outputs": [ + { + "internalType": "contract ILayerZeroEndpoint", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_srcChainId", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "_srcAddress", + "type": "bytes" + }, + { + "internalType": "uint64", + "name": "_nonce", + "type": "uint64" + }, + { + "internalType": "bytes", + "name": "_payload", + "type": "bytes" + } + ], + "name": "lzReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "", + "type": "uint16" + }, + { + "internalType": "uint16", + "name": "", + "type": "uint16" + } + ], + "name": "minDstGasLookup", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_srcChainId", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "_srcAddress", + "type": "bytes" + }, + { + "internalType": "uint64", + "name": "_nonce", + "type": "uint64" + }, + { + "internalType": "bytes", + "name": "_payload", + "type": "bytes" + } + ], + "name": "nonblockingLzReceive", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "oracle", + "outputs": [ + { + "internalType": "contract ResilientOracleInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "", + "type": "uint16" + } + ], + "name": "payloadSizeLimitLookup", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "precrime", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_srcChainId", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "_srcAddress", + "type": "bytes" + }, + { + "internalType": "uint64", + "name": "_nonce", + "type": "uint64" + }, + { + "internalType": "bytes", + "name": "_payload", + "type": "bytes" + } + ], + "name": "retryMessage", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_from", + "type": "address" + }, + { + "internalType": "uint16", + "name": "_dstChainId", + "type": "uint16" + }, + { + "internalType": "bytes32", + "name": "_toAddress", + "type": "bytes32" + }, + { + "internalType": "uint256", + "name": "_amount", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "_payload", + "type": "bytes" + }, + { + "internalType": "uint64", + "name": "_dstGasForCall", + "type": "uint64" + }, + { + "components": [ + { + "internalType": "address payable", + "name": "refundAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "zroPaymentAddress", + "type": "address" + }, + { + "internalType": "bytes", + "name": "adapterParams", + "type": "bytes" + } + ], + "internalType": "struct ICommonOFT.LzCallParams", + "name": "_callParams", + "type": "tuple" + } + ], + "name": "sendAndCall", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_from", + "type": "address" + }, + { + "internalType": "uint16", + "name": "_dstChainId", + "type": "uint16" + }, + { + "internalType": "bytes32", + "name": "_toAddress", + "type": "bytes32" + }, + { + "internalType": "uint256", + "name": "_amount", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "address payable", + "name": "refundAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "zroPaymentAddress", + "type": "address" + }, + { + "internalType": "bytes", + "name": "adapterParams", + "type": "bytes" + } + ], + "internalType": "struct ICommonOFT.LzCallParams", + "name": "_callParams", + "type": "tuple" + } + ], + "name": "sendFrom", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_version", + "type": "uint16" + }, + { + "internalType": "uint16", + "name": "_chainId", + "type": "uint16" + }, + { + "internalType": "uint256", + "name": "_configType", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "_config", + "type": "bytes" + } + ], + "name": "setConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "chainId_", + "type": "uint16" + }, + { + "internalType": "uint256", + "name": "limit_", + "type": "uint256" + } + ], + "name": "setMaxDailyLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "chainId_", + "type": "uint16" + }, + { + "internalType": "uint256", + "name": "limit_", + "type": "uint256" + } + ], + "name": "setMaxDailyReceiveLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "chainId_", + "type": "uint16" + }, + { + "internalType": "uint256", + "name": "limit_", + "type": "uint256" + } + ], + "name": "setMaxSingleReceiveTransactionLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "chainId_", + "type": "uint16" + }, + { + "internalType": "uint256", + "name": "limit_", + "type": "uint256" + } + ], + "name": "setMaxSingleTransactionLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_dstChainId", + "type": "uint16" + }, + { + "internalType": "uint16", + "name": "_packetType", + "type": "uint16" + }, + { + "internalType": "uint256", + "name": "_minGas", + "type": "uint256" + } + ], + "name": "setMinDstGas", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "oracleAddress_", + "type": "address" + } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_dstChainId", + "type": "uint16" + }, + { + "internalType": "uint256", + "name": "_size", + "type": "uint256" + } + ], + "name": "setPayloadSizeLimit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_precrime", + "type": "address" + } + ], + "name": "setPrecrime", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_version", + "type": "uint16" + } + ], + "name": "setReceiveVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_version", + "type": "uint16" + } + ], + "name": "setSendVersion", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_remoteChainId", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "_path", + "type": "bytes" + } + ], + "name": "setTrustedRemote", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "_remoteChainId", + "type": "uint16" + }, + { + "internalType": "bytes", + "name": "_remoteAddress", + "type": "bytes" + } + ], + "name": "setTrustedRemoteAddress", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user_", + "type": "address" + }, + { + "internalType": "bool", + "name": "val_", + "type": "bool" + } + ], + "name": "setWhitelist", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "sharedDecimals", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "interfaceId", + "type": "bytes4" + } + ], + "name": "supportsInterface", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "token", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint16", + "name": "", + "type": "uint16" + } + ], + "name": "trustedRemoteLookup", + "outputs": [ + { + "internalType": "bytes", + "name": "", + "type": "bytes" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "whitelist", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-500/abi/resilientOracle.json b/simulations/vip-500/abi/resilientOracle.json new file mode 100644 index 000000000..35f52caa0 --- /dev/null +++ b/simulations/vip-500/abi/resilientOracle.json @@ -0,0 +1,640 @@ +[ + { + "inputs": [ + { + "internalType": "address", + "name": "nativeMarketAddress", + "type": "address" + }, + { + "internalType": "address", + "name": "vaiAddress", + "type": "address" + }, + { + "internalType": "contract BoundValidatorInterface", + "name": "_boundValidator", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "calledContract", + "type": "address" + }, + { + "internalType": "string", + "name": "methodSignature", + "type": "string" + } + ], + "name": "Unauthorized", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "oldAccessControlManager", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAccessControlManager", + "type": "address" + } + ], + "name": "NewAccessControlManager", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "OracleEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "role", + "type": "uint256" + } + ], + "name": "OracleSet", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferStarted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Paused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "mainOracle", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "pivotOracle", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "fallbackOracle", + "type": "address" + } + ], + "name": "TokenConfigAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "Unpaused", + "type": "event" + }, + { + "inputs": [], + "name": "INVALID_PRICE", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "NATIVE_TOKEN_ADDR", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "acceptOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "accessControlManager", + "outputs": [ + { + "internalType": "contract IAccessControlManagerV8", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "boundValidator", + "outputs": [ + { + "internalType": "contract BoundValidatorInterface", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + }, + { + "internalType": "bool", + "name": "enable", + "type": "bool" + } + ], + "name": "enableOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "getOracle", + "outputs": [ + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "bool", + "name": "enabled", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "getTokenConfig", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "getUnderlyingPrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "nativeMarket", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "paused", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "pendingOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "accessControlManager_", + "type": "address" + } + ], + "name": "setAccessControlManager", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address", + "name": "oracle", + "type": "address" + }, + { + "internalType": "enum ResilientOracle.OracleRole", + "name": "role", + "type": "uint8" + } + ], + "name": "setOracle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig", + "name": "tokenConfig", + "type": "tuple" + } + ], + "name": "setTokenConfig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + }, + { + "internalType": "address[3]", + "name": "oracles", + "type": "address[3]" + }, + { + "internalType": "bool[3]", + "name": "enableFlagsForOracles", + "type": "bool[3]" + } + ], + "internalType": "struct ResilientOracle.TokenConfig[]", + "name": "tokenConfigs_", + "type": "tuple[]" + } + ], + "name": "setTokenConfigs", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "unpause", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "asset", + "type": "address" + } + ], + "name": "updateAssetPrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "vToken", + "type": "address" + } + ], + "name": "updatePrice", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "vai", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/simulations/vip-500/arbitrumsepolia.ts b/simulations/vip-500/arbitrumsepolia.ts new file mode 100644 index 000000000..3ebaa0b68 --- /dev/null +++ b/simulations/vip-500/arbitrumsepolia.ts @@ -0,0 +1,19 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId } from "src/types"; +import { forking } from "src/vip-framework"; + +import vip500, { BASE_SEPOLIA_TRUSTED_REMOTE, MIN_DST_GAS, remoteBridgeEntries } from "../../vips/vip-500/bsctestnet"; +import { RemoteBridgeEntry } from "../../vips/vip-500/types"; +import { checkXVSBridge } from "./checkXVSBridge"; + +forking(99339753, async () => { + await checkXVSBridge( + LzChainId.arbitrumsepolia, + LzChainId.basesepolia, + NETWORK_ADDRESSES.arbitrumsepolia, + vip500, + BASE_SEPOLIA_TRUSTED_REMOTE, + remoteBridgeEntries.find(entry => entry.dstChainId === LzChainId.arbitrumsepolia) as RemoteBridgeEntry, + MIN_DST_GAS, + ); +}); diff --git a/simulations/vip-500/bsctestnet.ts b/simulations/vip-500/bsctestnet.ts new file mode 100644 index 000000000..c7b83a30b --- /dev/null +++ b/simulations/vip-500/bsctestnet.ts @@ -0,0 +1,189 @@ +import { TransactionResponse } from "@ethersproject/providers"; +import { SignerWithAddress } from "@nomiclabs/hardhat-ethers/signers"; +import { expect } from "chai"; +import { Contract } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId } from "src/types"; +import { expectEvents, initMainnetUser } from "src/utils"; +import { forking, testVip } from "src/vip-framework"; + +import vip500, { BASE_SEPOLIA_TRUSTED_REMOTE, MIN_DST_GAS, remoteBridgeEntries } from "../../vips/vip-500/bsctestnet"; +import { RemoteBridgeEntry } from "../../vips/vip-500/types"; +import OMNICHAIN_PROPOSAL_SENDER_ABI from "./abi/OmnichainProposalSender.json"; +import XVS_ABI from "./abi/XVS.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/XVSBridgeAdmin.json"; +import XVS_BRIDGE_SRC_ABI from "./abi/XVSProxyOFTSrc.json"; + +const { bsctestnet } = NETWORK_ADDRESSES; + +const XVSProxyOFTSrc = "0x0E132cd94fd70298b747d2b4D977db8d086e5fD0"; +const XVS_HOLDER = "0x2Ce1d0ffD7E869D9DF33e28552b12DdDed326706"; + +forking(45828866, async () => { + const provider = ethers.provider; + let bridge: Contract; + let xvs: Contract; + let xvsHolderSigner: SignerWithAddress; + let receiver: SignerWithAddress; + let receiverAddressBytes32: string; + let defaultAdapterParams: string; + + beforeEach(async () => { + bridge = new ethers.Contract(XVSProxyOFTSrc, XVS_BRIDGE_SRC_ABI, provider); + xvs = new ethers.Contract(bsctestnet.XVS, XVS_ABI, provider); + xvsHolderSigner = await initMainnetUser(XVS_HOLDER, ethers.utils.parseEther("2")); + [receiver] = await ethers.getSigners(); + receiverAddressBytes32 = ethers.utils.defaultAbiCoder.encode(["address"], [receiver.address]); + defaultAdapterParams = ethers.utils.solidityPack(["uint16", "uint256"], [1, 300000]); + }); + + testVip("vip-500 testnet", await vip500(), { + callbackAfterExecution: async (txResponse: TransactionResponse) => { + await expectEvents( + txResponse, + [XVS_BRIDGE_ADMIN_ABI, XVS_BRIDGE_SRC_ABI], + [ + "SetMinDstGas", + "SetMaxSingleTransactionLimit", + "SetMaxDailyLimit", + "SetMaxSingleReceiveTransactionLimit", + "SetMaxDailyReceiveLimit", + "SetTrustedRemoteAddress", + "Failure", + ], + [1, 1, 1, 1, 1, 1, 0], + ); + await expectEvents( + txResponse, + [OMNICHAIN_PROPOSAL_SENDER_ABI], + ["ExecuteRemoteProposal", "StorePayload"], + [5, 0], + ); + }, + }); + + describe("Post-VIP behavior", () => { + it("Should match trusted remote address", async () => { + expect(await bridge.getTrustedRemoteAddress(LzChainId.basesepolia)).to.equal( + BASE_SEPOLIA_TRUSTED_REMOTE.toLowerCase(), + ); + }); + + it("Should match minDestGas value", async () => { + expect(await bridge.minDstGasLookup(LzChainId.basesepolia, 0)).to.equal(MIN_DST_GAS); + }); + + describe("Limits", () => { + let remoteBridgeEntry: RemoteBridgeEntry; + + before(() => { + remoteBridgeEntry = remoteBridgeEntries.find(entry => !entry.dstChainId) as RemoteBridgeEntry; + }); + + it("Should match single send transaction limit", async () => { + expect(await bridge.chainIdToMaxSingleTransactionLimit(LzChainId.basesepolia)).to.equal( + remoteBridgeEntry.maxSingleTransactionLimit, + ); + }); + + it("Should match single receive transaction limit", async () => { + expect(await bridge.chainIdToMaxSingleReceiveTransactionLimit(LzChainId.basesepolia)).to.equal( + remoteBridgeEntry.maxSingleReceiveTransactionLimit, + ); + }); + + it("Should match max daily send limit", async () => { + expect(await bridge.chainIdToMaxDailyLimit(LzChainId.basesepolia)).to.equal(remoteBridgeEntry.maxDailyLimit); + }); + + it("Should match max daily receive limit", async () => { + expect(await bridge.chainIdToMaxDailyReceiveLimit(LzChainId.basesepolia)).to.equal( + remoteBridgeEntry.maxDailyReceiveLimit, + ); + }); + }); + + it("Should emit an event on successfull bridging of XVS", async () => { + const amount = parseUnits("0.5", 18); + const nativeFee = ( + await bridge.estimateSendFee(LzChainId.basesepolia, receiverAddressBytes32, amount, false, defaultAdapterParams) + ).nativeFee; + + await xvs.connect(xvsHolderSigner).approve(bridge.address, amount); + const bridgeBalPrev = await xvs.balanceOf(XVSProxyOFTSrc); + await expect( + bridge + .connect(xvsHolderSigner) + .sendFrom( + xvsHolderSigner.address, + LzChainId.basesepolia, + receiverAddressBytes32, + amount, + [xvsHolderSigner.address, ethers.constants.AddressZero, defaultAdapterParams], + { value: nativeFee }, + ), + ) + .to.be.emit(bridge, "SendToChain") + .withArgs(LzChainId.basesepolia, XVS_HOLDER, receiverAddressBytes32, amount); + const bridgeBalAfter = await xvs.balanceOf(XVSProxyOFTSrc); + + expect(bridgeBalAfter.sub(bridgeBalPrev)).to.equal(amount); + }); + + it("Reverts if single transaction limit exceed", async function () { + const amount = ethers.utils.parseUnits("10000", 18); + await xvs.connect(xvsHolderSigner).approve(bridge.address, amount); + + const nativeFee = ( + await bridge.estimateSendFee(LzChainId.basesepolia, receiverAddressBytes32, amount, false, defaultAdapterParams) + ).nativeFee; + await expect( + bridge + .connect(xvsHolderSigner) + .sendFrom( + xvsHolderSigner.address, + LzChainId.basesepolia, + receiverAddressBytes32, + amount, + [xvsHolderSigner.address, ethers.constants.AddressZero, defaultAdapterParams], + { value: nativeFee }, + ), + ).to.be.revertedWith("Single Transaction Limit Exceed"); + }); + + it("Reverts if max daily transaction limit exceed", async function () { + const amount = parseUnits("2500", 18); + await xvs.connect(xvsHolderSigner).approve(bridge.address, ethers.constants.MaxUint256); // Let's approve enough XVS + const nativeFee = ( + await bridge.estimateSendFee(LzChainId.basesepolia, receiverAddressBytes32, amount, false, defaultAdapterParams) + ).nativeFee; + + for (let i = 0; i < 5; i++) { + await bridge + .connect(xvsHolderSigner) + .sendFrom( + xvsHolderSigner.address, + LzChainId.basesepolia, + receiverAddressBytes32, + amount, + [xvsHolderSigner.address, ethers.constants.AddressZero, defaultAdapterParams], + { value: nativeFee }, + ); + } + await expect( + bridge + .connect(xvsHolderSigner) + .sendFrom( + xvsHolderSigner.address, + LzChainId.basesepolia, + receiverAddressBytes32, + amount, + [xvsHolderSigner.address, ethers.constants.AddressZero, defaultAdapterParams], + { value: nativeFee }, + ), + ).to.be.revertedWith("Daily Transaction Limit Exceed"); + }); + }); +}); diff --git a/simulations/vip-500/checkXVSBridge.ts b/simulations/vip-500/checkXVSBridge.ts new file mode 100644 index 000000000..eec185a9e --- /dev/null +++ b/simulations/vip-500/checkXVSBridge.ts @@ -0,0 +1,192 @@ +import { impersonateAccount, setBalance } from "@nomicfoundation/hardhat-network-helpers"; +import { SignerWithAddress } from "@nomiclabs/hardhat-ethers/signers"; +import { expect } from "chai"; +import { Contract } from "ethers"; +import { parseUnits } from "ethers/lib/utils"; +import { ethers } from "hardhat"; +import { Proposal } from "src/types"; +import { expectEvents, initMainnetUser } from "src/utils"; +import { testForkedNetworkVipCommands } from "src/vip-framework"; + +import { RemoteBridgeEntry } from "../../vips/vip-500/types"; +import XVS_ABI from "./abi/XVS.json"; +import XVS_BRIDGE_ADMIN_ABI from "./abi/XVSBridgeAdmin.json"; +import XVS_BRIDGE_SRC_ABI from "./abi/XVSProxyOFTSrc.json"; +import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; + +const XVS_HOLDER = "0x000000000000000000000000000000000000dEaD"; + +export async function checkXVSBridge( + forkedLzChainId: number | undefined, + remoteLzChainId: number | undefined, + networkAddresses: { [key: string]: any }, + vip: () => Promise, + trustedRemote: string, + bridgeConfiguration: RemoteBridgeEntry, + minDstGas: string, +) { + const provider = ethers.provider; + let resilientOracle: Contract; + let bridge: Contract; + let xvs: Contract; + let xvsHolderSigner: SignerWithAddress; + let receiver: SignerWithAddress; + let receiverAddressBytes32: string; + let defaultAdapterParams: string; + + beforeEach(async () => { + bridge = new ethers.Contract(bridgeConfiguration.proxyOFT, XVS_BRIDGE_SRC_ABI, provider); + xvsHolderSigner = await initMainnetUser(XVS_HOLDER, ethers.utils.parseEther("2")); + [receiver] = await ethers.getSigners(); + receiverAddressBytes32 = ethers.utils.defaultAbiCoder.encode(["address"], [receiver.address]); + defaultAdapterParams = ethers.utils.solidityPack(["uint16", "uint256"], [1, 300000]); + resilientOracle = new ethers.Contract(networkAddresses.RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); + + // Let's fund the XVS_HOLDER wallet with some XVS tokens + await impersonateAccount(bridge.address); + await setBalance(bridge.address, parseUnits("1", 18)); + xvs = new ethers.Contract(networkAddresses.XVS, XVS_ABI, await ethers.getSigner(bridge.address)); + await xvs.mint(XVS_HOLDER, parseUnits("10000", 18)); + }); + + testForkedNetworkVipCommands("VIP", await vip(), { + callbackAfterExecution: async txResponse => { + await expectEvents( + txResponse, + [XVS_BRIDGE_ADMIN_ABI, XVS_BRIDGE_SRC_ABI], + [ + "SetMinDstGas", + "SetMaxSingleTransactionLimit", + "SetMaxDailyLimit", + "SetMaxSingleReceiveTransactionLimit", + "SetMaxDailyReceiveLimit", + "SetTrustedRemoteAddress", + "Failure", + ], + [1, 1, 1, 1, 1, 1, 0], + ); + }, + }); + + describe("Post-VIP behavior", () => { + it("Should match trusted remote address", async () => { + expect(await bridge.getTrustedRemoteAddress(remoteLzChainId)).to.equal(trustedRemote.toLowerCase()); + }); + + it("Should match minDestGas value", async () => { + expect(await bridge.minDstGasLookup(remoteLzChainId, 0)).to.equal(minDstGas); + }); + + describe("Limits", () => { + it("Should match single send transaction limit", async () => { + expect(await bridge.chainIdToMaxSingleTransactionLimit(remoteLzChainId)).to.equal( + bridgeConfiguration.maxSingleTransactionLimit, + ); + }); + + it("Should match single receive transaction limit", async () => { + expect(await bridge.chainIdToMaxSingleReceiveTransactionLimit(remoteLzChainId)).to.equal( + bridgeConfiguration.maxSingleReceiveTransactionLimit, + ); + }); + + it("Should match max daily send limit", async () => { + expect(await bridge.chainIdToMaxDailyLimit(remoteLzChainId)).to.equal(bridgeConfiguration.maxDailyLimit); + }); + + it("Should match max daily receive limit", async () => { + expect(await bridge.chainIdToMaxDailyReceiveLimit(remoteLzChainId)).to.equal( + bridgeConfiguration.maxDailyReceiveLimit, + ); + }); + }); + + it("Should emit an event on successfull bridging of XVS", async () => { + const amount = parseUnits("0.5", 18); + const nativeFee = ( + await bridge.estimateSendFee(remoteLzChainId, receiverAddressBytes32, amount, false, defaultAdapterParams) + ).nativeFee; + + await xvs.connect(xvsHolderSigner).approve(bridge.address, amount); + await expect( + bridge + .connect(xvsHolderSigner) + .sendFrom( + XVS_HOLDER, + remoteLzChainId, + receiverAddressBytes32, + amount, + [XVS_HOLDER, ethers.constants.AddressZero, defaultAdapterParams], + { value: nativeFee }, + ), + ) + .to.be.emit(bridge, "SendToChain") + .withArgs(remoteLzChainId, XVS_HOLDER, receiverAddressBytes32, amount); + }); + + it("Reverts if single transaction limit exceed", async function () { + const amount = ethers.utils.parseUnits("10000", 18); + await xvs.connect(xvsHolderSigner).approve(bridge.address, amount); + + const nativeFee = ( + await bridge.estimateSendFee(remoteLzChainId, receiverAddressBytes32, amount, false, defaultAdapterParams) + ).nativeFee; + await expect( + bridge + .connect(xvsHolderSigner) + .sendFrom( + XVS_HOLDER, + remoteLzChainId, + receiverAddressBytes32, + amount, + [XVS_HOLDER, ethers.constants.AddressZero, defaultAdapterParams], + { value: nativeFee }, + ), + ).to.be.revertedWith("Single Transaction Limit Exceed"); + }); + + it("Reverts if max daily transaction limit exceed", async function () { + const xvsPrice = await resilientOracle.getPrice(networkAddresses.XVS); + const singleTransactionLimit = await bridge.chainIdToMaxSingleTransactionLimit(remoteLzChainId); + const dailyTransactionLimit = await bridge.chainIdToMaxDailyLimit(remoteLzChainId); + const safeTransactionAmount = parseUnits(singleTransactionLimit.div(xvsPrice).sub(1).toString(), 18); + const safeTransactionOcurrencies = dailyTransactionLimit.div(singleTransactionLimit); + + await xvs.connect(xvsHolderSigner).approve(bridge.address, ethers.constants.MaxUint256); // Let's approve enough XVS + const nativeFee = ( + await bridge.estimateSendFee( + remoteLzChainId, + receiverAddressBytes32, + safeTransactionAmount, + false, + defaultAdapterParams, + ) + ).nativeFee; + + for (let i = 0; i < safeTransactionOcurrencies; i++) { + await bridge + .connect(xvsHolderSigner) + .sendFrom( + XVS_HOLDER, + remoteLzChainId, + receiverAddressBytes32, + safeTransactionAmount, + [XVS_HOLDER, ethers.constants.AddressZero, defaultAdapterParams], + { value: nativeFee }, + ); + } + await expect( + bridge + .connect(xvsHolderSigner) + .sendFrom( + XVS_HOLDER, + remoteLzChainId, + receiverAddressBytes32, + safeTransactionAmount, + [XVS_HOLDER, ethers.constants.AddressZero, defaultAdapterParams], + { value: nativeFee }, + ), + ).to.be.revertedWith("Daily Transaction Limit Exceed"); + }); + }); +} diff --git a/simulations/vip-500/opbnbtestnet.ts b/simulations/vip-500/opbnbtestnet.ts new file mode 100644 index 000000000..aaedec7a0 --- /dev/null +++ b/simulations/vip-500/opbnbtestnet.ts @@ -0,0 +1,19 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId } from "src/types"; +import { forking } from "src/vip-framework"; + +import vip500, { BASE_SEPOLIA_TRUSTED_REMOTE, MIN_DST_GAS, remoteBridgeEntries } from "../../vips/vip-500/bsctestnet"; +import { RemoteBridgeEntry } from "../../vips/vip-500/types"; +import { checkXVSBridge } from "./checkXVSBridge"; + +forking(45337620, async () => { + await checkXVSBridge( + LzChainId.opbnbtestnet, + LzChainId.basesepolia, + NETWORK_ADDRESSES.opbnbtestnet, + vip500, + BASE_SEPOLIA_TRUSTED_REMOTE, + remoteBridgeEntries.find(entry => entry.dstChainId === LzChainId.opbnbtestnet) as RemoteBridgeEntry, + MIN_DST_GAS, + ); +}); diff --git a/simulations/vip-500/opsepolia.ts b/simulations/vip-500/opsepolia.ts new file mode 100644 index 000000000..dbbac9b6e --- /dev/null +++ b/simulations/vip-500/opsepolia.ts @@ -0,0 +1,19 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId } from "src/types"; +import { forking } from "src/vip-framework"; + +import vip500, { BASE_SEPOLIA_TRUSTED_REMOTE, MIN_DST_GAS, remoteBridgeEntries } from "../../vips/vip-500/bsctestnet"; +import { RemoteBridgeEntry } from "../../vips/vip-500/types"; +import { checkXVSBridge } from "./checkXVSBridge"; + +forking(20553060, async () => { + await checkXVSBridge( + LzChainId.opsepolia, + LzChainId.basesepolia, + NETWORK_ADDRESSES.opsepolia, + vip500, + BASE_SEPOLIA_TRUSTED_REMOTE, + remoteBridgeEntries.find(entry => entry.dstChainId === LzChainId.opsepolia) as RemoteBridgeEntry, + MIN_DST_GAS, + ); +}); diff --git a/simulations/vip-500/sepolia.ts b/simulations/vip-500/sepolia.ts new file mode 100644 index 000000000..9d19fda58 --- /dev/null +++ b/simulations/vip-500/sepolia.ts @@ -0,0 +1,19 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId } from "src/types"; +import { forking } from "src/vip-framework"; + +import vip500, { BASE_SEPOLIA_TRUSTED_REMOTE, MIN_DST_GAS, remoteBridgeEntries } from "../../vips/vip-500/bsctestnet"; +import { RemoteBridgeEntry } from "../../vips/vip-500/types"; +import { checkXVSBridge } from "./checkXVSBridge"; + +forking(7124205, async () => { + await checkXVSBridge( + LzChainId.sepolia, + LzChainId.basesepolia, + NETWORK_ADDRESSES.sepolia, + vip500, + BASE_SEPOLIA_TRUSTED_REMOTE, + remoteBridgeEntries.find(entry => entry.dstChainId === LzChainId.sepolia) as RemoteBridgeEntry, + MIN_DST_GAS, + ); +}); diff --git a/simulations/vip-500/zksyncsepolia.ts b/simulations/vip-500/zksyncsepolia.ts new file mode 100644 index 000000000..8b05a0f8f --- /dev/null +++ b/simulations/vip-500/zksyncsepolia.ts @@ -0,0 +1,19 @@ +import { NETWORK_ADDRESSES } from "src/networkAddresses"; +import { LzChainId } from "src/types"; +import { forking } from "src/vip-framework"; + +import vip500, { BASE_SEPOLIA_TRUSTED_REMOTE, MIN_DST_GAS, remoteBridgeEntries } from "../../vips/vip-500/bsctestnet"; +import { RemoteBridgeEntry } from "../../vips/vip-500/types"; +import { checkXVSBridge } from "./checkXVSBridge"; + +forking(4245630, async () => { + await checkXVSBridge( + LzChainId.zksyncsepolia, + LzChainId.basesepolia, + NETWORK_ADDRESSES.zksyncsepolia, + vip500, + BASE_SEPOLIA_TRUSTED_REMOTE, + remoteBridgeEntries.find(entry => entry.dstChainId === LzChainId.zksyncsepolia) as RemoteBridgeEntry, + MIN_DST_GAS, + ); +}); diff --git a/src/networkAddresses.ts b/src/networkAddresses.ts index 398e74070..269d508b2 100644 --- a/src/networkAddresses.ts +++ b/src/networkAddresses.ts @@ -164,7 +164,7 @@ export const NETWORK_ADDRESSES = { OMNICHAIN_GOVERNANCE_EXECUTOR: "0xc1858cCE6c28295Efd3eE742795bDa316D7c7526", }, zksyncsepolia: { - NORMAL_TIMELOCK: "", // To be deployed + NORMAL_TIMELOCK: "0x1730527a0f0930269313D77A317361b42971a67E", GUARDIAN: "0xa2f83de95E9F28eD443132C331B6a9C9B7a9F866", GENERIC_TEST_USER_ACCOUNT: "0x6f057A858171e187124ddEDF034dAc63De5dE5dB", RESILIENT_ORACLE: "0x748853B3bE26c46b4562Fd314dfb82708F395bDf", @@ -173,9 +173,12 @@ export const NETWORK_ADDRESSES = { XVS_VAULT_PROXY: "0x825f9EE3b2b1C159a5444A111A70607f3918564e", POOL_REGISTRY: "0x1401404e6279BB8C06E5E3999eCA3e2008B46A76", VTREASURY: "0x943eBE4460a12F551D60A68f510Ea10CD8d564BA", + ENDPOINT: "0x99b6359ce8E0eBdC27eBeDb76FE28F29303E78fF", + LZ_LIBRARY: "0xC6d12200b743A8F7e6b7228B8E920A71d94FA7Fb", + OMNICHAIN_GOVERNANCE_EXECUTOR: "0x83F79CfbaEee738173c0dfd866796743F4E25C9e", }, zksyncmainnet: { - NORMAL_TIMELOCK: "", // To be deployed + NORMAL_TIMELOCK: "0x093565Bc20AA326F4209eBaF3a26089272627613", GUARDIAN: "0x751Aa759cfBB6CE71A43b48e40e1cCcFC66Ba4aa", VTREASURY: "0xB2e9174e23382f7744CebF7e0Be54cA001D95599", XVS: "0xD78ABD81a3D57712a3af080dc4185b698Fe9ac5A", @@ -184,9 +187,12 @@ export const NETWORK_ADDRESSES = { POOL_REGISTRY: "0xFD96B926298034aed9bBe0Cca4b651E41eB87Bc4", XVS_VAULT_PROXY: "0xbbB3C88192a5B0DB759229BeF49DcD1f168F326F", GENERIC_TEST_USER_ACCOUNT: "0x6f057A858171e187124ddEDF034dAc63De5dE5dB", + ENDPOINT: "0x9b896c0e23220469C7AE69cb4BbAE391eAa4C8da", + LZ_LIBRARY: "0x042b8289c97896529Ec2FE49ba1A8B9C956A86cC", + OMNICHAIN_GOVERNANCE_EXECUTOR: "0xA1b56f19CA5E5b15EF29d38238930Ce9f0235312", }, opsepolia: { - NORMAL_TIMELOCK: "", // To be deployed + NORMAL_TIMELOCK: "0xdDe31d7eEEAD7Cf9790F833C4FF4c6e61404402a", VTREASURY: "0x5A1a12F47FA7007C9e23cf5e025F3f5d3aC7d755", GUARDIAN: "0xd57365EE4E850e881229e2F8Aa405822f289e78d", XVS_VAULT_PROXY: "0x4d344e48F02234E82D7D1dB84d0A4A18Aa43Dacc", @@ -195,9 +201,12 @@ export const NETWORK_ADDRESSES = { RESILIENT_ORACLE: "0x6c01ECa2B5C97F135406a3A5531445A7d977D28e", CHAINLINK_ORACLE: "0x493C3f543AEa37EefF17D823f27Cb1feAB9f3143", POOL_REGISTRY: "0x6538C861C7A6997602311342657b9143dD9E8152", + ENDPOINT: "0x55370E0fBB5f5b8dAeD978BA1c075a499eB107B8", + LZ_LIBRARY: "0x35AdD9321507A87471a11EBd4aE4f592d531e620", + OMNICHAIN_GOVERNANCE_EXECUTOR: "0xC7D6D33adcdBfccD416C3aAB1878360ea8b79ac6", }, opmainnet: { - NORMAL_TIMELOCK: "", // To be deployed + NORMAL_TIMELOCK: "0x0C6f1E6B4fDa846f63A0d5a8a73EB811E0e0C04b", VTREASURY: "0x104c01EB7b4664551BE6A9bdB26a8C5c6Be7d3da", GUARDIAN: "0x2e94dd14E81999CdBF5deDE31938beD7308354b3", RESILIENT_ORACLE: "0x21FC48569bd3a6623281f55FC1F8B48B9386907b", @@ -207,6 +216,9 @@ export const NETWORK_ADDRESSES = { XVS_VAULT_PROXY: "0x133120607C018c949E91AE333785519F6d947e01", GENERIC_TEST_USER_ACCOUNT: "0x6f057A858171e187124ddEDF034dAc63De5dE5dB", POOL_REGISTRY: "0x147780799840d541C1d7c998F0cbA996d11D62bb", + ENDPOINT: "0x3c2269811836af69497E5F486A85D7316753cf62", + LZ_LIBRARY: "0x4D73AdB72bC3DD368966edD0f0b2148401A178E2", + OMNICHAIN_GOVERNANCE_EXECUTOR: "0x09b11b1CAdC08E239970A8993783f0f8EeC60ABf", }, basesepolia: { GUARDIAN: "0xdf3b635d2b535f906BB02abb22AED71346E36a00", @@ -214,5 +226,7 @@ export const NETWORK_ADDRESSES = { RESILIENT_ORACLE: "0xC34871C982cf0Bc6e7aCa2c2670Bc319bDA1C744", CHAINLINK_ORACLE: "0x801aB33A69AD867500fbCda7b3dB66C73151494b", REDSTONE_ORACLE: "0x8267FE3f75E0A37ee34e113E767F9C9727206838", + ENDPOINT: "0x55370E0fBB5f5b8dAeD978BA1c075a499eB107B8", + LZ_LIBRARY: "0x35AdD9321507A87471a11EBd4aE4f592d531e620", }, }; diff --git a/src/types.ts b/src/types.ts index 0e50a3aff..664749a47 100644 --- a/src/types.ts +++ b/src/types.ts @@ -7,7 +7,8 @@ export type SUPPORTED_NETWORKS = | "ethereum" | "opbnbtestnet" | "opbnbmainnet" - | "zksyncsepolia"; + | "zksyncsepolia" + | "basesepolia"; export type REMOTE_NETWORKS = | "sepolia" @@ -17,8 +18,15 @@ export type REMOTE_NETWORKS = | "arbitrumsepolia" | "arbitrumone"; -export const REMOTE_TESTNET_NETWORKS = ["sepolia", "opbnbtestnet", "arbitrumsepolia", "zksyncsepolia"]; -export const REMOTE_MAINNET_NETWORKS = ["ethereum", "opbnbmainnet", "arbitrumone", "zksyncmainnet"]; +export const REMOTE_TESTNET_NETWORKS = [ + "sepolia", + "opbnbtestnet", + "arbitrumsepolia", + "zksyncsepolia", + "opsepolia", + "basesepolia", +]; +export const REMOTE_MAINNET_NETWORKS = ["ethereum", "opbnbmainnet", "arbitrumone", "zksyncmainnet", "opmainnet"]; export interface ProposalMeta { version: string; title: string; @@ -78,4 +86,5 @@ export enum LzChainId { zksyncmainnet = 165, opsepolia = 10232, opmainnet = 111, + basesepolia = 10245, } diff --git a/vips/vip-500/bsctestnet.ts b/vips/vip-500/bsctestnet.ts new file mode 100644 index 000000000..8db8016f4 --- /dev/null +++ b/vips/vip-500/bsctestnet.ts @@ -0,0 +1,122 @@ +import { parseUnits } from "ethers/lib/utils"; + +import { LzChainId, ProposalType } from "../../src/types"; +import { makeProposal } from "../../src/utils"; +import { RemoteBridgeCommand, RemoteBridgeEntry } from "./types"; + +export const BASE_SEPOLIA_TRUSTED_REMOTE = "0xD5Cd1fD17B724a391C1bce55Eb9d88E3205eED60"; + +export const MIN_DST_GAS = "300000"; + +export const remoteBridgeEntries: RemoteBridgeEntry[] = [ + { + bridgeAdmin: "0xB164Cb262328Ca44a806bA9e3d4094931E658513", + proxyOFT: "0x0E132cd94fd70298b747d2b4D977db8d086e5fD0", + dstChainId: undefined, + maxDailyLimit: parseUnits("100000", 18), + maxSingleTransactionLimit: parseUnits("20000", 18), + maxDailyReceiveLimit: parseUnits("102000", 18), + maxSingleReceiveTransactionLimit: parseUnits("20400", 18), + }, + { + bridgeAdmin: "0xd3c6bdeeadB2359F726aD4cF42EAa8B7102DAd9B", + proxyOFT: "0xc340b7d3406502F43dC11a988E4EC5bbE536E642", + dstChainId: LzChainId.sepolia, + maxDailyLimit: parseUnits("100000", 18), + maxSingleTransactionLimit: parseUnits("20000", 18), + maxDailyReceiveLimit: parseUnits("102000", 18), + maxSingleReceiveTransactionLimit: parseUnits("20400", 18), + }, + { + bridgeAdmin: "0x19252AFD0B2F539C400aEab7d460CBFbf74c17ff", + proxyOFT: "0xA03205bC635A772E533E7BE36b5701E331a70ea3", + dstChainId: LzChainId.opbnbtestnet, + maxDailyLimit: parseUnits("100000", 18), + maxSingleTransactionLimit: parseUnits("20000", 18), + maxDailyReceiveLimit: parseUnits("102000", 18), + maxSingleReceiveTransactionLimit: parseUnits("20400", 18), + }, + { + bridgeAdmin: "0xc94578caCC89a29B044a0a1D54d20d48A645E5C8", + proxyOFT: "0xFdC5cEC63FD167DA46cF006585b30D03B104eFD4", + dstChainId: LzChainId.arbitrumsepolia, + maxDailyLimit: parseUnits("100000", 18), + maxSingleTransactionLimit: parseUnits("20000", 18), + maxDailyReceiveLimit: parseUnits("102000", 18), + maxSingleReceiveTransactionLimit: parseUnits("20400", 18), + }, + { + bridgeAdmin: "0x28cfE3f2D7D8944FAd162a058260ec922C19065E", + proxyOFT: "0x760461ccB2508CAAa2ECe0c28af3a4707b853043", + dstChainId: LzChainId.zksyncsepolia, + maxDailyLimit: parseUnits("100000", 18), + maxSingleTransactionLimit: parseUnits("20000", 18), + maxDailyReceiveLimit: parseUnits("102000", 18), + maxSingleReceiveTransactionLimit: parseUnits("20400", 18), + }, + { + bridgeAdmin: "0x6bBcB95eCF9BEc9AE91d5Ad227783e3913145321", + proxyOFT: "0x79a36dc9a43D05Db4747c59c02F48ed500e47dF1", + dstChainId: LzChainId.opsepolia, + maxDailyLimit: parseUnits("100000", 18), + maxSingleTransactionLimit: parseUnits("20000", 18), + maxDailyReceiveLimit: parseUnits("102000", 18), + maxSingleReceiveTransactionLimit: parseUnits("20400", 18), + }, +]; + +function getRemoteBridgeCommands(remoteBridgeEntry: RemoteBridgeEntry): RemoteBridgeCommand[] { + return [ + { + target: remoteBridgeEntry.bridgeAdmin, + signature: "setTrustedRemoteAddress(uint16,bytes)", + params: [LzChainId.basesepolia, BASE_SEPOLIA_TRUSTED_REMOTE], + dstChainId: remoteBridgeEntry.dstChainId, + }, + { + target: remoteBridgeEntry.bridgeAdmin, + signature: "setMinDstGas(uint16,uint16,uint256)", + params: [LzChainId.basesepolia, 0, MIN_DST_GAS], + dstChainId: remoteBridgeEntry.dstChainId, + }, + { + target: remoteBridgeEntry.bridgeAdmin, + signature: "setMaxDailyLimit(uint16,uint256)", + params: [LzChainId.basesepolia, remoteBridgeEntry.maxDailyLimit], + dstChainId: remoteBridgeEntry.dstChainId, + }, + { + target: remoteBridgeEntry.bridgeAdmin, + signature: "setMaxSingleTransactionLimit(uint16,uint256)", + params: [LzChainId.basesepolia, remoteBridgeEntry.maxSingleTransactionLimit], + dstChainId: remoteBridgeEntry.dstChainId, + }, + { + target: remoteBridgeEntry.bridgeAdmin, + signature: "setMaxDailyReceiveLimit(uint16,uint256)", + params: [LzChainId.basesepolia, remoteBridgeEntry.maxDailyReceiveLimit], + dstChainId: remoteBridgeEntry.dstChainId, + }, + { + target: remoteBridgeEntry.bridgeAdmin, + signature: "setMaxSingleReceiveTransactionLimit(uint16,uint256)", + params: [LzChainId.basesepolia, remoteBridgeEntry.maxSingleReceiveTransactionLimit], + dstChainId: remoteBridgeEntry.dstChainId, + }, + ]; +} + +const vip500 = () => { + const meta = { + version: "v2", + title: "VIP-500 Enable Base sepolia bridge", + description: `#### Summary Enable Base bridge`, + forDescription: "I agree that Venus Protocol should proceed with this proposal", + againstDescription: "I do not think that Venus Protocol should proceed with this proposal", + abstainDescription: "I am indifferent to whether Venus Protocol proceeds or not", + }; + + return makeProposal(remoteBridgeEntries.flatMap(getRemoteBridgeCommands), meta, ProposalType.REGULAR); +}; + +export default vip500; diff --git a/vips/vip-500/types.ts b/vips/vip-500/types.ts new file mode 100644 index 000000000..53c654bb7 --- /dev/null +++ b/vips/vip-500/types.ts @@ -0,0 +1,20 @@ +import { BigNumber } from "ethers"; + +import { LzChainId } from "../../src/types"; + +export type RemoteBridgeEntry = { + bridgeAdmin: string; + proxyOFT: string; + maxDailyLimit: BigNumber | number; + maxSingleTransactionLimit: BigNumber | number; + maxDailyReceiveLimit: BigNumber | number; + maxSingleReceiveTransactionLimit: BigNumber | number; + dstChainId: LzChainId | undefined; +}; + +export type RemoteBridgeCommand = { + target: string; + signature: string; + params: any[]; + dstChainId: LzChainId | undefined; +}; From bc201c25544b757f406ca3a600231b1162d59f12 Mon Sep 17 00:00:00 2001 From: GitGuru7 <128375421+GitGuru7@users.noreply.github.com> Date: Mon, 2 Dec 2024 12:42:46 +0530 Subject: [PATCH 175/178] fix: lint --- simulations/vip-500/arbitrumsepolia.ts | 1 - simulations/vip-500/checkXVSBridge.ts | 8 +++----- simulations/vip-500/opbnbtestnet.ts | 1 - simulations/vip-500/opsepolia.ts | 1 - simulations/vip-500/sepolia.ts | 1 - simulations/vip-500/zksyncsepolia.ts | 1 - src/networkAddresses.ts | 15 --------------- src/types.ts | 3 +-- 8 files changed, 4 insertions(+), 27 deletions(-) diff --git a/simulations/vip-500/arbitrumsepolia.ts b/simulations/vip-500/arbitrumsepolia.ts index 3ebaa0b68..a379cabda 100644 --- a/simulations/vip-500/arbitrumsepolia.ts +++ b/simulations/vip-500/arbitrumsepolia.ts @@ -8,7 +8,6 @@ import { checkXVSBridge } from "./checkXVSBridge"; forking(99339753, async () => { await checkXVSBridge( - LzChainId.arbitrumsepolia, LzChainId.basesepolia, NETWORK_ADDRESSES.arbitrumsepolia, vip500, diff --git a/simulations/vip-500/checkXVSBridge.ts b/simulations/vip-500/checkXVSBridge.ts index eec185a9e..70c376751 100644 --- a/simulations/vip-500/checkXVSBridge.ts +++ b/simulations/vip-500/checkXVSBridge.ts @@ -1,4 +1,3 @@ -import { impersonateAccount, setBalance } from "@nomicfoundation/hardhat-network-helpers"; import { SignerWithAddress } from "@nomiclabs/hardhat-ethers/signers"; import { expect } from "chai"; import { Contract } from "ethers"; @@ -17,7 +16,6 @@ import RESILIENT_ORACLE_ABI from "./abi/resilientOracle.json"; const XVS_HOLDER = "0x000000000000000000000000000000000000dEaD"; export async function checkXVSBridge( - forkedLzChainId: number | undefined, remoteLzChainId: number | undefined, networkAddresses: { [key: string]: any }, vip: () => Promise, @@ -43,9 +41,9 @@ export async function checkXVSBridge( resilientOracle = new ethers.Contract(networkAddresses.RESILIENT_ORACLE, RESILIENT_ORACLE_ABI, provider); // Let's fund the XVS_HOLDER wallet with some XVS tokens - await impersonateAccount(bridge.address); - await setBalance(bridge.address, parseUnits("1", 18)); - xvs = new ethers.Contract(networkAddresses.XVS, XVS_ABI, await ethers.getSigner(bridge.address)); + const impersonatedBridge = await initMainnetUser(bridge.address, parseUnits("1", 18)); + + xvs = new ethers.Contract(networkAddresses.XVS, XVS_ABI, impersonatedBridge); await xvs.mint(XVS_HOLDER, parseUnits("10000", 18)); }); diff --git a/simulations/vip-500/opbnbtestnet.ts b/simulations/vip-500/opbnbtestnet.ts index aaedec7a0..5561833c4 100644 --- a/simulations/vip-500/opbnbtestnet.ts +++ b/simulations/vip-500/opbnbtestnet.ts @@ -8,7 +8,6 @@ import { checkXVSBridge } from "./checkXVSBridge"; forking(45337620, async () => { await checkXVSBridge( - LzChainId.opbnbtestnet, LzChainId.basesepolia, NETWORK_ADDRESSES.opbnbtestnet, vip500, diff --git a/simulations/vip-500/opsepolia.ts b/simulations/vip-500/opsepolia.ts index dbbac9b6e..5871f18eb 100644 --- a/simulations/vip-500/opsepolia.ts +++ b/simulations/vip-500/opsepolia.ts @@ -8,7 +8,6 @@ import { checkXVSBridge } from "./checkXVSBridge"; forking(20553060, async () => { await checkXVSBridge( - LzChainId.opsepolia, LzChainId.basesepolia, NETWORK_ADDRESSES.opsepolia, vip500, diff --git a/simulations/vip-500/sepolia.ts b/simulations/vip-500/sepolia.ts index 9d19fda58..4943b2ff4 100644 --- a/simulations/vip-500/sepolia.ts +++ b/simulations/vip-500/sepolia.ts @@ -8,7 +8,6 @@ import { checkXVSBridge } from "./checkXVSBridge"; forking(7124205, async () => { await checkXVSBridge( - LzChainId.sepolia, LzChainId.basesepolia, NETWORK_ADDRESSES.sepolia, vip500, diff --git a/simulations/vip-500/zksyncsepolia.ts b/simulations/vip-500/zksyncsepolia.ts index 8b05a0f8f..fd68a2b71 100644 --- a/simulations/vip-500/zksyncsepolia.ts +++ b/simulations/vip-500/zksyncsepolia.ts @@ -8,7 +8,6 @@ import { checkXVSBridge } from "./checkXVSBridge"; forking(4245630, async () => { await checkXVSBridge( - LzChainId.zksyncsepolia, LzChainId.basesepolia, NETWORK_ADDRESSES.zksyncsepolia, vip500, diff --git a/src/networkAddresses.ts b/src/networkAddresses.ts index 8544c8dad..bc10c6e93 100644 --- a/src/networkAddresses.ts +++ b/src/networkAddresses.ts @@ -170,7 +170,6 @@ export const NETWORK_ADDRESSES = { OMNICHAIN_GOVERNANCE_EXECUTOR: "0xc1858cCE6c28295Efd3eE742795bDa316D7c7526", }, zksyncsepolia: { - NORMAL_TIMELOCK: "0x1730527a0f0930269313D77A317361b42971a67E", NORMAL_TIMELOCK: "0x1730527a0f0930269313D77A317361b42971a67E", GUARDIAN: "0xa2f83de95E9F28eD443132C331B6a9C9B7a9F866", GENERIC_TEST_USER_ACCOUNT: "0x6f057A858171e187124ddEDF034dAc63De5dE5dB", @@ -183,12 +182,8 @@ export const NETWORK_ADDRESSES = { ENDPOINT: "0x99b6359ce8E0eBdC27eBeDb76FE28F29303E78fF", LZ_LIBRARY: "0xC6d12200b743A8F7e6b7228B8E920A71d94FA7Fb", OMNICHAIN_GOVERNANCE_EXECUTOR: "0x83F79CfbaEee738173c0dfd866796743F4E25C9e", - ENDPOINT: "0x99b6359ce8E0eBdC27eBeDb76FE28F29303E78fF", - LZ_LIBRARY: "0xC6d12200b743A8F7e6b7228B8E920A71d94FA7Fb", - OMNICHAIN_GOVERNANCE_EXECUTOR: "0x83F79CfbaEee738173c0dfd866796743F4E25C9e", }, zksyncmainnet: { - NORMAL_TIMELOCK: "0x093565Bc20AA326F4209eBaF3a26089272627613", NORMAL_TIMELOCK: "0x093565Bc20AA326F4209eBaF3a26089272627613", GUARDIAN: "0x751Aa759cfBB6CE71A43b48e40e1cCcFC66Ba4aa", VTREASURY: "0xB2e9174e23382f7744CebF7e0Be54cA001D95599", @@ -201,9 +196,6 @@ export const NETWORK_ADDRESSES = { ENDPOINT: "0x9b896c0e23220469C7AE69cb4BbAE391eAa4C8da", LZ_LIBRARY: "0x042b8289c97896529Ec2FE49ba1A8B9C956A86cC", OMNICHAIN_GOVERNANCE_EXECUTOR: "0xA1b56f19CA5E5b15EF29d38238930Ce9f0235312", - ENDPOINT: "0x9b896c0e23220469C7AE69cb4BbAE391eAa4C8da", - LZ_LIBRARY: "0x042b8289c97896529Ec2FE49ba1A8B9C956A86cC", - OMNICHAIN_GOVERNANCE_EXECUTOR: "0xA1b56f19CA5E5b15EF29d38238930Ce9f0235312", }, opsepolia: { NORMAL_TIMELOCK: "0xdDe31d7eEEAD7Cf9790F833C4FF4c6e61404402a", @@ -218,12 +210,8 @@ export const NETWORK_ADDRESSES = { ENDPOINT: "0x55370E0fBB5f5b8dAeD978BA1c075a499eB107B8", LZ_LIBRARY: "0x35AdD9321507A87471a11EBd4aE4f592d531e620", OMNICHAIN_GOVERNANCE_EXECUTOR: "0xC7D6D33adcdBfccD416C3aAB1878360ea8b79ac6", - ENDPOINT: "0x55370E0fBB5f5b8dAeD978BA1c075a499eB107B8", - LZ_LIBRARY: "0x35AdD9321507A87471a11EBd4aE4f592d531e620", - OMNICHAIN_GOVERNANCE_EXECUTOR: "0xC7D6D33adcdBfccD416C3aAB1878360ea8b79ac6", }, opmainnet: { - NORMAL_TIMELOCK: "0x0C6f1E6B4fDa846f63A0d5a8a73EB811E0e0C04b", NORMAL_TIMELOCK: "0x0C6f1E6B4fDa846f63A0d5a8a73EB811E0e0C04b", VTREASURY: "0x104c01EB7b4664551BE6A9bdB26a8C5c6Be7d3da", GUARDIAN: "0x2e94dd14E81999CdBF5deDE31938beD7308354b3", @@ -237,9 +225,6 @@ export const NETWORK_ADDRESSES = { ENDPOINT: "0x3c2269811836af69497E5F486A85D7316753cf62", LZ_LIBRARY: "0x4D73AdB72bC3DD368966edD0f0b2148401A178E2", OMNICHAIN_GOVERNANCE_EXECUTOR: "0x09b11b1CAdC08E239970A8993783f0f8EeC60ABf", - ENDPOINT: "0x3c2269811836af69497E5F486A85D7316753cf62", - LZ_LIBRARY: "0x4D73AdB72bC3DD368966edD0f0b2148401A178E2", - OMNICHAIN_GOVERNANCE_EXECUTOR: "0x09b11b1CAdC08E239970A8993783f0f8EeC60ABf", }, basesepolia: { GUARDIAN: "0xdf3b635d2b535f906BB02abb22AED71346E36a00", diff --git a/src/types.ts b/src/types.ts index b35a8d5e7..50717786a 100644 --- a/src/types.ts +++ b/src/types.ts @@ -10,8 +10,7 @@ export type SUPPORTED_NETWORKS = | "zksyncsepolia" | "zksyncmainnet" | "opsepolia" - | "opmainnet" - | "basesepolia"; + | "opmainnet"; export type REMOTE_NETWORKS = Exclude; From f000fb0895fefa2bae8ae01b97abc108ec6c56e4 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Mon, 2 Dec 2024 13:02:12 +0100 Subject: [PATCH 176/178] chore: add missing config to support basesepolia forks --- hardhat.config.ts | 3 ++- src/chains.ts | 1 + type-extensions.ts | 1 + 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/hardhat.config.ts b/hardhat.config.ts index cef486cb0..7ff7e1a12 100644 --- a/hardhat.config.ts +++ b/hardhat.config.ts @@ -122,6 +122,7 @@ const config: HardhatUserConfig = { [ChainId.arbitrumone]: assumeCancun, [ChainId.opsepolia]: assumeCancun, [ChainId.opmainnet]: assumeCancun, + [ChainId.basesepolia]: assumeCancun, }, }, bsctestnet: { @@ -187,7 +188,7 @@ const config: HardhatUserConfig = { }, basesepolia: { url: process.env.ARCHIVE_NODE_basesepolia || "https://sepolia.base.org", - chainId: 84532, + chainId: ChainId.basesepolia, accounts: DEPLOYER_PRIVATE_KEY ? [`0x${DEPLOYER_PRIVATE_KEY}`] : [], blockGasLimit: BLOCK_GAS_LIMIT_PER_NETWORK.basesepolia, }, diff --git a/src/chains.ts b/src/chains.ts index 162466162..840962781 100644 --- a/src/chains.ts +++ b/src/chains.ts @@ -3,6 +3,7 @@ export enum ChainId { sepolia = 11155111, bscmainnet = 56, bsctestnet = 97, + basesepolia = 84532, opbnbtestnet = 5611, opbnbmainnet = 204, arbitrumsepolia = 421614, diff --git a/type-extensions.ts b/type-extensions.ts index 8c2f37155..adbc90766 100644 --- a/type-extensions.ts +++ b/type-extensions.ts @@ -6,6 +6,7 @@ declare module "hardhat/types/runtime" { FORKED_NETWORK?: | "bsctestnet" | "bscmainnet" + | "basesepolia" | "sepolia" | "ethereum" | "opbnbtestnet" From 40e25e383428b8e95a2f2e72dd4a913202032484 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Mon, 2 Dec 2024 19:52:16 +0100 Subject: [PATCH 177/178] fixup! fix: updated addresses --- .../basesepolia/vip-002/abi/acm.json | 126 ------------------ .../simulations/basesepolia/vip-002/index.ts | 12 +- 2 files changed, 3 insertions(+), 135 deletions(-) delete mode 100644 multisig/simulations/basesepolia/vip-002/abi/acm.json diff --git a/multisig/simulations/basesepolia/vip-002/abi/acm.json b/multisig/simulations/basesepolia/vip-002/abi/acm.json deleted file mode 100644 index 687d32137..000000000 --- a/multisig/simulations/basesepolia/vip-002/abi/acm.json +++ /dev/null @@ -1,126 +0,0 @@ -[ - { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, - { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" } - ], - "name": "RoleAdminChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } - ], - "name": "RoleGranted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, - { "indexed": true, "internalType": "address", "name": "sender", "type": "address" } - ], - "name": "RoleRevoked", - "type": "event" - }, - { - "inputs": [], - "name": "DEFAULT_ADMIN_ROLE", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], - "name": "getRoleAdmin", - "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" }, - { "internalType": "address", "name": "accountToPermit", "type": "address" } - ], - "name": "giveCallPermission", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "grantRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "hasRole", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "account", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" } - ], - "name": "isAllowedToCall", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "renounceRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "address", "name": "contractAddress", "type": "address" }, - { "internalType": "string", "name": "functionSig", "type": "string" }, - { "internalType": "address", "name": "accountToRevoke", "type": "address" } - ], - "name": "revokeCallPermission", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { "internalType": "bytes32", "name": "role", "type": "bytes32" }, - { "internalType": "address", "name": "account", "type": "address" } - ], - "name": "revokeRole", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], - "name": "supportsInterface", - "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], - "stateMutability": "view", - "type": "function" - } -] diff --git a/multisig/simulations/basesepolia/vip-002/index.ts b/multisig/simulations/basesepolia/vip-002/index.ts index 1aa809eea..ad5554258 100644 --- a/multisig/simulations/basesepolia/vip-002/index.ts +++ b/multisig/simulations/basesepolia/vip-002/index.ts @@ -2,22 +2,21 @@ import { mine } from "@nomicfoundation/hardhat-network-helpers"; import { SignerWithAddress } from "@nomiclabs/hardhat-ethers/signers"; import { expect } from "chai"; import { Contract } from "ethers"; -import { parseEther, parseUnits } from "ethers/lib/utils"; +import { parseEther } from "ethers/lib/utils"; import { ethers } from "hardhat"; import { NETWORK_ADDRESSES } from "src/networkAddresses"; import { initMainnetUser } from "src/utils"; import { checkXVSVault } from "src/vip-framework/checks/checkXVSVault"; import { forking, pretendExecutingVip } from "src/vip-framework/index"; -import vip002, { ACM, XVS_STORE } from "../../../proposals/basesepolia/vip-002"; -import ACM_ABI from "./abi/acm.json"; +import vip002, { XVS_STORE } from "../../../proposals/basesepolia/vip-002"; import XVS_ABI from "./abi/xvs.json"; import XVS_STORE_ABI from "./abi/xvsstore.json"; import XVS_VAULT_ABI from "./abi/xvsvault.json"; const { basesepolia } = NETWORK_ADDRESSES; -const XVS_BRIDGE = "0xE431E82d8fFfd81E7c082BeC7Fe2C306f5c988aD"; +const XVS_BRIDGE = "0xD5Cd1fD17B724a391C1bce55Eb9d88E3205eED60"; forking(18691727, async () => { let xvsVault: Contract; @@ -34,17 +33,12 @@ forking(18691727, async () => { describe("Post tx checks", () => { describe("Generic checks", async () => { before(async () => { - const acm: Contract = await ethers.getContractAt(ACM_ABI, ACM); const xvs: Contract = await ethers.getContractAt(XVS_ABI, basesepolia.XVS); xvsMinter = await initMainnetUser(XVS_BRIDGE, ethers.utils.parseEther("1")); const admin = await initMainnetUser(basesepolia.GUARDIAN, ethers.utils.parseEther("1")); const xvsHolder = await initMainnetUser(basesepolia.GENERIC_TEST_USER_ACCOUNT, ethers.utils.parseEther("1")); await xvsVault.connect(admin).setRewardAmountPerBlockOrSecond(basesepolia.XVS, "61805555555555555"); await xvsVault.connect(admin).resume(); - // Giving call permissions to call the functions as xvs bridge vip is not executed now. - await acm.connect(admin).giveCallPermission(basesepolia.XVS, "mint(address,uint256)", XVS_BRIDGE); - await acm.connect(admin).giveCallPermission(basesepolia.XVS, "setMintCap(address,uint256)", admin.address); - await xvs.connect(admin).setMintCap(XVS_BRIDGE, parseUnits("100", 18)); await xvs.connect(xvsMinter).mint(xvsHolder.address, parseEther("10")); await xvs.connect(xvsHolder).transfer(XVS_STORE, ethers.utils.parseEther("1")); From 70aa9ed36e66344a261511b875f026e6a6724c20 Mon Sep 17 00:00:00 2001 From: Jesus Lanchas Date: Tue, 3 Dec 2024 11:36:28 +0100 Subject: [PATCH 178/178] chore: update the PoolRegistry address --- src/networkAddresses.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/networkAddresses.ts b/src/networkAddresses.ts index 52f986824..2ef481e2f 100644 --- a/src/networkAddresses.ts +++ b/src/networkAddresses.ts @@ -217,6 +217,6 @@ export const NETWORK_ADDRESSES = { XVS: "0xE657EDb5579B82135a274E85187927C42E38C021", GENERIC_TEST_USER_ACCOUNT: "0x6f057A858171e187124ddEDF034dAc63De5dE5dB", REDSTONE_ORACLE: "0x8267FE3f75E0A37ee34e113E767F9C9727206838", - POOL_REGISTRY: "0xD5D9f24a5EB83e81F2188b1F2a8c217EEf56dFa5", + POOL_REGISTRY: "0xCa330282BEeb07a81963336d0bf8f5f34317916c", }, };